There can be connectivity issues between the Linux servers hosting your application that cause the 503 service unavailable error. One of the easiest ways to fix the 503 service temporarily unavailable error is to follow this knowledge base article.
Step 1
First you have to check if the website is a node.js/python hosted website. If yes, then go for node.js/python solutions :
Nodejs :
Cpanel >> node.js >> open the application >> switch to the source path from terminal >> run the application : npm start / node app.js runserver & (main file may be app.js, test.js,depends)
If the error occurs for : port is already in use then :
netstat -nap | grep :port no.
lsof -p 21069
where 21069 = pid
kill -9 21069
Restart the application and again run the application.
Check whether the website is proxy based or not,in that order check the proxy.
Python :
Cpanel >> node.js >> open the application >> switch to the source path from terminal >> run the application : python3 manage.py runserveror python manage.py runserver &
Follow the steps as above as for node.js
Step 2
You need to check the resources of the account. If they are high, you need to optimize the resources of the account.
Step 3
Check if there is load on the server. If yes, reduce the server load.
Step 4
Enable debug mode for the website (If WP site >>in wp-config, edit the value of debug from false to true / If other site then enable the debug logs from php ini editor in cPanel ) Exact error will get displayed on the site.)
Step 5
Here is the error that you will get on the screen.
“Error :
You will get a memory exhaust error message.
*Allowed memory size of 41943040 bytes exhausted (tried to allocate 32768 bytes) in /home/mumbai/public_html/wp-content/plugins/userswp/vendor/ayecode/wp-super-duper/wp-super-duper.php on line 3060:
To resolve such errors, Increase the values in the multi PHP INI editor.”
Step 6
If error is related to plugin/theme, then scan the security measures from wp-toolkit, and then you must know that there is error for the respective plugin , theme ,
Ask the web hosts tech team to disable the plugin, with no changes in the theme.
Step 7
Check applying different suitable PHP versions to the site (On priority: 5.6, 7.3, 8.0 and above).
That is how you can resolve 503 error on Linux operating systems compatible servers.