lsphp + lsws 3.3.24 = socket problem

#1
i use litespeed on sharing hosting, i run a multiple user spawned php processes

it works fine until...

if someone spawn a php it will start php process in self management mode
its just ok

but if he dont run another php script in 10min, children will stop, parent will also stop (defined that way to safe memory)

BUT
socket for this process is still there
(
/tmp/phpls_login.sock
/tmp/phpls_login.sock.432
/tmp/phpls_login.sock.622
/tmp/phpls_login.sock.567
)

that repeats itself few times and for example 24h later
client try to run php script and see 503 service unavailable screen

to restore it to work i need to remove all phpls sockets from /tmp
then i just put F5 on browser and everything works fine.

it also work the same with admin_php from lsws panel
for now i need to 2 times go to /opt/lsws/admin/...
and delete socket file to run lsws panel

Why he don't delete sockets?

It is safe to delete it in cron for example every hour?

What can i do to prevent that?

<extProcessor>
<type>lsapi</type>
<name>phpm_login</name>
<address>uds://tmp/phpls_login.sock</address>
<note></note>
<maxConns>8</maxConns>
<env>PHPRC=/address/jasiu300</env>
<env>LSAPI_CHILDREN=10</env>
<env>LSAPI_PGRP_MAX_IDLE=30</env>
<env>LSAPI_MAX_IDLE=300</env>
<env>LSAPI_MAX_PROCESS_TIME=12</env>
<env>LSAPI_AVOID_FORK=1</env>
<initTimeout>60</initTimeout>
<retryTimeout>0</retryTimeout>
<persistConn></persistConn>
<pcKeepAliveTimeout>-1</pcKeepAliveTimeout>
<respBuffer>0</respBuffer>
<autoStart>1</autoStart>
<path>/address/jasiu300/php</path>
<backlog>100</backlog>
<instances>1</instances>
<runOnStartUp></runOnStartUp>
<extMaxIdleTime>-1</extMaxIdleTime>
<priority>5</priority>
<memSoftLimit>280M</memSoftLimit>
<memHardLimit>300M</memHardLimit>
<procSoftLimit>500</procSoftLimit>
<procHardLimit>500</procHardLimit>
</extProcessor>

Thanks for answers.
 

mistwang

LiteSpeed Staff
#2
Which edition of LSWS are you using? we will try to reproduce this problem in our lab.

In the meantime, it is safe to remove those sockets from a cron job.
 
#3
LiteSpeed server 3.3.24

php 5.2.9 + php-litespeed-4.7

Last time:
2009-03-23 13:02:55.244 [NOTICE] The maximum number of file descriptor limit is set to 100000.

First time was 10 000

1024 and less it would even start because i have 3000 domains assigned.

(by the way ls Panel in 3000 domains works sloooow , so to monitor my domains and php i must cut/parse .rtreaport file, maybe it can be set up to be faster?)
 
#7
After upgrade admin panel wont to start, but its no problem.

2009-03-23 19:27:11.978 [STDERR] admin_php: error while loading shared libraries: libjpeg.so.62: cannot open shared object file: No such file or directory

apt-get install libjpeg-dev
all works

So i don't need cron rm /tmp/php*sock ?

I don't want to wake up tomorrow with lots of email from clients :D

Thanks for your help.
 
#8
lsws panel don't want to start for a while, 5 times or something like that
at the end of log it start (error with .vmstats is 'normal' and works ok)

what means that "(null)" in logs?

in /tmp/ i now see only 1 socket for every php,

