Cpanel User Permissions Problem

Discussion in 'Site & Server Administration' started by blwire, Mar 8, 2010.

  1. #1
    Hey i logged in to check my server today and came across a problem. The permissions on one of my cpanel user's are all messed up. Whenever i browse /user/public_html it won't let me make any changes to any of the files or folders. Has anyone else had this problem and if so how did you fix it? I didn't make any changes or anything it just randomly happened. Also can't chmod any of the files too and a reboot didn't help either. Thanks for the help.
     
    blwire, Mar 8, 2010 IP
  2. RHS-Chris

    RHS-Chris Well-Known Member

    Messages:
    1,007
    Likes Received:
    35
    Best Answers:
    10
    Trophy Points:
    150
    #2
    Are you logged in as the root user?
     
    RHS-Chris, Mar 8, 2010 IP
  3. blwire

    blwire Peon

    Messages:
    85
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Interesting, i can make changes to the folders etc. when i'm logged in as root. I can't though when i login as the designated ftp user though.
     
    blwire, Mar 8, 2010 IP
  4. RHS-Chris

    RHS-Chris Well-Known Member

    Messages:
    1,007
    Likes Received:
    35
    Best Answers:
    10
    Trophy Points:
    150
    #4
    Sounds like the permissions are set wrong for the files, and that user you are logged in as does not have rights to the files. Are the files owned by the correct user/group?
     
    RHS-Chris, Mar 8, 2010 IP
  5. FavouritesBlog

    FavouritesBlog Peon

    Messages:
    846
    Likes Received:
    7
    Best Answers:
    0
    Trophy Points:
    0
    #5
    You need to chown the folders, for some reason the public_html folder or users home folder is not set to the correct user and group.

    google the chown command or example - chown -R userexample:userexample file
     
    FavouritesBlog, Mar 8, 2010 IP
  6. blwire

    blwire Peon

    Messages:
    85
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #6
    So i need to chown the whole user's folder recursively to the designated user? Would this affect any recursive symlinks that are used for user authentication?
     
    blwire, Mar 8, 2010 IP
  7. RHS-Chris

    RHS-Chris Well-Known Member

    Messages:
    1,007
    Likes Received:
    35
    Best Answers:
    10
    Trophy Points:
    150
    #7
    I would question as to why the ownership has changed. The command to change all files and folders under the public_html folder would be:

    chown -R user.group /home/user/public_html

    You need to change the public_html folder back to nobody group when done:

    chgrp nobody /home/user/public_html
     
    RHS-Chris, Mar 8, 2010 IP