Find the answer to your Linux question:
Results 1 to 6 of 6
Hi, I need to set up a 3-PCs test-environment, two PCs running on Windows and the one in the middle on Linux (Ubuntu, Kernel 2.6.10). I want to send data ...
  1. #1
    Just Joined!
    Join Date
    Sep 2005
    Posts
    7

    ethernet bridge

    Hi,

    I need to set up a 3-PCs test-environment, two PCs running on Windows and the one in the middle on Linux (Ubuntu, Kernel 2.6.10). I want to send data between the two win-PCs, which will be disturbed by the linux-machine (I installed Nistnet for that purpose).

    The Linux-PC has 2 Ethernet-Cards. Eth1 is connected to a switch, which is connected to a internet-router and the first Win-PC. Eth0 is connected to a Windows-Laptop via Crossover-cable.

    The network on the one side uses 192.168.0.XXX-addresses, and I configured the Win-Laptop to use a 10.0.0.XXX-address. I can ping the linux-machine from both windows-PCs, but the two windows PCs can't ping or connect to each other.

    I already tried to configure it with "iptables", but without success. Do I need to install a Ethernet-Bridge?

    Sorry if that sounds like a standard newbie-problem, but I already googled a while and couldn't find answers.

    I would be a really great help if someone could help me out.

    thanks,

    chris

  2. #2
    Linux Guru
    Join Date
    May 2004
    Location
    forums.gentoo.org
    Posts
    1,814
    You need to create a route from the 192.x.x.x network to the 10.x.x.x network and vice versa. Look it up, but I think you will need something like this for your Linux box:
    Code:
    route add -net 192.168.0.0 dev eth0
    route add -net 10.0.0.0 dev eth1
    That will default to netmask 255.255.255.0 and 255.0.0.0 respectively, I think, unless you specify a different netmask in the route command.

    And you need to have IP forwarding in your kernel.
    /IMHO
    //got nothin'
    ///this use to look better

  3. #3
    Just Joined!
    Join Date
    Sep 2005
    Posts
    7
    thanks for the quick reply!

    I tried it out, but I get the error message:
    "SIOCADDRT: Invalid argument", but the arguments are valid and conforming to the "man route".

    Another strange behaviour: from the first Win-PC, I can't ping the linux-PC if it has no connections open. e.g. I run the ping command on the win-PC, and get request timed out, but if i start to surf the web or ping back on the linux-machine, it works

  4. #4
    Just Joined!
    Join Date
    Sep 2005
    Posts
    7
    how can I test if I have IP forwarding in my kernel?

  5. #5
    Linux Guru
    Join Date
    May 2004
    Location
    forums.gentoo.org
    Posts
    1,814
    /IMHO
    //got nothin'
    ///this use to look better

  6. #6
    Just Joined!
    Join Date
    Sep 2005
    Posts
    7
    ok, it works. thanks for your responses. Finally, all that I had to do was to set the ip_forward to "1" and to add a new route on the windows-pc via the linux-machine.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •