You are not logged in or registered. Please login or register to use the full functionality of this board...
Linuxcat.org
Virtuozzo Plesk VPS suexec command not in docroot - Printable Version

+- Linuxcat.org (https://www.linuxcat.org)
+-- Forum: Linux Guides and Troubleshooting (/forumdisplay.php?fid=1)
+--- Forum: Linux Troubleshooting (/forumdisplay.php?fid=3)
+--- Thread: Virtuozzo Plesk VPS suexec command not in docroot (/showthread.php?tid=38)



Virtuozzo Plesk VPS suexec command not in docroot - knifebunny - 10-05-2011 07:34 PM

Plesk uses a modified version of suexec and sometimes up2date maintenance replaces Plesk's version of it.
When that happens, my cgi-bin scripts would fail with the message: "command not in docroot" in suexec.log and I would have to copy Plesk's version of suexec back.

I now have the code below run after up2date. It checks the date on suexec and replaces it with Plesk's psa-suexec if the date has changed:



Quote:#

a1=`ls -la /usr/sbin/suexec | tr "-" " " | gawk '{print substr($0,1,56)}'`

a2=`ls -la /usr/sbin/psa-suexec | tr "-" " " | gawk '{print substr($0,1,56)}'`

if [[ "$a1" != "$a2" ]]

then

cp /usr/sbin/suexec /usr/sbin/suexec-saved-$(date +%Y"-"%m"-"%d)

cp -Rfp /usr/sbin/psa-suexec /usr/sbin/suexec

fi

#