Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Strange forwarding problem
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
jeffbuttars
Tux's lil' helper
Tux's lil' helper


Joined: 23 May 2003
Posts: 79
Location: Boise, ID

PostPosted: Thu Jun 24, 2004 5:42 am    Post subject: Strange forwarding problem Reply with quote

I have firewall setup with two nics.
eth0 is a static ip x.x.x.53 netmask x.x.x.248
eth1 is internal ip 192.168.0.1 netmask 192.168.0.0

I'm using iptables to setup a simple firewall and SNAT

EXTIF=eth0


$IPTABLES -t filter -A FORWARD -i! $EXTIF -m state --state NEW,ESTABLISHED,RELATED -j ACCEPT
$IPTABLES -t filter -A FORWARD -i $EXTIF -m state --state ESTABLISHED,RELATED -j ACCEPT
$IPTABLES -t filter -A FORWARD -i $EXTIF -m state --state NEW,INVALID -j DROP
$IPTABLES -t nat -A POSTROUTING -o $EXTIF -s 192.168.0.0/255.255.0.0 -j SNAT --to-source x.x.x.53


The problem:
On fresh boot the firewall will not forward packets from eth1 to eth0.
From the internal network I can ssh to eth1 on the firewall and restart the internal network
/etc/init.d/net.eth1 restart
and then everything will forward through and work like it's supposed to.
Right after boot, before restarting eth1 to make things forward,
/proc/sys/net/ipv4/conf/all/forwarding
/proc/sys/net/ipv4/ip_forward
are both '1'

I'm running dncpd and it functions just fine.

I'm lost.
Back to top
View user's profile Send private message
Shan
Guru
Guru


Joined: 04 Nov 2003
Posts: 558
Location: /dev/null

PostPosted: Thu Jun 24, 2004 6:07 am    Post subject: Reply with quote

Its not a proper fix but assuming you don't find one, you can always add the line
Code:
/etc/init.d/net.ethX restart
to your /etc/init.d/local.start file
_________________
{ NO -U } { STRIP }
{ TINY }
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum