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.

public_html folder auto chmoded to 750 after unsuspend

Discussion in 'General Discussion' started by simonlee, Oct 15, 2003.

  1. simonlee

    simonlee Active Member

    Joined:
    Jan 19, 2003
    Messages:
    37
    Likes Received:
    0
    Trophy Points:
    6
    Sometime after I unsuspended a user in PHP script, the client complained that his public_html folder was auto chmoded to 750.

    It's not very often, but happened twice.

    Could somebody here to tell if it is possible, is it a bug of cPanel PHP Accounting module?

    cPanel.net Support Ticket Number:
     
  2. HollyRidge

    HollyRidge Well-Known Member

    Joined:
    Feb 25, 2003
    Messages:
    138
    Likes Received:
    2
    Trophy Points:
    18
    Location:
    Garner NC USA
    cPanel Access Level:
    Root Administrator
    Hmmm been sitting here for over an hour trying to figure out what was going on. It appears the same thing happened to me. I chmoded the folder back to 755 and the account is now working again. Anyone got a solution for this?
     
  3. ciphervendor

    ciphervendor Well-Known Member

    Joined:
    Aug 26, 2002
    Messages:
    1,052
    Likes Received:
    0
    Trophy Points:
    36
    Code:
    phoenix:~# grep 750 /scripts/unsuspendacct 
            chmod 0750, "${homedir}/public_html";
    phoenix:~# 
     
  4. HollyRidge

    HollyRidge Well-Known Member

    Joined:
    Feb 25, 2003
    Messages:
    138
    Likes Received:
    2
    Trophy Points:
    18
    Location:
    Garner NC USA
    cPanel Access Level:
    Root Administrator
    Shouldnt it be 755 instead of 750? It doesnt work on 750 but does on 755. If on 750 get forbidden pages.

    Also if edit that file as soon as you run /scripts/updatenow its going to over write it. If the file is chattr'd then it wont get updated.
     
  5. Website Rob

    Website Rob Well-Known Member

    Joined:
    Mar 23, 2002
    Messages:
    1,506
    Likes Received:
    0
    Trophy Points:
    36
    Location:
    Alberta, Canada
    cPanel Access Level:
    Root Administrator
    Not sure if the permission settings are a bug within any WHM/Cpanel scripts, but figure it does fall within regular SysAdmin maintanence.

    As for home directories, where are people getting 755 from? All mine -- different Servers, OSs, WHM releases -- are 711.

    ls -lh /home
     
  6. HollyRidge

    HollyRidge Well-Known Member

    Joined:
    Feb 25, 2003
    Messages:
    138
    Likes Received:
    2
    Trophy Points:
    18
    Location:
    Garner NC USA
    cPanel Access Level:
    Root Administrator
    Rob the problem is the public_html folder inside of the users folder being chmoded to 750 instead of 755.
     
  7. Website Rob

    Website Rob Well-Known Member

    Joined:
    Mar 23, 2002
    Messages:
    1,506
    Likes Received:
    0
    Trophy Points:
    36
    Location:
    Alberta, Canada
    cPanel Access Level:
    Root Administrator
    Ok, point taken. New check, on Servers same as above, showed 'public_html' dir. as 750. This is normal if one is using the 'web protect' feature and the catch is, the grp owner must be nobody.

    This confused the hell out of me when doing some recent tranfers as grp owner was under the account owner id and wasn't working.

    A ticket to DarkOrb provided me with the above answer and it works just fine with all accounts.
     
  8. HollyRidge

    HollyRidge Well-Known Member

    Joined:
    Feb 25, 2003
    Messages:
    138
    Likes Received:
    2
    Trophy Points:
    18
    Location:
    Garner NC USA
    cPanel Access Level:
    Root Administrator
    That makes good sense then... Just one thing... Wonder why they are not chowning the files to user.nobody then?
     
  9. Website Rob

    Website Rob Well-Known Member

    Joined:
    Mar 23, 2002
    Messages:
    1,506
    Likes Received:
    0
    Trophy Points:
    36
    Location:
    Alberta, Canada
    cPanel Access Level:
    Root Administrator
    Probably due to the coding required, to check the Receiving Server for whether 'web protect' is ON or OFF. Much easier (for DarkOrb) to leave that up to the Server Admin and adjust accordingly -- that is, as long as one knows what the problem is and how to correct it. ;)
     
  10. jamesbond

    jamesbond Well-Known Member

    Joined:
    Oct 9, 2002
    Messages:
    738
    Likes Received:
    1
    Trophy Points:
    18
    In my opinion this is lazy (or sloppy) scripting. Ofcourse one needs to know how to manage a server, but why would it be acceptable to have scripts causing these problems when the web protect feature is incorporated in WHM?

    A decent script should check these things before applying changes.

    Actually I think many of the 'strange issues' that occur when certain cpanel scripts get executed are a result of not checking if files exist, what options have been set etc.

    I've always thought it was common programming practise to build in these checks. It's only a couple of extra lines of code in most cases.
     
  11. HollyRidge

    HollyRidge Well-Known Member

    Joined:
    Feb 25, 2003
    Messages:
    138
    Likes Received:
    2
    Trophy Points:
    18
    Location:
    Garner NC USA
    cPanel Access Level:
    Root Administrator
    That is basically what I was saying as well james. I think this should be built in for these checks and in this case I cant see it being more than a couple of lines of code. Its not as bad knowing about this but getting a lot of tickets from this as well.
     
  12. pingo

    pingo Well-Known Member

    Joined:
    Nov 16, 2002
    Messages:
    430
    Likes Received:
    0
    Trophy Points:
    16
    I am experiencing the same. A client account were suspended and then unsuspended whereafter permissions for public_html changed to 750. - I also have another client who opened a ticket just a few minutes ago. We, and he, didn't touch this account, but in some way his public_html folder were chmoded to 750 as well. Hmm, I wonder what is going on.

    John
     
Loading...

Share This Page