Hi, On 02/28/2012 01:33 AM, Lew Wolfgang wrote:
On 02/27/2012 09:54 PM, Cristian Rodríguez wrote:
On 27/02/12 00:53, Lew Wolfgang wrote:
So I need to figure out how to delay sshguard so that it appears later in the boot sequence.
Later is quite vague, do you want it after Susefirewall I presume ?
Right. sshguard needs to start after SuSEfirewall2_setup.
The sshguard rpm created /etc/init.d/sshguard and the symlink /etc/init.d/rc3.d/S08sshguard. The firewall setup link is S15SuSEfirewall2_setup. So I moved S08sshguard to S16sshguard and rebooted. But it still doesn't work, S15SuSEfirewall2_setup is being run after S16sshguard.
But "systemctl list-units |grep guard" shows:
sshguard.service loaded active running LSB: SSHGUARD provides automatic attack blocking
So systemd knows about sshguard, but I don't know how it found out about it. Maybe the install rpm? If it found it by scanning the init.d scripts it must be ignoring the "ls" order.
My default runlevel is 3.
For sysV init the order is determined by the LSB header in the init script, yes I know comments that are significant is not very nice, but that's the way it has been for a long time. Thus, for sshguard to start after SuSEfirewall in a sysV init environment you'd need to add SuSEfirewall2_setup at the end of the Required-Start: line within the ### BEGIN INIT INFO and ### END INIT INFO block in the init script for sshguard. After you are done with your modification run insserv sshguard and the order will be correct and things will work. For the systemd init process the order is set with key words: After Before Requires Wants see http://0pointer.de/public/systemd-man/systemd.unit.html Files for systemd are located in /lib/systemd/system/ If sshguard already has a .service file it should be in the /lib/systemd/system directory. You can edit this file and add an After=SuSEfirewall2_setup.service This should work even though SuSEfirewall2_setup does not yet have a .service file. We have "magic" in various places that ties sysV init and systemd together such that during the transitions phase (until all services have .service files) services are started properly. HTH, Robert -- Robert Schweikert MAY THE SOURCE BE WITH YOU SUSE-IBM Software Integration Center LINUX Tech Lead rjschwei@suse.com rschweik@ca.ibm.com 781-464-8147 -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org