Date: Tue, 16 Oct 2007 23:25:02 +0200 From: Pawel Jakub Dawidek <pjd@FreeBSD.org> To: Bill Vermillion <bv@wjv.com> Cc: freebsd-fs@freebsd.org, Paul Kupfer <kupfer@ldc.upenn.edu> Subject: Re: du and df discrepancy Message-ID: <20071016212502.GJ16627@garage.freebsd.pl> In-Reply-To: <20071016162948.GA79131@wjv.com> References: <20071016114035.O64828@lorax.ldc.upenn.edu> <20071016162948.GA79131@wjv.com>
next in thread | previous in thread | raw e-mail | index | archive | help
--++alDQ2ROsODg1x+ Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Oct 16, 2007 at 12:29:48PM -0400, Bill Vermillion wrote: > du - shows the amount of blocks used by the system > df - shows the amunt of space it thinks is being used. >=20 > The latter will compute the length of sparse files so df > will show less free space than du. Sparse file will have=20 > blocks of no data in them. These are typically created > by database programs. Please, verify before giving an answer. Neither du(1) nor df(1) include sparse blocks in their calculations: # ls -lh /mnt/tmp/foo -rw-r----- 1 root wheel 10G 16 pa# 23:19 /mnt/tmp/foo # df -h /mnt/tmp/foo Filesystem Size Used Avail Capacity Mounted on /dev/md0 9.4M 52K 8.6M 1% /mnt/tmp --=20 Pawel Jakub Dawidek http://www.wheel.pl pjd@FreeBSD.org http://www.FreeBSD.org FreeBSD committer Am I Evil? Yes, I Am! --++alDQ2ROsODg1x+ Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.4 (FreeBSD) iD8DBQFHFSwuForvXbEpPzQRAtAEAJ9GY8F+gTUadyRUMlw51TP9ukVSvACfVI/w CoexGKv6VrgRhb6mPuyi64w= =k+VL -----END PGP SIGNATURE----- --++alDQ2ROsODg1x+--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20071016212502.GJ16627>
