Routing problem : two interfaces one gateway


 
Thread Tools Search this Thread
Special Forums IP Networking Routing problem : two interfaces one gateway
# 8  
Old 10-09-2014
I take it you mean you do want to just bridge them all together and not do any routing. Trying could be dangerous, it's not a minor change -- it's effectively ditching the "wan" device and making everything part of "br0". And since this is an embedded device, one slip-up and you've "bricked" it. I wouldn't recommend it.

Why not just plug everything into the LAN ports?
# 9  
Old 10-09-2014
Quote:
Originally Posted by Corona688
I take it you mean you do want to just bridge them all together and not do any routing. Trying could be dangerous, it's not a minor change -- it's effectively ditching the "wan" device and making everything part of "br0". And since this is an embedded device, one slip-up and you've "bricked" it. I wouldn't recommend it.

Why not just plug everything into the LAN ports?
the device has a read-only system. so after reboot everything is as before.

when plug the lan-cable to my network switch to the lan2 (br0) then it works like a switch and auto-configures the lan-ports. so i can use lan2 lan3 and lan4 like a normal switch. BUT

then the internal link to the internet is not there and the internal voip-program has no connection to the internet and cannot connect to my sip-account.

when i disable wan0 with

Code:
ifconfig wan0 down

and add the default gw with

Code:
route add default gw 192.168.2.1 br0

everything works like it should (router cann connect to sip-account, devices on lan1 - lan4 have inet). but i need to configure this on every reboot, and that is really annoying.


so is there an option to bridge or do something like this.
# 10  
Old 10-09-2014
If you cannot change the router's configuration, then anything you do isn't going to be permanent, bridge or not.

see 'brctl' for how software bridges are managed, but you'd have to get the router to stop messing with the 'wan' interface and use 'br0' instead somehow.
# 11  
Old 10-09-2014
Quote:
Originally Posted by Corona688
If you cannot change the router's configuration, then anything you do isn't going to be permanent, bridge or not.

see 'brctl' for how software bridges are managed, but you'd have to get the router to stop messing with the 'wan' interface and use 'br0' instead somehow.
yes you are right. but if i leave the configuration like i have now. at least the sip-account works on reboot. that is because the lan1 port is configured to be a fake external modem with dhcp. this is what the user interface allows. but i can't use lan2-4.

brctl is not available :-(

the following commands are avalable :

Code:
expr            kill            ping            top
ash             false           killall         pivot_root      touch
basename        fgrep           klogd           ppf             tr
busybox         free            ln              ps              true
callsetupunit   fsck.msdos      logger          pwd             tty
cat             fsck.vfat       login           reboot          udhcpc
chmod           fxo             logread         rm              udhcpr
config.ini      getopt          ls              rmmod           umount
cp              getty           mkdir           route           uname
cut             grep            mknod           sh              uptime
date            gunzip          modprobe        sleep           usleep
dd              gzip            modprobe.sh     syslogd         vi
dmesg           hostname        more            t38.ini         wget
dosfsck         ifconfig        mount           tail            zcat
dropbearkey     init            mv              tapidemo
dumpleases      insmod          oamctl          tar
echo            iwconfig        oamd            test
env             iwpriv          passwd          tftp

# 12  
Old 10-09-2014
If brctl is not available, you cannot bridge.
# 13  
Old 10-09-2014
Quote:
Originally Posted by Corona688
If brctl is not available, you cannot bridge.
ok. so i have to do trial and error to achieve a solution. thanks for your help.

i ll give feedback if any solution will work.
# 14  
Old 10-11-2014
i found out that there is the command brctl. it was in another directory which was not in the path. the output is the following.

Code:
# ./brctl show
bridge name     bridge id               STP enabled     interfaces
br0             8000.001b11b444de       no              eth1

again the output of route is

Code:
# route
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
192.168.2.0     *               255.255.255.0   U     0      0        0 br0
192.168.2.0     *               255.255.255.0   U     0      0        0 wan0
default         192.168.2.1     0.0.0.0         UG    0      0        0 wan0

ip route show delivers
Code:
# ./ip route show
192.168.2.0/24 dev br0  proto kernel  scope link  src 192.168.2.4
192.168.2.0/24 dev wan0  proto kernel  scope link  src 192.168.2.127
default via 192.168.2.1 dev wan0

ip link show delivers

Code:
# ./ip link show
1: lo: <LOOPBACK,UP> mtu 16436 qdisc noqueue
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: MEI_PHY: <UP> mtu 0 qdisc noop
    link/[94]
3: eth0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop qlen 1000
    link/ether 00:1b:11:b4:44:dd brd ff:ff:ff:ff:ff:ff
4: eth1: <BROADCAST,MULTICAST,PROMISC,UP> mtu 1500 qdisc pfifo_fast qlen 1000
    link/ether 00:1b:11:b4:44:de brd ff:ff:ff:ff:ff:ff
5: gre0@NONE: <NOARP> mtu 1476 qdisc noop
    link/gre 0.0.0.0 brd 0.0.0.0
6: br0: <BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue
    link/ether 00:1b:11:b4:44:de brd ff:ff:ff:ff:ff:ff
7: wifi0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop qlen 199
    link/ether 00:19:5b:ed:63:44 brd ff:ff:ff:ff:ff:ff
8: wan0: <BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast qlen 1000
    link/ether 0a:1b:11:b4:44:de brd ff:ff:ff:ff:ff:ff
#

i think i need to remove br0 and bridge wan0 to eth1. but i am not sure.

again wan0 is the ehternet port which is connected to my homenetwork (switch).

if i try to remove the interface from the bridge br0 i loose my ssh-connection to the router. so this is no option. removing the bridge does not work because it is denied by brctl. i am a little stuck right now because of my limited knowledge to ip.

i repeat myself but with the recent permanten configuration the internal sip-telephony which needs access to internet works. for a solution i need a simple command that i can enter from the console to use the lan2-4 ports.
any ideas ? thx in advance.

Last edited by gencaslan; 10-11-2014 at 07:49 PM..
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Beginners Questions & Answers

Inconsistency between RedHat 6.5 global gateway and single gateway leads to loss of default gateway

Dear friends I use RedHat 6.5, which sets the gateway in the configuration file / etc / sysconfig / network as GATEWAY = 192.168.1.26, and the gateway in the configuration file / etc / sysconfig / network-scripts / ifcfg-eth11 as GATEWAY = 192.168.1.256. The two gateways are different.... (6 Replies)
Discussion started by: tanpeng
6 Replies

2. IP Networking

Network Interfaces Problem - Monitoring equipment

Dear gurus of Linux / Unix. I have a server, which I use to monitoring traffic, the problem that I find is when I run the following command: probe:~ # sar -n DEV 1 I see that I one second appear info in some interface and in the other second no appear, I don't know what will be the... (0 Replies)
Discussion started by: andresguillen
0 Replies

3. AIX

Problem with multiple network interfaces

Hi .. we have two AIX 5.3 systems with a small client server app communicating over a TCP socket. Box A has a single network interface where the server app (in Java) opens a well known port and waits for connections from Box B. Box B has two network interfaces, X and Y. Interface X has the... (4 Replies)
Discussion started by: RonBowater
4 Replies

4. Solaris

Routing problem

Hi, I have two physical interfaces on a servers. We have connected them to differerent subnets. 1) First interface: 10.158.49.87 to newtwork 10.158.49.0, its gateway is 10.158.49.1 (It is added as default gateway) It is existing set up. It works well 2) Second interface: ... (1 Reply)
Discussion started by: sri243
1 Replies

