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.

Cpanel and derivate files owners and groups on /var

Discussion in 'General Discussion' started by AoM_Scott, Apr 30, 2012.

  1. AoM_Scott

    AoM_Scott Member

    Joined:
    Aug 26, 2010
    Messages:
    7
    Likes Received:
    0
    Trophy Points:
    1
    OK this is embarrassing but my fat fingers managed to do a recursive chown on most of /var to root:root.

    This has of course broken a few of the functions of cpanel, could somebody have a quick look at the owner of all the cpanel related files in /var and let me know what to change the owners back to (where its not meant to be root:root)?

    For example my installation cannot read /var/cpanel/users and therefore won't login to cPanel user accounts :rolleyes:

    Thanks
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,723
    Likes Received:
    660
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    Ideally, you should obtain access to another server to compare the ownership of the files/directories within the /var partition because there are several directories that are not owned by "root".

    The files within the "/var/cpanel/users" directory should have user ownership set to "root", and group ownership set to the cPanel username. EX:

    Code:
    root@server [/]# ls -al /var/cpanel/users/cptest01
    -rw-r----- 1 root cptest01 788 May  1 05:54 /var/cpanel/users/cptest01
    The directories within "/var/cpanel/userdata" should have the same ownership values configured.

    Thank you.
     
  3. AoM_Scott

    AoM_Scott Member

    Joined:
    Aug 26, 2010
    Messages:
    7
    Likes Received:
    0
    Trophy Points:
    1
    Yeah that was my first thought, I have a VPS but it doesn't run cpanel so it wasn't much help. Do you have a test or demo server I could look at? (bit of a long shot!)

    I'm getting exim_paniclog errors on directories such as

    /var/cpanel/domain_keys/

    Thanks

    Scott
     
  4. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,723
    Likes Received:
    660
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    We do not have root SSH access available to the public on our demo servers. Another option to consider would be to migrate the accounts to a new server with a fresh installation of cPanel. Or, move cPanel backups of your accounts to a remote server, reinstall the OS/cPanel, and then restore the accounts.

    Thank you.
     
  5. AoM_Scott

    AoM_Scott Member

    Joined:
    Aug 26, 2010
    Messages:
    7
    Likes Received:
    0
    Trophy Points:
    1
    OK I'll have a think about what to do, at least I can log into cPanel again now.

    Also, bit unrelated but I setup Logaholic on one of my accounts and the stats show for one day and are zero for every day after that? Almost like the log files aren't being processed? This was before my destruction of /var.

    Thanks

    Scott
     
  6. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,723
    Likes Received:
    660
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
Loading...

Share This Page