Select Page

How to resolve “Resource temporarily unavailable” error in SSH for cPanel servers

Here at Bobcares, we provide Server Administration and Maintenance services to cPanel/WHM server owners.

An error we sometimes see in cPanel servers while trying to SSH is : “Resource temporarily unavailable.”

This error is usually accompanied by the error ‘too many processes’, while trying to do ‘sudo su -‘ command, which is used to elevate the privileges of a wheel user to that of a root user.

 

What is the error “Resource temporarily unavailable” during SSH

Fork bomb attacks in servers are performed by attackers using a cascade of small processes that duplicate themselves, until the server’s resources are depleted. This is performed via shell.

To protect cPanel servers from such attack, cPanel offers a Fork Bomb Protection. It denies users who have terminal access (SSH/Telnet) from using up all the resources on the server.

This protection is enabled with these steps:

1 Click on Server Setup, on the main WebHost Manager interface.

2 Click on Shell Fork Bomb Protection.

3 Click on Enable Protection.

But, this protection can hinder the normal functioning of SSH access at times, when users cannot SSH or sudo using the account, and instead face the error “Resource temporarily unavailable”.

Today, we’ll look at the reason for this SSH failure, and the fix:

 

Resolving “Resource temporarily unavailable” error in cPanel servers

This happens because the Shell Fork Bomb Protection that is enabled in WHM. This protection is used to prevent Telnet/SSH users using all of the server resources and causing a system crash.

For example, while trying to SSH as a user to the server, or while trying to elevate the privileges of a wheel user to a root user,  you’ll see these errors:

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
wheel432@wheeluser.com [~]# su -
Password:
su: cannot set user id: Resource temporarily unavailable
wheel432@wheeluser.com [~]# sudo su -
sudo: PERM_ROOT: setresuid(0, -1, -1): too many processes
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

After you have enabled shell fork bomb protection, the following limits are available to better protect the server:

Limit  Description
200000  maximum size of core files created.
100  maximum number of open-file descriptors.
35  maximum number of processes available to a single user.
200000 maximum amount of virtual memory available for the process.

When the user’s limit exceeds the allotted limits of these resources, it can give out “Resource temporarily unavailable” error while trying to SSH your cPanel server.

If you are facing this error and need expert help to fix it, click here to request expert assistance.

 

How to fix “Resource temporarily unavailable” error in cPanel servers

This error occurs due to shell fork bomb protection enabled in WHM for protecting your cPanel server from resource overload attacks.

The two variations of this error are:

  • su: cannot set user id: Resource temporarily unavailable
  • sudo: PERM_ROOT: setresuid(0, -1, -1): too many processes

 

To fix this, you’ll need to remove the shell fork bomb protection for the server from the WHM => ‘Server Setup’.

If you still face issues, our cPanel experts can fix this for you in an hour. Click here to go to our server administration services page.

 

Conclusion

“Resource temporarily unavailable” is a class of errors in cPanel & WHM servers. It is shown when users are unable to connect to the server via SSH. Today we’ve seen the common causes for this error, and how to fix them.

 

 


SSH ERRORS IN YOUR CPANEL SERVER?

Our server experts will resolve your service related errors, manage and monitor your servers, secure and tweak your services, so that you never have to worry about server errors again.

Contact us for expert assistance!

RESOLVE YOUR SERVER ERRORS.

Submit a Comment

Your email address will not be published. Required fields are marked *

Bobcares
Bobcares is a server management company that helps businesses deliver uninterrupted and secure online services. Our engineers manage close to 51,500 servers that include virtualized servers, cloud infrastructure, physical server clusters, and more.
MORE ABOUT BOBCARES

Privacy Preference Center

    Necessary

    Necessary cookies help make a website usable by enabling basic functions like page navigation and access to secure areas of the website. The website cannot function properly without these cookies.

    PHPSESSID - Preserves user session state across page requests.

    gdpr[consent_types] - Used to store user consents.

    gdpr[allowed_cookies] - Used to store user allowed cookies.

    PHPSESSID, gdpr[consent_types], gdpr[allowed_cookies]
    PHPSESSID
    WHMCSpKDlPzh2chML

    Statistics

    Statistic cookies help website owners to understand how visitors interact with websites by collecting and reporting information anonymously.

    _ga - Preserves user session state across page requests.

    _gat - Used by Google Analytics to throttle request rate

    _gid - Registers a unique ID that is used to generate statistical data on how you use the website.

    smartlookCookie - Used to collect user device and location information of the site visitors to improve the websites User Experience.

    _ga, _gat, _gid
    _ga, _gat, _gid
    smartlookCookie

    Marketing

    Marketing cookies are used to track visitors across websites. The intention is to display ads that are relevant and engaging for the individual user and thereby more valuable for publishers and third party advertisers.

    IDE - Used by Google DoubleClick to register and report the website user's actions after viewing or clicking one of the advertiser's ads with the purpose of measuring the efficacy of an ad and to present targeted ads to the user.

    test_cookie - Used to check if the user's browser supports cookies.

    1P_JAR - Google cookie. These cookies are used to collect website statistics and track conversion rates.

    NID - Registers a unique ID that identifies a returning user's device. The ID is used for serving ads that are most relevant to the user.

    DV - Google ad personalisation

    IDE, test_cookie, 1P_JAR, NID, DV, NID
    IDE, test_cookie
    1P_JAR, NID, DV
    NID