System Administration
cancel
Showing results for 
Search instead for 
Did you mean: 

used is only 16GB , but it is not showing 1 gb free

 
Highlighted

used is only 16GB , but it is not showing 1 gb free

Hello Linux Gurus,

Here I'm facing a issue with free disk and actual disk used
Below is the df -h /db output.
OS SLES 10.2

/dev/mapper/vg01-lvol1
17G 16G 93M 100% /db

Why it's showing 100% used while only 16Gb is the used.

Thanks in advance.

Regards,
4 REPLIES 4
Highlighted
Acclaimed Contributor

Re: used is only 16GB , but it is not showing 1 gb free

This is the wrong forum for Linux questions, I'll ask the moderators to move it.

Typically this happens when a file removed while it is still open. Once the process exits, the space will be returned to the free space.
Highlighted
Honored Contributor

Re: used is only 16GB , but it is not showing 1 gb free

> [...] Linux Gurus [...]

An HP-UX forum might not be the best place to
look for those.

http://forums11.itrc.hp.com/service/forums/familyhome.do?familyId=118

> Why it's showing 100% used [...]

Some "df" programs treat 90% full as "100%"
-- like setting the time ahead 30 minutes on
your alarm clock to get you up on time in the
morning. I'm not sure what DNU "df" does,
but if all its percentages appear to be off
this way, then that could be the reason.
Actual GNU "df" documentation (or the source
code) might reveal the truth.

Also, with numbers like "16" and "17", there
could be some round-off error. (For example,
if "16" is really 16.4999, and "17" is
really 16.5001, then what's the ratio?)
Highlighted
Honored Contributor

Re: used is only 16GB , but it is not showing 1 gb free

Is it worth noting that on some operating
systems, it's trivial to get exact file
system size and usage info (in 512-byte
blocks), and then one can do the arithmetic
himself? On VMS, for example, one can easily
"get device information":

alp $ write sys$output f$getdvi( "dka0:", "maxblock")
71687372

alp $ write sys$output f$getdvi( "dka0:", "freeblocks")
15364544

A strong argument could be made that the
design of "df" for getting file system size
and usage is every bit as good as that of
"ls -l" when one is looking for date-time
info for a file.
Highlighted
Honored Contributor

Re: used is only 16GB , but it is not showing 1 gb free

In Linux ext2/ext3(/ext4?) filesystems, it is possible to reserve a part of disk space for root only. The intent was to allow important system daemons to run normally even if some user program allocates all the space it can get (and there are no quotas configured).

For historical reasons, this feature is enabled by default. The percentage of disk space reserved for root only is 5% by default on my Debian system: on other Linux distributions, it might be 1% or 2%.

When creating a new filesystem, you can disable this feature by using the option "-m 0" with mkfs.

If you want to disable this feature in an already existing filesystem, use "tune2fs -m 0". (tune2fs -l will show the current setting)

Example:
To view your current /db filesystem settings:

tune2fs -l /dev/mapper/vg01-lvol1

To remove the root-only reservation from your /db filesystem:

umount /db
tune2fs -m 0 /dev/mapper/vg01-lvol1
mount /db

MK
MK