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.

Disk Used Incorrect

Discussion in 'General Discussion' started by sudonic, Dec 24, 2009.

  1. sudonic

    sudonic Member

    Joined:
    Oct 29, 2007
    Messages:
    11
    Likes Received:
    0
    Trophy Points:
    1
    Hi,
    When I download a zip file like Joomla or Wordpress and unzip that, it is 16 MB on my PC. but when i Upload and unzip that on host. it uses 29 MB of quota, and some times on other Host it is 58 MB

    I checked it with du command and get some strange and different results.

    Code:
    # du -sm administrator/
    15    administrator/
    
    # du -sb administrator/
    3997771    administrator/
    
    # du -sh administrator/
    15M    administrator/
    
    The following commands return different results for a specific folder but just du -sb command show the true results.
    the problem is that , cPanel show the incorrect result
     
  2. cPanelDon

    cPanelDon cPanel Quality Assurance Analyst
    Staff Member

    Joined:
    Nov 5, 2008
    Messages:
    2,557
    Likes Received:
    7
    Trophy Points:
    38
    Location:
    Houston, Texas, U.S.A.
    cPanel Access Level:
    DataCenter Provider
    Twitter:
    The disk usage utility "du" is not a component of cPanel, rather it is included with the Operating System distribution.

    What method is being used to calculate "du -sb" as reporting a more correct result versus other CLI options for "du"?

    Via what specific area is being used to view the disk usage in cPanel (e.g., Disk Space Usage (viewer), File Manager, or Legacy File Manager)?

    Please also be aware of the context when using the CLI switch "-b" for the "du" command. Here is a partial quote from the manual page for "du" as seen via the command "man du":
    -b, --bytes
    equivalent to '--apparent-size --block-size=1'


    --apparent-size
    print apparent sizes, rather than disk usage; although the apparent size is usually smaller, it may be larger due to holes in ('sparse') files, internal fragmentation, indirect blocks, and the like


    -B, --block-size=SIZE
    use SIZE-byte blocks
     
  3. sudonic

    sudonic Member

    Joined:
    Oct 29, 2007
    Messages:
    11
    Likes Received:
    0
    Trophy Points:
    1
    Many thanks for your replay.
    I don,t use of commands. I used it just for reporting.
    But I want to know why the result is different in two server disk usage space reporting on cPanel and my PC reporting?
    For example: 16MB -> PC .... 29MB -> cPanel ... 58MB -> other server cPanel
    What is the problem in cPanel?
    I think I have a problem on server.
    Why the disk space usage is different?
     
  4. cPanelDon

    cPanelDon cPanel Quality Assurance Analyst
    Staff Member

    Joined:
    Nov 5, 2008
    Messages:
    2,557
    Likes Received:
    7
    Trophy Points:
    38
    Location:
    Houston, Texas, U.S.A.
    cPanel Access Level:
    DataCenter Provider
    Twitter:
    cPanel does not control how much disk space is used; the OS-provided file-system quota support and OS-provided tools are used for querying disk usage, such as that from the command "du" -- if there is significant difference in what "du" reports this should be investigated by the server administrator and or escalated to the upstream data center or server management team.
     
Loading...

Share This Page