LSTSRV-L Archives

LISTSERV Site Administrators' Forum

LSTSRV-L

Options: Use Monospaced Font
Show HTML Part by Default
Show All Mail Headers

Topic: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Eric Thomas <[log in to unmask]>
Fri, 23 Sep 2016 02:45:28 +0000
text/plain (2673 bytes) , text/html (8 kB)
I am not familiar with RHEL 7, but 'kill' is pretty much the equivalent of sending a SHUTDOWN command via 'lcmd' and should get rid of all worker processes once they complete their current transaction. You should see a SHUTDOWN command in the log from [log in to unmask] If you somehow end up doing 'kill -9' instead, the workers will remain until they exit due to not finding the main process when they need to signal it, which could take a while, possibly forever. I would check the log to see what happens when the 'kill' is issued, as well as trying it from the command line.

  Eric

From: LISTSERV Site Administrators' Forum [mailto:[log in to unmask]] On Behalf Of Scott Kraczek
Sent: Thursday, September 22, 2016 17:22
To: [log in to unmask]
Subject: systemd registration of listserv on modern Linux

Howdy,

I tried dropping the L-Soft provided sysV script into /etc/init.d on my new RHEL7 listserv server, but found that stopping the service under systemd failed to kill all the  ./lsv processes like it used to on RHEL5, leaving two ./lsv zombies to get in the way of maintenance operations. In general, killing the main Listserv PID as recommended by L-Soft just doesn't seem to kill Listserv anymore:

kill `cat $LSVHOME/spool/listserv.PID`


Since I couldn't find a reliable method to kill listserv all the way from the PID, I tried using the lcmd  tool to issue a clean SHUTDOWN command to listserv. I couldn't convince listserv that root was authorized to run commands without making root@hostname a quiet, hidden Admin. Eventually I was able to convince lcmd to shutdown listserv, but I'm not sure if this is the best way.

Since I was re-writing the init script, I figured I might as well learn systemd. I came up with the following systemd unit file, (which relies on root@hostname to be a Listserv admin):

[Unit]
Description=Listserv mailing lists by LSoft
After=network.target postfix.service

[Service]
PIDFile=/home/listserv/spool/listserv.PID
ExecStart=/home/listserv/go bg
ExecReload=/home/listserv/go bg
KillMode=process
Restart=on-failure
RestartSec=42s
ExecStop=/usr/local/bin/lcmd  SHUTDOWN

[Install]
WantedBy=multi-user.target


Anyone have a better, more reliable way to register Listserv under systemd?

Scott K
IT Engineer, BYU


________________________________

To unsubscribe from the LSTSRV-L list, click the following link:
http://peach.ease.lsoft.com/scripts/wa-PEACH.exe?SUBED1=LSTSRV-L&A=1

############################

To unsubscribe from the LSTSRV-L list:
write to: mailto:[log in to unmask]
or click the following link:
http://peach.ease.lsoft.com/scripts/wa-PEACH.exe?SUBED1=LSTSRV-L&A=1


ATOM RSS1 RSS2