0

Because I do not find the correct question that I can ask google, due to the lack of terminology. I'm trying to ask it here. Please have patience.

My Question is similar to the questions asked here and here .

How to connect to devices that have a the same ip address 192.168.1.1. Clearly this is not possible because a IP address needs to be unique.

Which setup do I need, in order to access multiple devices that have the same id.

The idea that I have so far is to use a managed switch that maps the IP address 192.168.2.n to 192.168.1.1

network diagramm

If a setup like the image above suggests could be achived, then could you please guide me to how to set it up. Also I'm very thankful if you could provide me with the right terminology of what I'm trying to achive.

Like: Connect two Vlan from port 1 to Port2 with a bridge ....

The Author of the post above suggested: The managed switch is setup so that each port is vlan'd into its own untagged vlan and all of those vlans are tagged on the port connected to the PC. What does it mean, can you explain further?

Your help is highly appreciated.

PS: What I really trying to achieve is to automate the installment of software on a Linux device that by default comes with a default IP address of 192.168.1.1. Detect the connected device on the network ssh into it and install & configure the software.

1
  • If it is just a layer 2 managed switch he won't be able to do what you're trying to do as it doesn't know about IPs. But if you're connecting to a router anyway you could do it on the router.
    – Seth
    Commented Feb 1, 2017 at 17:15

1 Answer 1

0

Multiple network devices with the same IP means that those devices are in bridge mode. This is an example of /etc/network/interfaces file, on a Debian-base Linux:

iface br0 inet manual
      pre-up brctl addbr br0
      pre-up brctl addif br0 eth0
      pre-up brctl addif br0 eth1
      pre-up brctl addif br0 eth2
      pre-up ifconfig eth0 up
      pre-up ifconfig eth1 up
      pre-up ifconfig eth2 up
      up ifconfig br0 up
      up ifconfig br0 192.168.0.50
      down ifconfig br0 down
      post-down ifconfig eth0 down
      post-down ifconfig eth1 down
      post-down ifconfig eth2 down
      post-down brctl delif br0 eth0
      post-down brctl delif br0 eth1
      post-down brctl delif br0 eth2
      post-down brctl delbr br0

In this case, eth0, eth1 and eth2 are part of virtual "br0" network interface. Then, you configure network on that virtual interface.

If you are planning to use bridge mode on Linux, then kernel has to support it (usually do), and bridge-utils package must be installed.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .