From owner-freebsd-stable Tue Feb 6 9:36:27 2001 Delivered-To: freebsd-stable@freebsd.org Received: from whale.sunbay.crimea.ua (whale.sunbay.crimea.ua [212.110.138.65]) by hub.freebsd.org (Postfix) with ESMTP id 474BF37B491 for ; Tue, 6 Feb 2001 09:36:04 -0800 (PST) Received: (from ru@localhost) by whale.sunbay.crimea.ua (8.11.0/8.11.0) id f16HZW509021; Tue, 6 Feb 2001 19:35:32 +0200 (EET) (envelope-from ru) Date: Tue, 6 Feb 2001 19:35:32 +0200 From: Ruslan Ermilov To: Panagiotis Astithas Cc: stable@FreeBSD.ORG Subject: Re: df output incosistency Message-ID: <20010206193532.A7821@sunbay.com> Mail-Followup-To: Panagiotis Astithas , stable@FreeBSD.ORG References: <20010206192656.B6939@netmode.ece.ntua.gr> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010206192656.B6939@netmode.ece.ntua.gr>; from past@netmode.ntua.gr on Tue, Feb 06, 2001 at 07:26:56PM +0200 Sender: owner-freebsd-stable@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Tue, Feb 06, 2001 at 07:26:56PM +0200, Panagiotis Astithas wrote: > Running df on my laptop with softupdates enabled, produces the > following output: > > Filesystem 1K-blocks Used Avail Capacity Mounted on > /dev/ad0s1a 99183 43709 47540 48% / > /dev/ad0s1e 2750654 2112356 418246 83% /usr > procfs 4 4 0 100% /proc > > As you can see there is a difference between the total number > of blocks and the sum of used+available blocks. Particularly > in the case of /usr there are more than 200MB "lost". Now, > this came up while I was building a large port and erasing a > very large file, about the size of the lost space. In the process > the filesystem became full, and I had to stop the rm process, > stop the build, reboot and fsck the disks (which did find errors). > After that df always reported the mismatch you can see above. At > that time the system was 4.2-STABLE as of early December IIRC, so > I suspected a bug in df or ufs or softupdates and I upgraded the > system, to no avail. I have since used the system as usual, with > the only remarkable exception that a few times when I exceeded the > available disk space (as indicated by df), the operations continued > without a problem, although df reported a negative available space. > > My question is, can I reclaim the apparently lost space without > using newfs? Is df lying and I can safely ignore the available > space reading, or doing so will corrupt my filesystem even worse? > > Any help on this would be highly appreciated, since I will not be > able to newfs my drive for a few months. > The UFS filesystem normally reserve about 8% of space. If you run the above command, you should see numbers around 92: df -P -t ufs | awk '{ print $1, ($3+$4)/$2*100 }' Cheers, -- Ruslan Ermilov Oracle Developer/DBA, ru@sunbay.com Sunbay Software AG, ru@FreeBSD.org FreeBSD committer, +380.652.512.251 Simferopol, Ukraine http://www.FreeBSD.org The Power To Serve http://www.oracle.com Enabling The Information Age To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-stable" in the body of the message