Skip to content
  • Solutions
    By Role
    • For Developers
    • For Content Managers
    • For Agencies
    • For IT Admins
    • For Web Hosters
    • For Developers
    • For Content Managers
    • For Agencies
    • For IT Admins
    • For Web Hosters
    By Infrastructure
    • Overview
    • AWS
    • Microsoft Azure
    • Alibaba Cloud
    • Google Cloud Platform
    • Vultr
    • Overview
    • AWS
    • Microsoft Azure
    • Alibaba Cloud
    • Google Cloud Platform
    • Vultr
    • Digital Ocean
    • Linode
    • Upcloud
    • Oracle
    • OVH
    • Digital Ocean
    • Linode
    • Upcloud
    • Oracle
    • OVH
  • Product
    • Plesk Features
    • Plesk Editions
    • What’s new
    • Pricing
    • Roadmap
    • Lifecycle Policy
    • Extensions Catalogue
  • Pricing
  • Extensions
    Featured Extensions
    • SocialBee
    • WP Toolkit
    • Sitejet Builder for Plesk
    • SEO Toolkit
    • Joomla! Toolkit
    • Premium Email
    • Email Security
    • SocialBee
    • WP Toolkit
    • Sitejet Builder for Plesk
    • SEO Toolkit
    • Joomla! Toolkit
    • Premium Email
    • Email Security
    Bundles and packs:
    • Business and Collaboration Edition
    • WP pack
    • Hosting pack
    • Power pack
    • Language pack
    • Business and Collaboration Edition
    • WP pack
    • Hosting pack
    • Power pack
    • Language pack

    See all Extensions

  • For Partners
    • Plesk Contributor Program
    • Plesk Partner Program
    • Affiliate program
    • Plesk University
  • Help Center
    • Documentation
    • Professional Services
    • Support
    • Contact Us
    • Wiki
    • Forum
  • Plesk 360 login
  • Free Trial
  • Pricing
  • Solutions
    • By Role
      • For Developers
      • For Content Managers
      • For Agencies
      • For IT Admins
      • For Web Hosters
    • By Infrastructure
      • Overview
      • Plesk on Amazon Web Services (AWS & Lightsail)
      • Microsoft Azure
      • Alibaba Cloud
      • Google Cloud Platform
      • Vultr
      • DigitalOcean
      • Linode
      • UpCloud
      • Oracle
      • OVH
  • Products
  • Pricing
  • Extensions
    • Featured Extensions
      • SocialBee
      • WP Toolkit
      • Sitejet Builder for Plesk
      • SEO Toolkit
      • Joomla! Toolkit
      • Premium Email
      • Email Security
    • Bundles and packs:
      • Business and Collaboration Edition
      • WP pack
      • Hosting pack
      • Power pack
      • Language pack
      • See all Extensions
  • For Partners
    • Plesk Contributor Program
    • Plesk Partner Program
    • Affiliate Program
    • Plesk University
  • Help Center
    • Documentation
    • Professional Services
    • Support
    • Contact Us
    • Wiki
    • Forum
  • Plesk 360 login
  • Free Trial
  • Pricing
  • Solutions
    • By Role
      • For Developers
      • For Content Managers
      • For Agencies
      • For IT Admins
      • For Web Hosters
    • By Infrastructure
      • Overview
      • Plesk on Amazon Web Services (AWS & Lightsail)
      • Microsoft Azure
      • Alibaba Cloud
      • Google Cloud Platform
      • Vultr
      • DigitalOcean
      • Linode
      • UpCloud
      • Oracle
      • OVH
  • Products
  • Pricing
  • Extensions
    • Featured Extensions
      • SocialBee
      • WP Toolkit
      • Sitejet Builder for Plesk
      • SEO Toolkit
      • Joomla! Toolkit
      • Premium Email
      • Email Security
    • Bundles and packs:
      • Business and Collaboration Edition
      • WP pack
      • Hosting pack
      • Power pack
      • Language pack
      • See all Extensions
  • For Partners
    • Plesk Contributor Program
    • Plesk Partner Program
    • Affiliate Program
    • Plesk University
  • Help Center
    • Documentation
    • Professional Services
    • Support
    • Contact Us
    • Wiki
    • Forum
  • Plesk 360 login
  • Free Trial
Plesk 360 login
Free Trial

