Networking Forums

Networking Forums > Computer Networking > Linux Networking > how can i bridge 2 network interfaces?

Reply
Thread Tools Display Modes

how can i bridge 2 network interfaces?

 
 
Christos Panagiotakis
Guest
Posts: n/a

 
      07-19-2004, 10:08 AM
Hello, I have a problem with bridging 2 different networks
We have already a network with ips like 10.165.0.1 and subnet mask
255.255.255.224 and we have a linux box running slackware 10.
With this box we want to bridge 10.165.0.0 network with a new one 10.166.0.0
(subnet 255.255.255.224)
We dont know how to bridge them... Any ideas?
the linuxbox has eth0 and eth1. eth0 = 10.165.0.0 and i couldnt find out how
to configure eth1 as 10.165.0.0
Any ideas?
thanks


 
Reply With Quote
 
 
 
 
Robert Brendel
Guest
Posts: n/a

 
      07-19-2004, 03:25 PM
Christos Panagiotakis wrote:

> Hello, I have a problem with bridging 2 different networks
> We have already a network with ips like 10.165.0.1 and subnet mask
> 255.255.255.224 and we have a linux box running slackware 10.
> With this box we want to bridge 10.165.0.0 network with a new one
> 10.166.0.0 (subnet 255.255.255.224)
> We dont know how to bridge them... Any ideas?
> the linuxbox has eth0 and eth1. eth0 = 10.165.0.0 and i couldnt find out
> how to configure eth1 as 10.165.0.0
> Any ideas?
> thanks


Why don't you just want to route? ( to enable routing type: 'echo 1
> /proc/sys/net/ipv4/ip_forward')


setup your network-devices using ifconfig:

'ifconfig eth0 10.165.0.1 netmask 255.255.255.224 up'
'ifconfig eth1 10.166.0.1 netmask 255.255.255.224 up'

Note:
=========

1st network:

Address: 10.165.0.1 00001010.10100101.00000000.000 00001
Netmask: 255.255.255.224 = 27 11111111.11111111.11111111.111 00000
Wildcard: 0.0.0.31 00000000.00000000.00000000.000 11111
=>
Network: 10.165.0.0/27 00001010.10100101.00000000.000 00000 (Class
A)
Broadcast: 10.165.0.31 00001010.10100101.00000000.000 11111
HostMin: 10.165.0.1 00001010.10100101.00000000.000 00001
HostMax: 10.165.0.30 00001010.10100101.00000000.000 11110
Hosts/Net: 30 (Private Internet)


2nd network:

Address: 10.166.0.1 00001010.10100110.00000000.000 00001
Netmask: 255.255.255.224 = 27 11111111.11111111.11111111.111 00000
Wildcard: 0.0.0.31 00000000.00000000.00000000.000 11111
=>
Network: 10.166.0.0/27 00001010.10100110.00000000.000 00000 (Class
A)
Broadcast: 10.166.0.31 00001010.10100110.00000000.000 11111
HostMin: 10.166.0.1 00001010.10100110.00000000.000 00001
HostMax: 10.166.0.30 00001010.10100110.00000000.000 11110
Hosts/Net: 30

That means each of your networks my at least have maximum 30 computers. The
first useable ip in your network is 10.165.0.1/10.166.0.1, the last one is
10.165.0.30/10.166.0.30!
 
Reply With Quote
 
Juha Laiho
Guest
Posts: n/a

 
      07-20-2004, 10:02 AM
"Christos Panagiotakis" <(E-Mail Removed)> said:
>Hello, I have a problem with bridging 2 different networks
>We have already a network with ips like 10.165.0.1 and subnet mask
>255.255.255.224 and we have a linux box running slackware 10.
>With this box we want to bridge 10.165.0.0 network with a new one 10.166.0.0
>(subnet 255.255.255.224)


I think you may have a terminology error here -- bridging would be to
connect two distinct media (f.ex. Ethernet) segments belonging to the
same IP network. What you describe here is apparently need for routing
between two distinct IP networks (that coincidentally also are located
into distinct media segments).

It looks like the other response already contained at least most of the
needed things for setting up the routing.
--
Wolf a.k.a. Juha Laiho Espoo, Finland
(GC 3.0) GIT d- s+: a C++ ULSH++++$ P++@ L+++ E- W+$@ N++ !K w !O !M V
PS(+) PE Y+ PGP(+) t- 5 !X R !tv b+ !DI D G e+ h---- r+++ y++++
"...cancel my subscription to the resurrection!" (Jim Morrison)
 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
interfaces on network switch Mark Linux Networking 13 12-17-2009 10:11 PM
[/etc/network/interfaces]Syntax somewhere?? universalbitmapper Linux Networking 8 04-25-2006 06:32 AM
ifconfig... /etc/network/interfaces shawn modersohn Linux Networking 3 01-04-2005 09:26 AM
Bridge between interfaces without snat?? Mark Richards Linux Networking 0 07-30-2004 07:51 PM
nis server with 2 network interfaces IVANYI Ivan Linux Networking 0 07-17-2003 09:01 AM



1 2 3 4 5 6 7 8 9 10 11