• Dear Pleskians! The Plesk Forum will be undergoing scheduled maintenance on Monday, 7th of July, at 9:00 AM UTC. The expected maintenance window is 2 hours.
    Thank you in advance for your patience and understanding on the matter.

Input Unable to delete web user? Here's how to work around it

websavers

Regular Pleskian
Server operating system version
CentOS 7.9.2009
Plesk version and microupdate number
Version 18.0.50 Update #2
Note this applies only to web users. They appear under FTP Accounts, but are not deleteable from there. If you click on the user then try to delete it from the Plesk GUI while you're using PHP-FPM, it will say:

Unable to execute usermng: usermng: /usr/sbin/userdel execution failed:
userdel: user ACCOUNT is currently used by process PID
usermng: Unable to delete user:

To work around this, run the following from shell:

Bash:
systemctl stop plesk-php81-fpm && systemctl stop plesk-php80-fpm && systemctl stop plesk-php74-fpm

/usr/local/psa/bin/webuser --remove $WEBUSERNAME -domain $DOMAIN

systemctl start plesk-php81-fpm && systemctl start plesk-php80-fpm && systemctl start plesk-php74-fpm

Notes: Do not forget to enter the correct username and the primary domain from the subscription in the middle line. If the web user belongs to a subscription that has any domains within it using a different PHP-FPM version than those above, edit the first and last lines to stop and start those PHP versions.
 
Back
Top