• Plesk Uservoice will be deprecated by October. Moving forward, all product feature requests and improvement suggestions will be managed through our new platform Plesk Productboard.
    To continue sharing your ideas and feedback, please visit features.plesk.com

Issue run-parts: /etc/cron.daily/pleskupdate exited with return code 1

@mxk thx a lot, where exactly do i find that script?

still does not seem that strato will fix that problem anymore so u would help a lot of us i believe :)
It is the mentioned
/etc/cron.daily/pleskupdate

After a few weeks now, I have not received any further mail with a fail.
 
Thank you so much.
After a couple of weeks i can say, that it works 75% if the time. So i switched to a sleep of 240 and i think it works.*

thanks again for the fix
 
I had the same issue with a root server from Strato. For analysis I have executed the script /etc/cron.daily/pleskupdate directly. Most time the response code was 0, so there was not a directly problem with it. But when I have used run-parts --report /etc/cron.daily, what is used by the server to start automatically all scripts in this directory, I have received the annoying mail with the info "run-parts: /etc/cron.daily/pleskupdate exited with return code 1". A directly start of /etc/cron.daily/pleskupdate afterwards have then also finished with return code 1.

I have noticed the message "Update operation was locked by another update process." in the autoinstaller3.log. Maybe there are some other scripts in /etc/cron.daily, that are blocking something for a short time?!

So I have added a simple sleep to the pleskupdate script, what at first glance solved the issue on my server.

This is the current script:

Bash:
#!/bin/sh
# Plesk autoinstaller
sleep 120
/usr/local/psa/admin/sbin/autoinstaller --select-product-id plesk --select-release-current --install-component base >/dev/null 2>&1
Exactly, I think that it was just lock collision too...

I checked first with this code

sudo run-parts --report /etc/cron.daily
sudo tail -n 100 /var/log/plesk/install/autoinstaller3.log | grep -i lock -n

It tells

run-parts: /etc/cron.daily/pleskupdate exited with return code 1
100:[2025-09-04 13:50:41.462797] Update operation was locked by another update process.

Then i backed the script up:

sudo cp /etc/cron.daily/pleskupdate /etc/cron.daily/pleskupdate.bak

An then used this script:

sudo bash -c 'cat >/etc/cron.daily/pleskupdate <<EOF
#!/bin/sh
LOG=/var/log/plesk/cron-pleskupdate.log
LOCK=/run/lock/pleskupdate.lock

# random jitter (0–299s) so we don’t collide with other daily jobs
sleep "\$(awk '\''BEGIN{srand(); print int(rand()*300)}'\'')"

# run only if we can acquire the lock; if locked, exit 0 to avoid spammy mails
if command -v flock >/dev/null 2>&1; then
/usr/bin/flock -n "\$LOCK" -c "/usr/local/psa/admin/sbin/autoinstaller \
--select-product-id plesk \
--select-release-current \
--install-component base >>\"\$LOG\" 2>&1" || exit 0
else
sleep 240
/usr/local/psa/admin/sbin/autoinstaller \
--select-product-id plesk \
--select-release-current \
--install-component base >>\"\$LOG\" 2>&1 || exit 0
fi

exit 0
EOF'
sudo chmod 755 /etc/cron.daily/pleskupdate

Not sure if my script is totally fine bu so far no problem... I don't receive those fail mails anymore...
 
Back
Top