for admin_php.sock is also only 1, but it was the same 503 error :(

---------------------

2009-03-23 23:16:14.045 [INFO] [1.2.3.4:1501-0#_AdminVHost] ExtConn timed out while processing.
2009-03-23 23:16:14.053 [INFO] [1.2.3.4:1501-0#_AdminVHost] connection to [UDS://tmp/lshttpd/admin_php.sock] on request #0, Connection timed out!
2009-03-23 23:16:24.045 [INFO] [1.2.3.4:1501-0#_AdminVHost] ExtConn timed out while processing.
2009-03-23 23:16:24.045 [INFO] [1.2.3.4:1501-0#_AdminVHost] connection to [UDS://tmp/lshttpd/admin_php.sock] on request #0, Connection timed out!
2009-03-23 23:16:34.079 [INFO] [1.2.3.4:1501-0#_AdminVHost] ExtConn timed out while processing.
2009-03-23 23:16:34.079 [INFO] [1.2.3.4:1501-0#_AdminVHost] connection to [UDS://tmp/lshttpd/admin_php.sock] on request #0, Connection timed out!
2009-03-23 23:16:34.080 [NOTICE] [1.2.3.4:1501-0#_AdminVHost] oops! 503 Service Unavailable
2009-03-23 23:16:34.080 [NOTICE] [1.2.3.4:1501-0#_AdminVHost] Content len: 0, Request line:
(null)
2009-03-23 23:17:01.069 [INFO] [1.2.3.4:1503-0#_AdminVHost] ExtConn timed out while processing.
2009-03-23 23:17:01.069 [INFO] [1.2.3.4:1503-0#_AdminVHost] connection to [UDS://tmp/lshttpd/admin_php.sock] on request #0, Connection timed out!
2009-03-23 23:17:11.033 [INFO] [1.2.3.4:1503-0#_AdminVHost] ExtConn timed out while processing.
2009-03-23 23:17:11.033 [INFO] [1.2.3.4:1503-0#_AdminVHost] connection to [UDS://tmp/lshttpd/admin_php.sock] on request #0, Connection timed out!
2009-03-23 23:17:21.087 [INFO] [1.2.3.4:1503-0#_AdminVHost] ExtConn timed out while processing.
2009-03-23 23:17:21.087 [INFO] [1.2.3.4:1503-0#_AdminVHost] connection to [UDS://tmp/lshttpd/admin_php.sock] on request #0, Connection timed out!
2009-03-23 23:17:21.088 [NOTICE] [1.2.3.4:1503-0#_AdminVHost] oops! 503 Service Unavailable
2009-03-23 23:17:21.088 [NOTICE] [1.2.3.4:1503-0#_AdminVHost] Content len: 0, Request line:
(null)
2009-03-23 23:18:23.088 [INFO] [1.2.3.4:1507-0#_AdminVHost] ExtConn timed out while processing.
2009-03-23 23:18:23.088 [INFO] [1.2.3.4:1507-0#_AdminVHost] connection to [UDS://tmp/lshttpd/admin_php.sock] on request #0, Connection timed out!
2009-03-23 23:18:33.012 [INFO] [1.2.3.4:1507-0#_AdminVHost] ExtConn timed out while processing.
2009-03-23 23:18:33.012 [INFO] [1.2.3.4:1507-0#_AdminVHost] connection to [UDS://tmp/lshttpd/admin_php.sock] on request #0, Connection timed out!
2009-03-23 23:18:43.067 [INFO] [1.2.3.4:1507-0#_AdminVHost] ExtConn timed out while processing.
2009-03-23 23:18:43.067 [INFO] [1.2.3.4:1507-0#_AdminVHost] connection to [UDS://tmp/lshttpd/admin_php.sock] on request #0, Connection timed out!
2009-03-23 23:18:43.068 [NOTICE] [1.2.3.4:1507-0#_AdminVHost] oops! 503 Service Unavailable
2009-03-23 23:18:43.068 [NOTICE] [1.2.3.4:1507-0#_AdminVHost] Content len: 0, Request line:
(null)
2009-03-23 23:20:09.023 [INFO] [1.2.3.4:1517-0#_AdminVHost] ExtConn timed out while processing.
2009-03-23 23:20:09.023 [INFO] [1.2.3.4:1517-0#_AdminVHost] connection to [UDS://tmp/lshttpd/admin_php.sock] on request #0, Connection timed out!
2009-03-23 23:20:19.045 [INFO] [1.2.3.4:1517-0#_AdminVHost] ExtConn timed out while processing.
2009-03-23 23:20:19.046 [INFO] [1.2.3.4:1517-0#_AdminVHost] connection to [UDS://tmp/lshttpd/admin_php.sock] on request #0, Connection timed out!
2009-03-23 23:20:19.191 [NOTICE] [1.2.3.4:1517-0#_AdminVHost] [STDERR] PHP Warning: file(/tmp/lshttpd/.vmstats) [<a href='function.file'>function.file</a>]: failed to open stream: No such file or directory in /opt/lsws/admin/html.4.0/classes/STATS.php on line 163
 
#10
problem isnt disaper ... :(

Now i type
http://[host]:5555/ (LiteSpeed Panel)

and i see:

503 Service Unavailable
The server is temporarily busy, try again later! Powered By LiteSpeed Web Server

There isn't any admin_php process.
I keep trying to refresh, and it start php process for about 3 or 4 refresh ( i didn't count )

Is any other option to work it well other that deleting socket files?

in deleting is one problem, it makes more process that he use, i see from 1 user about 4 parents and more (in self management mode):(
 
#12
mistwang has root access to server, and was on server, but from then he don't say a word about anything.

I'am not going to be mad or something, i know that he has lots of work, and i respect that, but he could say something, maybe i also can help.

I also know that ls is a big project and a good peace of code, so its not that simple to fix.

(and sorry for my English ...)
 
Top