Knowledge Base

Increased memory usage by PHP-CGI processes on server after Plesk update

 
apachecpudomainsdowntimefastcgi

Symptoms

  • The memory usage increased after installing Plesk updates.

  • RAM is used by dozens of php-cgi processes started by Apache:

    # top
    PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
    26267 johndoe+ 20 0 810324 72704 3372 S 0.0 0.5 0:01.62 /opt/plesk/php/5.3/bin/php-cgi -c /var/www/vhosts/system/example.com/etc/php.ini
    10022 janedoe+ 20 0 809084 71940 2108 S 0.7 0.5 0:01.72 /opt/plesk/php/5.3/bin/php-cgi -c /var/www/vhosts/system/example1.com/etc/php.ini
    996 jadedoe+ 20 0 814800 68728 10556 S 0.0 0.5 0:04.24 /opt/plesk/php/5.3/bin/php-cgi -c /var/www/vhosts/system/example2.com/etc/php.ini

  • Very big timeouts are specified in /etc/httpd/conf.d/fcgid.conf :

    FcgidIdleTimeout 2100
    FcgidProcessLifeTime 2100
    FcgidMaxProcesses 300
    FcgidConnectTimeout 2100
    FcgidIOTimeout 2100
    FcgidBusyTimeout 2100

Cause

PHP-CGI processes are consuming too much memory due to big timeout values in FastCGI configuration.

Resolution

Solution 1

  1. Connect to the server via SSH

  2. Open /etc/httpd/conf.d/fcgid.conf in any text editor

  3. Decrease timeouts to lower values to finish php-cgi processes earlier, and execute service httpd reload command to reload Apache configuration. Default values are:

    FcgidIdleTimeout 40
    FcgidProcessLifeTime 30
    FcgidMaxProcesses 20
    FcgidConnectTimeout 30
    FcgidIOTimeout 45
    FcgidIdleScanInterval 10

    Note: The drawback of this solution is the possible failure of long-running PHP scripts. If you are sure that there is no any on the server, you can follow this option.

Solution 2

Log in to Plesk, go to Domains > example.com > PHP settings and set PHP version to 7.0.33 and handler to FPM application served by nginx:
php.JPG

Perform these configuration changes for every domain one by one.

Note: The drawback of this solution is possible websites' downtime due to switching to nginx. For example, domain-level .htaccess files can not be handled anymore, that can lead to website downtime. That's why it was recommended to switch the websites one by one, checking their availability.

Tweet
Share
Share
Email
0 Shares
Read the full article
Related Posts

Your Complete .htaccess Guide: Including .htaccess Basics and More

Read More »

NGINX vs Apache – Which Is the Best Web Server in 2024?

Read More »

PHP-FPM: The Future of PHP Handling

Read More »
Knowledge Base

 Website pages based on WordPress show “404 Not Found” when PHP-FPM by Apache is used

Read More »

[BUG] nginx shows configuration error in Plesk: “proxy_read_timeout” directive is duplicate

Read More »

Websites hosted on Plesk server are unavailable with 502 Bad Gateway: upstream sent too big header while reading response header

Read More »

After switching a website to FPM served by nginx in Plesk, it fails to load with “404 Not Found” on all pages except start page

Read More »

Hosting Wiki

  • Django
  • Server Redundancy
  • Google Cloud CDN
  • CGI
  • htaccess
  • Bare Metal Server
  • PhpMyAdmin
  • phpPgAdmin
  • Oracle VM Server
  • Server Virtualization Software
  • Windows Server
  • Linux
  • PHP
  • MongoDB
  • Domain
  • Plesk
  • Apache Tomcat
  • NGINX
  • Apache
  • Web Server
  • DNS Server
  • SSH
X-twitter Linkedin Youtube Reddit Github
  • Product
  • Login
  • Pricing
  • Editions
  • For Partners
  • Partner Program
  • Contributor Program
  • Affiliate Program
  • Plesk University
  • Company
  • Blog
  • Careers
  • Events
  • About Plesk
  • Our Brand
  • Resources
  • User and Admin guides
  • Help Center
  • Migrate to Plesk
  • Contact Us
  • Hosting Wiki
  • Forum
  • Legal
  • Legal
  • Privacy Policy
  • Imprint

© 2025 WebPros International GmbH

Part of the WebPros®  Family