Gentoo Archives: gentoo-user

From: Mark Knecht <markknecht@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] modifying iptables: how can I prevent locking me out?
Date: Mon, 24 Jan 2011 19:00:46
Message-Id: AANLkTin98-=p88PHnB+n_+nHgBbKxC4BAwxcoQTTV6eE@mail.gmail.com
In Reply to: [gentoo-user] modifying iptables: how can I prevent locking me out? by Jarry
1 On Mon, Jan 24, 2011 at 10:47 AM, Jarry <mr.jarry@×××××.com> wrote:
2 > Hi,
3 >
4 > I have to change rather complex iptables rules on server
5 > and I do not want to lock me out as this server is about
6 > 50 miles away. So how should I do it?
7 >
8 > I can back up the old rules by running:
9 > /etc/init.d/iptables save
10 > and it will be saved to /var/lib/iptables/rules-save
11 > (some strange format starting with number like [536:119208])
12 >
13 > I prepared a script with new (modified) iptables-rules,
14 > which I will run in bash. But in case I screw something,
15 > how could I force netfilter to load old saved rules,
16 > if I for whatever reason do not connect to server (ssh)?
17 >
18 > Or can I load new iptables-rules for certain time, and
19 > then force netfilter to load back the old rules again?
20 >
21 > Jarry
22 >
23
24 Maybe a cron job that no matter what reloads the old rules 1 hour later?
25
26 - Mark

Replies

Subject Author
Re: [gentoo-user] modifying iptables: how can I prevent locking me out? kashani <kashani-list@××××××××.net>
Re: [gentoo-user] modifying iptables: how can I prevent locking me out? Manuel Klemenz <m.klemenz@×××.at>
Re: [gentoo-user] modifying iptables: how can I prevent locking me out? Neil Bothwick <neil@××××××××××.uk>