Plesk

Low server performance: WP Toolkit processes spawned by UI/API/CLI are stuck

Symptoms

Cause

Broken or compromised with malware WordPress instance affects WP Toolkit processes.

Resolution

As workaround:

  1. Log into Plesk.

  2. Detach broken or affected WordPress instances from the WP Toolkit:

    Go to Domains > example.com > WordPress, find the affected instance, click the button and click Detach:

  3. Resolve the issue on a per-instance basis. It can be performed:

  4. Kill stuck processes:

    • In Plesk for Linux:

      Connect to the server using SSH and check whether or not there are some stuck processes still. Kill them in case they are:

      # ps aux | grep safe_mode | grep -v grep

      jdoe 812014 203.0.113.2 347652 21328 ? R 00:01 728:37 /opt/plesk/php/7.0/bin/php -d safe_mode=off -d display_errors=off -d opcache.enable_cli=off -d open_basedir= -c /var/www/vhosts/system/example.com/etc/php.ini /usr/local/psa/admin/plib/modules/wp-toolkit/vendor/wp-cli/wp-cli/bin/../php/boot-fs.php --path=/var/www/vhosts/example.com/httpdocs instance info --format=json --check-updates=true --quiet

      # kill -9 812014

    • For Windows:

      Connect to the server using RDP, open Task Manager, kill stuck processes by right-clicking on them and selecting End Task.

  5. After the WordPress instances are clean from malicious scripts, reattach the instance to WP Toolkit by running Scan in Plesk > WordPress.