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.

Quotas and automatic updates

Discussion in 'General Discussion' started by shacker23, Sep 14, 2010.

  1. shacker23

    shacker23 Well-Known Member

    Joined:
    Feb 20, 2005
    Messages:
    263
    Likes Received:
    1
    Trophy Points:
    16
    We're set to track Automatic RELEASE. Last night after an automatic update to the latest release, all of our disk quota customizations were lost and they were reset to default values.

    Any idea what could cause this or how we can prevent it from happening in the future? Thanks.
     
  2. garrettp

    garrettp Well-Known Member
    PartnerNOC

    Joined:
    Jun 18, 2004
    Messages:
    312
    Likes Received:
    0
    Trophy Points:
    16
    cPanel Access Level:
    DataCenter Provider
    Can you clarify "disk quota customiations"? Are you referring to having changed a user's quota in the WHM under Main >> Account Functions >> Quota Modification?
     
  3. shacker23

    shacker23 Well-Known Member

    Joined:
    Feb 20, 2005
    Messages:
    263
    Likes Received:
    1
    Trophy Points:
    16
    Yes - this is after having changed a user's quota. Thanks.
     
  4. garrettp

    garrettp Well-Known Member
    PartnerNOC

    Joined:
    Jun 18, 2004
    Messages:
    312
    Likes Received:
    0
    Trophy Points:
    16
    cPanel Access Level:
    DataCenter Provider
    Quotas may not be initialized on your drive, try:
    Code:
    /scripts/initquotas
     
  5. shacker23

    shacker23 Well-Known Member

    Joined:
    Feb 20, 2005
    Messages:
    263
    Likes Received:
    1
    Trophy Points:
    16
    OK, ran that. We'll see how it goes after the next auto-update. Thanks.
     
  6. 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:
    Were any system administration tasks performed before or close to the time when the quotas were reset?

    Does the system have a pre or post script setup that runs before or after a cPanel update?

    Please let us know the output from the following commands:
    Code:
    # stat /scripts/preupcp /scripts/postupcp
    # cat -en /scripts/preupcp
    # cat -en /scripts/postupcp
    For future-proofing the desired modifications, I recommend ensuring that all disk quotas are defined in packages, where each package defines a specific disk quota while multiple accounts may share the same package. WebHost Manager (WHM) can be used to define packages and assign them to accounts via the following menu paths (with linked documentation):
     
  7. shacker23

    shacker23 Well-Known Member

    Joined:
    Feb 20, 2005
    Messages:
    263
    Likes Received:
    1
    Trophy Points:
    16
    On this particular server, we use only a single package for all accounts, and it does have a quota set. Accounts that need different quotas are modified individually.

    I'm not positive about administrative commands running at the same time, but we do have a fairly lengthy backup process running in the middle of the night, in case that could be related.

    Here is the output of those commands:

    # stat /scripts/preupcp /scripts/postupcp
    stat: cannot stat `/scripts/preupcp': No such file or directory
    File: `/scripts/postupcp'
    Size: 34 Blocks: 8 IO Block: 4096 regular file
    Device: fd00h/64768d Inode: 458756 Links: 1
    Access: (0700/-rwx------) Uid: ( 0/ root) Gid: ( 0/ root)
    Access: 2009-12-22 02:18:20.000000000 -0800
    Modify: 2008-05-30 05:25:18.000000000 -0700
    Change: 2010-09-08 02:17:03.000000000 -0700


    # cat -en /scripts/preupcp
    cat: /scripts/preupcp: No such file or directory

    # cat -en /scripts/postupcp
    1 #!/bin/sh$
    2 /scripts/compilers off$
    3 $
     
  8. shacker23

    shacker23 Well-Known Member

    Joined:
    Feb 20, 2005
    Messages:
    263
    Likes Received:
    1
    Trophy Points:
    16
    On this particular server, we use only a single package for all accounts, and it does have a quota set. Accounts that need different quotas are modified individually.

    I'm not positive about administrative commands running at the same time, but we do have a fairly lengthy backup process running in the middle of the night, in case that could be related.

    Here is the output of those commands:

    Code:
    # stat /scripts/preupcp /scripts/postupcp
    stat: cannot stat `/scripts/preupcp': No such file or directory
      File: `/scripts/postupcp'
      Size: 34        	Blocks: 8          IO Block: 4096   regular file
    Device: fd00h/64768d	Inode: 458756      Links: 1
    Access: (0700/-rwx------)  Uid: (    0/    root)   Gid: (    0/    root)
    Access: 2009-12-22 02:18:20.000000000 -0800
    Modify: 2008-05-30 05:25:18.000000000 -0700
    Change: 2010-09-08 02:17:03.000000000 -0700
    
    
    # cat -en /scripts/preupcp
    cat: /scripts/preupcp: No such file or directory
    
    # cat -en /scripts/postupcp
         1	#!/bin/sh$
         2	/scripts/compilers off$
         3	$
    
     
  9. 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 content of the custom postupcp script appears OK; I believe that should not reset quotas. I recommend creating a package for each unique disk quota limit that is desired, and then use the new packages to have customized disk quotas applied to cPanel accounts. As a long-term solution, using packages to store and assign disk quotas will help to ensure they remain intact and are not inadvertently reset.

    If the difficulty with disk quotas being reset is persistently recurring or recurring frequently, I would consider submitting a support request so that the issue may be investigated further.
     
Loading...

Share This Page