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.

Rebuild permissions and chmod

Discussion in 'General Discussion' started by thealee, Oct 5, 2006.

  1. thealee

    thealee Member

    Joined:
    Oct 5, 2006
    Messages:
    16
    Likes Received:
    0
    Trophy Points:
    1
    Hi there,

    Is there any way to rebuild the permissions on the folders in /home (the user's files) and make their chmods of the public html etc. workable.

    Currently my website shows up as "You don't have permission to access / on this server."

    Help!

    -Alee
     
  2. Manuel_accu

    Manuel_accu Well-Known Member

    Joined:
    Jun 19, 2005
    Messages:
    191
    Likes Received:
    0
    Trophy Points:
    16
    Are all folders affected with this issue?

    Try using chmod <> command.

    also check the ownership and group of particulare folder in /home


    Thanks,
     
  3. jester.ro

    jester.ro Well-Known Member
    PartnerNOC

    Joined:
    Feb 6, 2004
    Messages:
    304
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Bucharest, Romania
    cPanel Access Level:
    DataCenter Provider
    Are yous sure you have an index.html or index.php in public_html ?

    you could try running /scripts/chownpublichtmls in a shell.
    (i've never tried it tough, i have no idea if it can break anything)
     
  4. mambovince

    mambovince Well-Known Member

    Joined:
    Jan 15, 2005
    Messages:
    192
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    London, UK
    I have used it many time and works fine, and fixes on all domains on that server.

    If you need to just run on one user account, use the following from SSH:

    cd /home/username/public_html/
    chown -R username:username *

    - Vince
     
  5. brianoz

    brianoz Well-Known Member

    Joined:
    Mar 13, 2004
    Messages:
    1,146
    Likes Received:
    6
    Trophy Points:
    38
    Location:
    Melbourne, Australia
    cPanel Access Level:
    Root Administrator
    chownpublichtmls while a useful command will not solve this problem if I'm correct.

    The message you mention comes from apache and means that there is no index file in that directory (ie public_html probably), and that 'Options -Indexes' is set (rather than 'Options Indexes'). The fix is to place an index file in there, ie restore the site files from elsewhere correctly, or create an index.htm/index.html/index.php file; or, in the unlikely event that you need it to work this way, edit .htaccess to enable the default indexing ('Options Indexes' - but don't do this, as this weakens security, and the fix is probably to restore the site files correctly).
     
  6. levelsupport

    levelsupport Well-Known Member

    Joined:
    Oct 7, 2006
    Messages:
    47
    Likes Received:
    0
    Trophy Points:
    6
    try runnning these commands
    chmod 750 /home/username/public_html

    make sure you have a index.html or index.php on that directory
    if your file is index.html and if its permission is correct AND STILL if you get this error
    open your httpd.conf
    and try adding this below your domain virtual host



    right after
    DocumentRoot entry
     
Loading...

Share This Page