You are not logged in.

#1 2004-04-26 08:48:03

tmadhavan
Member
From: Wales :D
Registered: 2004-03-26
Posts: 441

Starting firestarter/iptables at boot - rc.local or rc.conf?

Hi all.

Just installed firestarter as my firewall, and set it up as root, with defaults for now.

I was just wodnering what I need to do to start iptables and firestarter at boot. From what I can work out, iptables should be in the daemon section of rc.conf, whereas I can start firestarter from rc.local with

 firestarter -& 

.

Unfortunately, firestarter doesn't seem to start at boot (at least, I don't see a message, and ps -ax doesn't show it). Then when I shutdown I get a FAILED message when the kernel reports it's shutting down iptables??!!

Any ideas/confirmations that I'm right/wrong?

Thanks a lot,
Thom.

Offline

#2 2004-04-26 18:54:15

colnago
Member
From: Victoria, BC
Registered: 2004-03-25
Posts: 438

Re: Starting firestarter/iptables at boot - rc.local or rc.conf?

I don't use firestarter, but in order to have the daemon start at boot, you need to have a script for it in /etc/rc.d 

When you put it in rc.conf, the startup will try to run 'etc/rc.d/firestarter start', so the script should be set up with that in mind.  Look at others there for examples.  The script might have been put there by the install. 

Also, most progs have an option to not launch into the bg, so you can see if there are any messages ( maybe there already are, look in /var/log/...) by launching it from a terminal.

It sounds like you have something working from the /etc/rc.d script, as you get the iptables failed message.

Here is the type of thing I would expect in /etc/rc.d/firestarter
---------------------------------------------------------------
#!/bin/sh
#
if [ "$1" = "start" ]; then
        firestarter -&
elif [ "$1" = "stop" ]; then
        killall -q /usr/sbin/iptables
else
        echo "usage: $0 start|stop"
fi
#End of file

Offline

Board footer

Powered by FluxBB