5. IP Networking

Problem when I Open my WireShark - No Interfaces Option available

Hi gurus of unix, I haved installed my openSolaris in a HP530, Recently I use the following command beadm destry opensolaris1 beadm destry opensolaris2 After That I reboot my Laptop. Well when I go to my work I try to open my wireshark tool, but the option in GUI interface does not appear!!!... (2 Replies)
Discussion started by: andresguillen
2 Replies

6. Debian

/etc/network/interfaces problem

Hello i am configuring a debian lenny sever ,/etc/network/interfaces is modified so that eth1 takes a static IP address then i save it wq! then i restart the networking , /etc/init.d/networking restart . but after reboot ,the file is reset ,note that the interfaces had by defauklt IPv6 address... (5 Replies)
Discussion started by: learn82
5 Replies

7. Linux

GNUGK-How to setup static gateway to gateway routing

Dear Sir I am a newbie in the world of IP telephony. I have been working with Asterisk PBX (SIP) and Cisco Call Manager (MGCP) but now I am learning on how to work GNUGK for H.323 Gatekeeper. I am having a problem, configuring static call routing on GNUGK in the section ... (0 Replies)
Discussion started by: mfondoum
0 Replies

8. Linux

Routing via several interfaces for hosted virtual machines

My setup consists of a hardware node, which hosts several virtual machines (OpenVZ, to be precise). The hardware node has two network interfaces (<ifA>, <ifB>) connected to different subnets (<networkA>, <networkB>). I want to route the traffic of certain VEs over <ifB> while routing the other VEs... (0 Replies)
Discussion started by: bakunin
0 Replies

9. SCO

Network interfaces problem

Hi, I have problems with my SCO unix network interfaces. Intel integrated adapter was failing, so I installed new one - 3COM adapter into free PCI slot. Installed driver using SCO Software manager - successfully Added new Network adapter using SCO Network configuration manager - successfully... (0 Replies)
Discussion started by: vilius
0 Replies

10. IP Networking

Network interfaces problem

Hi, I have problems with my SCO unix network interfaces. Intel integrated adapter was failing, so I installed new one - 3COM adapter into free PCI slot. Installed driver using SCO Software manager - successfully Added new Network adapter using SCO Network configuration manager - successfully... (0 Replies)
Discussion started by: vilius
0 Replies
Login or Register to Ask a Question