Network settings

Hi,

I have two routers (one internet connected) and a BananaPi acting as a extender. As you know the default network on OpenWRT is 192.168... My desktop is connected to the Pi running OpenWRT via lan cable and thus I am expect the desktop to have a ip on 192.168. However, it is getting a address of 10.1.1.* which, is the network the internet connection router.

Thanks,

Nightwalker83

How is the pi connected to your computer? Is it a direct connection, or is it connected to a switch? Does your computer have multiple network interfaces? (Multiple wired or wired + WiFi, etc)?

1 Like

The computer is connected via ethernet cable. It is wired plus wifi. The computer is connected by cable and the wifi connects to the main router.

did you turn off the wifi on your computer?

No because the computer is connected by LAN cable.

When connected by a cable, don't use wifi. There should only be one connection a a time.

No, you misunderstand! I drawn a diagram of my setup hopefully it clear things up a bit.

There are two ways to do this... one is to set the OpenWrt wifi uplink as a Wireless WAN (which means that the devices behind the OpenWrt device will be on a different subnet), or you can use what is described in this link.

Your desktop computer should only have a single network connection active -- the wired one. The wifi on the desktop should be disabled if you want to use the connection through the OpenWrt.

You say you have 2 routers and a Banana Pi and a desktop computer - that's 4 devices

You've shown 3 in your diagram -

is the middle device the banana pi? If so, where is the "second" router, if not, where is the banana pi?

192.168.x.x and 10.x.x.x, these are both internal private addresses.
To get that working you need a firewall and masq between those two gateways. And a dhcp server on the inside of firewall.

But 10.x.x.x also means that you live behind a double NAT if you set up your own router and doesn’t have a real internet connection.

The BananaPi is setup as a forwarder not router sorry however, it is able to be setup as one I have not chosen to do so.

So 192.168.1.* is normal NAT while 10.1.1.* is a double NAT?

No but there are three private address ranges allowed in private networks in the world
10.0.0.0/8
172.16.0.0/12
192.168.0.0/16
These are on the other hand not allowed online and must be placed inside a private network.
So if you have one of these from your ISP then you don’t have any real internet connection at all. Instead you are a part of the ISP own LAN with his firewall and DHCP server. And do you want to use one address for your self inside a private network you need a physical delimiter like a firewall, dnsmasq and your own DHCP server on the inside and you are not allowed to use the same address range on both sides of the firewall.

So when you run “wifi” between “internet” and “router” in your picture you actually run “wifi” between “router” and “router” with two different LAN on the same LAN.

If you want that to work you must run the wifi to WAN on the device you call “router” in the picture or only use the 10.1.1.* DHCP server.