Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
hello!
i have a redhat 9 box with two ethers. The gateway is on eth0 segment. The problem is that when i enable bridging, i cannot ping in internet. I think it is a route problem. Please help!
route is a little bit odd
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.0.0 * 255.255.255.0 U 0 0 0 eth1
192.168.0.0 * 255.255.255.0 U 0 0 0 eth1
169.254.0.0 * 255.255.0.0 U 0 0 0 eth1
127.0.0.0 * 255.0.0.0 U 0 0 0 lo
default gate 0.0.0.0 UG 0 0 0 eth0
gate is 192.168.0.1
an entry shows twice but i cannot delete it
route del 192.168.0.0
SIOCDELRT: No such process
as soon as i delete the bridge, the internet is accesible.
Well, i figured it out. This was the correct init sequence for the bridge
cd /sbin
brctl addbr br0
brctl addif br0 eth0
brctl addif br0 eth1
ifconfig eth0 0.0.0.0 up
ifconfig eth1 0.0.0.0 up
ifconfig br0 192.168.0.2 up
echo "1" > /proc/sys/net/ipv4/ip_forward
route add default gw 192.168.0.1
I have a similar problem. Whenever this line "ifconfig $ETH_PRIV 0.0.0.0 promisc up" is executed, the ip address of ETH_PRIV is changed. However after some time it reassigns its original IP address. I guess this happens after this line "ifconfig $BRIDGE_DEV $ETH_PRIV_IP netmask "
I have a Redhat Enterprise Machine with 2 interfaces.
brctl addbr $BRIDGE_DEV
RETVAL=$?
if [ $RETVAL != 0 ] ; then
echo "Add Brdige failed"
exit 1
fi
brctl addif $BRIDGE_DEV bb0
RETVAL=$?
if [ $RETVAL != 0 ] ; then
echo "Adding bb0 to bridge $BRIDGE_DEV failed"
exit 1
fi
brctl addif $BRIDGE_DEV $ETH_PRIV
RETVAL=$?
if [ $RETVAL != 0 ] ; then
echo "Adding $ETH_PRIV-(private network interface) to bridge $BRIDGE_DEV failed"
exit 1
fi
#Set the IP address of ETH_PRIV
ifconfig $ETH_PRIV 0.0.0.0 promisc up
RETVAL=$?
if [ $RETVAL != 0 ] ; then
echo "Setting ETH_PRIV to promisc mode failed"
exit 1
fi
ifconfig $BRIDGE_DEV $ETH_PRIV_IP netmask $ETH_PRIV_NETMASK up
RETVAL=$?
if [ $RETVAL != 0 ] ; then
echo "Adding IP Address to Bridge Failed"
exit 1
fi
brctl show
./ifconfig
#Amount of time spends listening for topology change information after that interface is
#activated for bridging and before forwarding actually begins
brctl setfd $BRIDGE_DEV 5
RETVAL=$?
if [ $RETVAL != 0 ] ; then
echo "Setting bridge forward delay failed"
exit 1
fi
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.