Thursday, March 13, 2014

DF command shows incorrect usage for VXFS file system

I have faced issue with one of the VXFS file system which is showing incorrect volume usage when I execute “df -h”command. But actually if you do "du -sh" there is no data and volume is empty but still it is showing incorrect value , after digging more I got to know this is known issue. 

Here I am giving details how to calculate actual space when this type of issue occur.

Information from Symantec site (VERITAS) :
  1. VxFS will use some of this space for structural data such as the Intent Log, Free Extent Bitmaps, Superblocks, etc. 
  2. Due to the dynamic inode allocation functionality on a VXFS, free space is not the same as available space.
This space will be released automatically by Veritas when user needs that space means if you start fill up the volume it will get release automatically.

The right way of identifying the actual free available space we should use “df -b” command.

As per below scenario we are missing around 30 GB size.
[root@iv01]# df -h /ora/data1
Filesystem              size   used  avail capacity  Mounted on
/dev/vx/dsk/ora/data1   300G   500M   269G     1%    /ora/data1
[root@iv01]# du -sh /ora/data1
   0K   /ora/data1
[root@iv01]#
To examine correct value:
[root@iv01]# df -b /ora/data1
Filesystem              avail
/ora/data1     313524224
[root@iv01]#
Calculate KB to GB:
[root@iv01]# bc
313524224/1024/1024
299
[root@iv01]#
We can see through "df -b" command , it is reporting correct value. This is not the issue in VXFS but actually VXFS is keeping configuration date like this method.

0 comments:

Post a Comment