Not reloading on changes

felosi

Well-Known Member
#1
I have a sevrer in which lsws is not reloading on changes. I tried the binary wrapper and when you issue the restart script from cpanel, it shows it giving signal and whatnot but the pids are same and it does not reload.

This has been a problem when new domains and subdomains are added.

Here is example
root@sl [~]# nano -w /scripts/restartsrv_httpd*
root@sl [~]# ps -u nobody
PID TTY TIME CMD
9829 ? 00:00:02 lshttpd
9832 ? 00:00:02 lshttpd
10688 ? 00:00:00 lshttpd
10689 ? 00:00:00 lshttpd
10690 ? 00:00:00 lshttpd
10691 ? 00:00:00 lshttpd
10692 ? 00:00:00 lshttpd
10693 ? 00:00:00 lshttpd
10694 ? 00:00:00 lshttpd
10695 ? 00:00:00 lshttpd
root@sl [~]# /scripts/restartsrv_httpd
root@sl [~]# ps -u nobody
PID TTY TIME CMD
9829 ? 00:00:02 lshttpd
10688 ? 00:00:00 lshttpd
10689 ? 00:00:00 lshttpd
10690 ? 00:00:01 lshttpd
10691 ? 00:00:00 lshttpd
10692 ? 00:00:00 lshttpd
10693 ? 00:00:00 lshttpd
10694 ? 00:00:00 lshttpd
10695 ? 00:00:00 lshttpd
10917 ? 00:00:00 lshttpd
10918 ? 00:00:00 lshttpd
10919 ? 00:00:00 lshttpd
10920 ? 00:00:00 lshttpd
10921 ? 00:00:00 lshttpd
10923 ? 00:00:00 lshttpd
10924 ? 00:00:00 lshttpd
10925 ? 00:00:00 lshttpd
root@sl [~]# ps -u nobody
PID TTY TIME CMD
9829 ? 00:00:02 lshttpd
10692 ? 00:00:00 lshttpd
10917 ? 00:00:00 lshttpd
10918 ? 00:00:00 lshttpd
10919 ? 00:00:00 lshttpd
10920 ? 00:00:00 lshttpd
10921 ? 00:00:00 lshttpd
10923 ? 00:00:00 lshttpd
10924 ? 00:00:00 lshttpd
10925 ? 00:00:00 lshttpd

Seems like it cannot kill the process or something.

I tried auto reload on changes and got same effect
 

felosi

Well-Known Member
#3
Ok I totally deleted the old directory and done a fresh install. Same thing, showing over 2gb ram usage. Will not restart/reload after config is added to. Graceful restart does not work, must kill -9 the lshttpd in order for it to reload.

This is an 8 core license, is it possible this is the problem?
 

auser

Super Moderator
#4
since 8 core license, there'll be 9 lshttpd processes running.
assume each process consume 200MB memory, the total memory usage may be reported as 200MB x 9 = 1.8G. but needn't worry much, since within the 200MB memory, many of them are shared. the memory usage reported by "top" is same case. using "free -m" can check the actually available memory.

using "pmap -x <pid of an process>" can display the memory map of the process.

however I have no clue about why graceful restart not working well.
 

felosi

Well-Known Member
#5
Got the restart thing resolved with George via email. thanks George!

Ram usage is still showing well over 2gb, Awaiting his reply on that. It may be normal for 8 core but my 4 core servers show no where near half of that.
 
Top