1. Please take a little time for this simple survey! Thank you for participating!
    Dismiss Notice
  2. Dear Pleskians, please read this carefully! New attachments and other rules Thank you!
    Dismiss Notice
  3. Dear Pleskians, I really hope that you will share your opinion in this Special topic for chatter about Plesk in the Clouds. Thank you!
    Dismiss Notice

php: command not found

Discussion in 'Plesk 10.x for Linux Issues, Fixes, How-To' started by cmer, Apr 21, 2011.

  1. cmer

    cmer Guest

    0
     
    Hello,

    I just migeret my site on a server plesk 10.2.0 CentOS on the server there is a user who needs to perform tasks crontab php php -q /var/www/vhosts/blablabla.php but the stain crontab does not work and returns as an error

    Is there a solution??
     
  2. Mickael Salfati

    Mickael Salfati Regular Pleskian

    27
     
    Joined:
    Apr 6, 2009
    Messages:
    178
    Likes Received:
    1
  3. Hostasaurus.Com

    Hostasaurus.Com Regular Pleskian

    30
    68%
    Joined:
    Oct 8, 2009
    Messages:
    465
    Likes Received:
    8
    That command is broken if you give the user chrootsh for the shell; they either need full shell access to run cron jobs, or they need forbidden for that setting to take effect and let them run cron jobs.
     
  4. Bilar_Pip

    Bilar_Pip Guest

    0
     
    I'm running Plesk 10.4.4 and when I tried the command as specified in the Administrator Guide:

    I got the following output:

    I then tried this command:

    and got this output:

    Is this a safe fix?
     
  5. Hostasaurus.Com

    Hostasaurus.Com Regular Pleskian

    30
    68%
    Joined:
    Oct 8, 2009
    Messages:
    465
    Likes Received:
    8
    Currently, that command will only work if the customer is set to have a forbidden shell (and unnecessary if you give them a full shell). If you give your customers chroot bash for their shell, they will not be able to run cron jobs no matter what you do.
     
  6. DaivatS

    DaivatS New Pleskian

    6
     
    Joined:
    Mar 8, 2013
    Messages:
    1
    Likes Received:
    0
    Hello Team,

    I am also facing the same issue on my shared server.
    I tried a lot to run cron script, but getting failure each time.

    Manual says that, we have to run provided command to enable SSH. and then after the cron script can works.

    So my question is that, where to execute command:
    Please help me to fix it ASAP.
     
    Last edited: Mar 8, 2013
  7. Hostasaurus.Com

    Hostasaurus.Com Regular Pleskian

    30
    68%
    Joined:
    Oct 8, 2009
    Messages:
    465
    Likes Received:
    8
    The command that was given includes the full path; you'd run it as root while logged into the server via SSH.

    Keep in mind that it has the limitations I pointed out previously; it is only going to be useful if your customers are set to have a shell of 'Forbidden' and is completely useless if they have a shell of /bin/bash. If you attempt to use it with the more secure option of "/bin/bash (chrooted)" then it will not work and your customers also won't be able to use SSH; i.e. the most secure setting to give your customers breaks their cron jobs.
     
  8. ClassBilisim

    ClassBilisim New Pleskian

    6
     
    Joined:
    May 5, 2014
    Messages:
    2
    Likes Received:
    0
  9. sbillis

    sbillis Basic Pleskian

    24
     
    Joined:
    Mar 2, 2007
    Messages:
    40
    Likes Received:
    1
Loading...