The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Wrong disk usage by /var

Discussion in 'General Discussion' started by ukagg, Jul 25, 2006.

  1. ukagg

    ukagg Active Member

    Joined:
    Aug 14, 2002
    Messages:
    35
    Likes Received:
    0
    Trophy Points:
    6
    Hi,

    Server Information in WHM on my server shows:-

    /dev/hda3 6.9G 6.2G 390M 95% /var

    But, when I check it from ssh, it shows as under:-

    root@ns2 [/]# du -sh /var
    364M /var

    I think, actual usage on my /var is only 364MB, but WHM is showing wrong figure. How can I fix it?

    Thanks
    UKA
     
  2. chirpy

    chirpy Well-Known Member

    Joined:
    Jun 15, 2002
    Messages:
    13,475
    Likes Received:
    20
    Trophy Points:
    38
    Location:
    Go on, have a guess
    WHM isn't showing the wrong figure. They're both right :) The difference comes about because there are open files that have been deleted on the partition. This typically happens if you delete a log file but forget to restart the service that has it open. It will continue to write to the deleted file until it is restarted. df, show is what WHM is using, shows the amount of space used including open files, du shows the amount of space, excluding the deleted, but open files.
     
Loading...

Share This Page