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.

Some script execute permissions gone

Discussion in 'General Discussion' started by pwaara, May 17, 2017.

  1. pwaara

    pwaara Member

    Joined:
    Aug 10, 2016
    Messages:
    16
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Hawaii
    cPanel Access Level:
    Root Administrator
    This morning I saw that cpbackup failed to run due to "Permission denied" error. Looking at the scripts directory, I see several scripts have had their execute permissions removed. They are: cp-backup, make-config, upcp, and update_sa_config. Any ideas what may have happened, and what is the best way to fix the issue? Just go in and update the permissions?
     
  2. cPanelChrisI

    cPanelChrisI Technical Analyst II
    Staff Member

    Joined:
    Mar 24, 2014
    Messages:
    67
    Likes Received:
    11
    Trophy Points:
    83
    cPanel Access Level:
    Root Administrator
    Hello!

    The best way to try to track down how those were changed will likely be to use the stat command to find the times that they were changed before before changing the permissions back, then check the various logs and the bash history for anything that was done around that time. Also, note that /scripts/cp-backup and /scripts/make-config do not exist on my test server and update_sa_config does not have execute permissions. These are the correct permissions for update_sa_config and upcp.

    [root@test3 scripts]# ll update_sa_config
    -rw-r--r-- 1 root root 2083 Feb 17 00:34 update_sa_config

    [root@test3 scripts]# ll upcp
    -rwxr-xr-x 1 root root 28588 Apr 11 11:35 upcp

    Thanks!
     
  3. pwaara

    pwaara Member

    Joined:
    Aug 10, 2016
    Messages:
    16
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Hawaii
    cPanel Access Level:
    Root Administrator
    Sorry, I meant cpbackup.

    Interestingly, the permissions have fixed themselves. I did nothing to change them in either direction. According to stat, the file was modified yesterday, but there is nothing in the history. While this has me curious as to how and why it happened, I don't have the time to track it down. It certainly was odd, though.
     
Loading...

Share This Page