• We value your experience with Plesk during 2024
    Plesk strives to perform even better in 2025. To help us improve further, please answer a few questions about your experience with Plesk Obsidian 2024.
    Please take this short survey:

    https://pt-research.typeform.com/to/AmZvSXkx
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.

Issue Scheduled Tasks/Cron

chapterjason

New Pleskian
Server operating system version
Debian 12.8
Plesk version and microupdate number
v18.0.66_build1800241206.15
Hello,

I use scheduled tasks to run a PHP script under a specific version for a specific subscription.
The PHP script does some tasks, simplified to starting a screen (with -dmS to make it detached and prevent it from being killed when the parent process—the cron job itself(?)—is done). It also checks if the screen is already running, etc.

What I’ve realized is that it works if I have a cron job set to run every 5 minutes (or at whatever interval I want), but if I try to start it manually by clicking "Run now," it gets killed somehow (likely by the parent process). I couldn’t find any documentation explaining the difference. It would be great if it worked when using "Run now" as well.

Cheers!
 
Hello! Could you please reproduce the issue and check Plesk log:

1) Connect to the server via SSH
2) Run the following command:
Code:
tail -fn0 /var/log/plesk/panel.log
3) Go to Plesk GUI and click "Run now" for required task
4) Get back to SSH and check output of tail command for any errors

If there are any errors you can provide here output as it may help identify cause of the issue.
 
Forgot the output:


Code:
Dec 18 14:58:35 HOSTNAME systemd[1]: Started run-plesk-task-44414.service - Plesk task: scheduler-run-task (task=44414 process=44414 trace=3617:6762d50baa119).
Dec 18 14:58:35 HOSTNAME crontab[7221]: (root) LIST (SUBSCRIPTION-NAME)
Dec 18 14:58:36 HOSTNAME systemd[1]: Stopping run-plesk-task-44414.service - Plesk task: scheduler-run-task (task=44414 process=44414 trace=3617:6762d50baa119)...
Dec 18 14:58:36 HOSTNAME systemd[1]: run-plesk-task-44414.service: Deactivated successfully.
Dec 18 14:58:36 HOSTNAME systemd[1]: Stopped run-plesk-task-44414.service - Plesk task: scheduler-run-task (task=44414 process=44414 trace=3617:6762d50baa119).
 
Back
Top