LSWS 2.2.4 / Solaris hang

zellster

Well-Known Member
#1
OS: Solaris 2.8
Arch: SPARC (64/32-bit)
LiteSpeed: 2.2.4 Standard edition
Location: http://206.117.43.99:8088/

I installed 2.2.4 as a non-root user, and added an entry to the Rails template. However, after a day or so of uptime, LSWS no longer accepts connections. The lshttpd processes are still running and don't appear to be hanging:

[ 33 unknown ~ ] pstack 21291 | c++filt
21291: lshttpd
ff21d344 poll (ffbed980, 1, 3e8)
00017c20 LshttpdMain::guardCrash (26de88, 0, ffbefaa8, 0, 0, ff21f854) + 268
000168dc init__11LshttpdMainiPPc (26de88, 1, ffbefc0c, ff3e7760, 225b4, ff19be98) + 474
00016a54 main__11LshttpdMainiPPc (26de88, 1, ffbefc0c, 300, 225b4, ff19bc08) + 30
00013908 main (1, ffbefc0c, ffbefc14, 2335dc, 0, 0) + b4
0001371c _start (0, 0, 0, 0, 0, 0) + 5c
[ 34 unknown ~ ] pstack 21292 | c++filt
21292: lscgid
ff21d344 poll (ffbefdb8, 1, 3e8)
000124c4 ???????? (23000, 23000, ff23e878, 3, 12b20, 270f8)
000127a4 ???????? (1, ffbeff1c, ff23e5d0, 300, 225b4, ff19bc08)
00012804 ???????? (1, ffbeff1c, ffbeff24, 22fe4, 0, 0)
00010bd0 ???????? (0, 0, 0, 0, 0, 0)
[ 35 unknown ~ ] pstack 21293 | c++filt
21293: lshttpd
ff21d344 poll (275da8, 3, 64)
000ae1f8 waitAndProcessEvents__6Polleri (299d40, 64, ae1bc, 0, 0, 0) + 3c
00065744 EventDispatcher::run (26df7c, 26df7c, 0, 0, 0, 0) + 48
0002d6dc HttpServerImpl::start (26df68, 0, 0, 0, 0, 0) + 108
00030be0 HttpServer::start (2335fc, 1, ffbefc0c, ff3e7760, 225b4, ff19be98) + c
00016a84 main__11LshttpdMainiPPc (26de88, 1, ffbefc0c, 300, 225b4, ff19bc08) + 60
00013908 main (1, ffbefc0c, ffbefc14, 2335dc, 0, 0) + b4
0001371c _start (0, 0, 0, 0, 0, 0) + 5c

There are no ruby processes running. I can supply truss output, or access to the admin site.

Thanks!
 

xing

LiteSpeed Staff
#2
If you have any other relevant ouput regarding this problem, feel free to attach it.

Once we find the cause, we should have this fixed and preped for the 2.2.5 release.
 

zellster

Well-Known Member
#3
I will e-mail short truss runs of the lsws processes. If you would like admin or shell login access, please let me know.

Thanks!
 
Last edited:

zellster

Well-Known Member
#4
The poll handler is broken under Solaris 2.8 with LSWS 2.2.6 and 3.0rc2. Connections hang and timeout. Switching to devpoll fixes the problem.
 

mistwang

LiteSpeed Staff
#5
Thanks for the update, we will take a look.
How long does it take for this problem start to happen? Is it on a i386 system or a SPARC system?
 

zellster

Well-Known Member
#6
Thanks for the update, we will take a look.
How long does it take for this problem start to happen? Is it on a i386 system or a SPARC system?
The problem is immediately apparent. The hardware is SPARC/sun4u. I can send a truss/pstack dump if it would help.
 

zellster

Well-Known Member
#8
Great, I will try the latest 3.0. One thing I did notice in install.sh is the following:

#!/bin/sh

cd `dirname "$0"`
source ./functions.sh

I believe that source is for C shell. The lines should be:

#!/bin/sh

cd `dirname "$0"`
. ./functions.sh

Thanks!
 

zellster

Well-Known Member
#10
Hello,

the current install.sh tries "source ./functions.sh" first, then try ". ./functions.sh" if it fails.
It just seems odd to try and even do a "source" in a Bourne script. Perhaps you should redirect stderr to /dev/null to prevent the error message from being visible to the user.

The poll problem persists in the latest 3.0 release, but it did take longer to reproduce (2-3 hours). Is there a way to run multiple instances of lsws on the same box without colliding? I need to keep port 80 working with /dev/poll but run on port 8088 with poll.

Thanks.
 

mistwang

LiteSpeed Staff
#11
It just seems odd to try and even do a "source" in a Bourne script. Perhaps you should redirect stderr to /dev/null to prevent the error message from being visible to the user.
Some use may use csh as the default shell. Making the install script working on all OS was a big headache. :)
We plan to hide the error message as well.

Is there a way to run multiple instances of lsws on the same box without colliding? I need to keep port 80 working with /dev/poll but run on port 8088 with poll.
We construct a chroot jail manually when we need to run multiple instance of LSWS on the same server.
 
Top