Hello all,
I have a problem setting up network bridging + masquerading on my Linux server box (Ubuntu Gutsy Gibbon).
I have a networking bridge setup like this:
/etc/network/interfaces
Code:
# The loopback network interface
auto lo
iface lo inet loopback
# The primary network interface
auto eth0
iface eth0 inet static
address 192.168.1.1
netmask 255.255.255.0
pre-up iptables-restore < /etc/iptables.up.rules
allow-hotplug benp0
iface bnep0 inet static
address 192.168.1.1
netmask 255.255.255.0
# The bridge for PAN
auto pan0
iface pan0 inet manual
up echo "Adding ethernet bridge between LAN and PAN"
up ifconfig eth0 0.0.0.0
up brctl addbr pan0
up brctl setfd pan0 3
up brctl stp pan0 on
up brctl addif pan0 eth0
up ifconfig pan0 192.168.1.1 netmask 255.255.255.0 up
down echo "Removing ethernet bridge between LAN and PAN"
down ifconfig pan0 down
down brctl delif pan0 eth0
down brctl delbr pan0
auto dsl-provider
iface dsl-provider inet ppp
pre-up /sbin/ifconfig pan0 up # line maintained by pppoeconf
provider dsl-provider
also in:
/etc/bluetooth/pan/dev_up
Code:
brctl addif pan0 $1
ifconfig $1 0.0.0.0
so, I have a bridge pan0 that initially has eth0 in one port and adds bnep0 to another port when it's available.
Also I have masquerading enabled in IPTalbes.
My problem is:
MASQUERADE is not functioning???
I can ssh to my server, I can ping my ppp0 IP in server, I can use NFS and what ever I want BUT my requests to the outside work is not working.
Also I checked the MASQUERADE with tcpdump -i ppp0 and I saw that requests from my clients are translated and go through ppp0 but THERE IS NOT REPLAY to this requests at all.
I'm really getting nuts because of this problem.!
DOES ANYONE KNOW WHERE IS MY MISTAKE???
thank you very much!