lkml.org 
[lkml]   [1997]   [Sep]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: 2.0.31-pre9: "noise after df"
On Mon, 15 Sep 1997, Pavel Machek wrote:
>
> Hmm. Recreated in 2.1.55, df sounds like sync... And looks like sync,
> too (on blinkenlights)... And guess what:
>
> And it is because df _calls_ sync!
>
> write(1, "Filesystem 1024-blocks "..., 67Filesystem
> 1024-blocks Used Available Capacity Mounted on
> ) = 67
> sync() = 0
> statfs("/", {f_type=EXT2_SUPER_MAGIC, f_bsize=1024, f_blocks=491660,
> f_bfree=21860, f_files=127472, f_ffree=89438, f_namelen=255}}) = 0
> write(1, "/dev/hda4 491660 46"..., 58/dev/hda4
> 491660 469800 16780 97%
>
> So "bug" is in df (or is sync required before df-ing?).
> Pavel

More likely, a workaround for a bug in filesystem support in some popular
unix. (statfs() returning the metadata for only that portion that has been
written to disk, rather then computing it with the cached data taken into
account.) So df syncs (you can never sync to often) just to make shure.

-=- James Mastros


\
 
 \ /
  Last update: 2005-03-22 13:40    [W:0.113 / U:0.376 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site