Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
litespeed_wiki:php_503_error [2015/06/22 03:40]
Gary Duan [6. zend_extension Instead of extension and Vice Versa]
litespeed_wiki:php_503_error [2015/07/28 13:11]
Michael Alegre removed
Line 196: Line 196:
   "​Restart Lfd"   "​Restart Lfd"
  
 +===== 8. lsphp process hit memory limit =====
 +
 +when define a lsphp external application,​ there are 2 litespeed specific settings:
 +
 +  * Memory Soft Limit (bytes) (https://​www.litespeedtech.com/​docs/​webserver/​config/​extapps#​memSoftLimit)
 +  * Memory Hard Limit (bytes) (https://​www.litespeedtech.com/​docs/​webserver/​config/​extapps#​memHardLimit)
 +
 +As stated in the document: "The main purpose of this limit is to prevent excessive memory usage because of software bugs or intentional attacks, not to impose a limit on normal usage. Make sure to leave enough head room, otherwise your application may fail and 503 error may be returned."​
 +
 +so for example in a shared hosting server, with memory soft/hard limit set, if an php script in an account consumes too many memory, it'll fail(return 503 error) and other accounts are not affected. the ideal solution is to optimize the php script to consume less memory. A quick and temporary workaround is to raise the soft/hard limit to a big value(for example 8G), to see if the 503 error will be gone. here's a use case : https://​www.litespeedtech.com/​support/​forum/​threads/​solved-xenforo-rebuild-attachment-thumbnails-503.12403/​
 ====== Real World Examples ====== ====== Real World Examples ======