Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


Recalculate df
New on LowEndTalk? Please Register and read our Community Rules.

All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

Recalculate df

drmikedrmike Member
edited September 2011 in Help

Is there a way to recalculate df? I ask because I have a drive where I do a df as root and it's off my no less than 20 gigs.

Or is there something maybe I should be looking at?

Granted this is for FreeBSD but same answers should apply.

thanks,
-drmike

Comments

  • I don't really get your question, but I think du may help.

    http://en.wikipedia.org/wiki/Du_(Unix)

    Its like df, but a bit more accurate, but takes longer.

  • How would you know that df is off by ~20GB?

  • thanks

    du if I believe space used. df is space free.

    For example, say I have a 100 gig hard drive. Right now 30 gigs are being used for files so a 'du -h' should report back as as having 70 gigs free. It's not. It's saying only 50 gigs are available.

    Nothing in the /tmp/ directory as far as I see. That comes up as a suggestion via a google search.

    @Kuro, because it is. :) I know what's on it. It's a networked drive for backups. I can sit here and see all of the compressed files and add them up in size. My math may be off but it wouldn't be off by that much. (And when i first came across the issue, I went ahead and added all of the sizes up together. It's off.)

    Of course the smart add response for that is a friendly reminder about that PhD in Theoretical Mathematics that I have. :D

  • Give the output of

    df -h and fdisk

  • drmikedrmike Member
    edited September 2011

    I'm going to have to look at this later. I'm getting the fdisk not found error followed by the "is already the newest version." error when I try to install it. I'll be late for bloodwork.

    edit: Oops, should have been root. I have to go though. Thanks

  • Only thing I can think of at the moment is maybe one of those programs is reporting in Gigabytes (GB) and the other is reporting in Gibibytes (GiB)?

    For example, a HDD labeled by the manufacturer as 100GB, has a capacity of 93.132GiB, which is often reported within the OS as just 93.132GB.

  • Have you tried rebooting it?

  • If there are files that have been opened, then deleted but are still held open - they are still present (take disk space) only they don't show as names anywhere in the file system (unlinked). Only when these files are closed the space they take will be freed.
    If it is possible to schedule a reboot this should get rid of those unlinked but still not deleted files.

Sign In or Register to comment.