Setting up OpenWrt


I managed to install openwrt 21.02 on an old xiaomi 3g router.

The internet box as an ip address of, I have a DHCP server on a rasperry pi 4 (

Openwrt default ip address is I would like to change this for, let's say,
If I go to network/interfaces and chage to save and apply, It tasks several minutes and notghin responding (nor or
The only way to fix things is to reboot the router, and then it's ip address is still

So can someone explain me how to change this setting ?

Thank you for your answer.

(via SSH)

uci set network.lan.ipaddr=''
uci commit network
service network restart

just make sure the IP isn't within the DHCP range, or change the interface to DHCP client, instead of static IP.

Thank you very much.
It worked perfectly.
Don't know why it's not working directly in the Luci web interface.

Now How can I say openwrt the dhcp server is not himself ?

1 Like

there's a timeout you need to wait for, or choose Apply unchecked.

check the box below.

1 Like

Ok, well i've got a pb.

If I plug my laptop on lan0 or lan1 on openwrt router.
If I want a DHCP address for the laptop it fails.
And nothing works.

If I setup a static ip address on my laptop, i can access the web, the router (, but not the dhcp server ( does not respond) and my NAS is not reachable !!!

I really don't understand how to configure openwrt as just a switch with wifi connection possibility. asked this already:

Please try not to make duplicate inquires. My response explains why it didnt work on web GUI. I see that there was no need to respond.

what's the use case for the 3g ?

this might be a better option

1 Like

In fact I have a two floor house.
Wifi signal downstair is weak.
Downstair I've got my NAS too (downstair is cooler than the deskroom)

My idea was to use the router xiaomi with openwrt, to plus the NAS on lan0, and use the wifi signal of openwrt for devices which are downstair.

Obvously I want to be able to reach the NAS and devices wifi connected to the openwrt router from upstair.

I'm curious...

Is the upstairs and downstairs network currently connected in any manner?

1 Like

if not,

1 Like

yes I have an rj45 cable between the two floors.

Frollic : thank you it works well with dumb mode. The only drawback is that there are only 2 rj45 port available...
I would have like 3 connections (the cable from the 1st floor, the NAS, and a third cable that goes on another room on floor 0 ...

Please provide more detail on how the 2 are connected by RJ45.

(Really need details on their connection to assist you, we can't guess your setup.)

  • are they LAN to LAN?
  • IP of other device?
  • etc. significantly edited your post. Disregard.

In fact my internet box is in my office room.
There is a cable rj45 from that room to the living room (still floor 1). (there is a switch for tv, ps4, tv player ...)
From that switch I have the rj45 cable that goes to floor 0

Now on floor 0, I can connect that cable to the openwrt router on port lan0 and my Nas on lan1, and I can use openwrt wifi.
The only drawback is that it would have be great to have a third port, since I have another rj45 cable that goes in an another room...

Please try not to significantly edit posts.

  • If you have the WAN port available, you can reassign it to LAN, if thats what you mean.
  • If you mean magically having another port because there are no physical ports avaliable, then no. You'll need a switch to expand port capacity.

(I'm not sure because you have refered to links before you make their connections, so I want to be clear.)

1 Like

there's also a USB port, on the v1 of the device, which could be used as additional ethernet port(s), but a gigabit switch is probably cheaper, anyway.

1 Like

Yes if we can reassign wan port to LAN, it would be great. Even if the connection is not 1gb, there's no matter. It's just to plug a tv box.

But I don't know how to reassignwan to LAN. On some posts I see to do something in physical settings tab, but in openwrt 21.02 there is no such tab...

Thank you for your help.

I've never heard of such a tab - until you mentioned it.

If your device has a switch built in, it would be under Network > Switch. If this is the case, the WAN port is usually assigned as "untagged" on line 2 (VLAN 2), you would turn that off and change it to "untagged" on VLAN 1.

This is a DSA kernel, there is no Switch page. Also in later versions, bridges are declared separately.

First go to Network-Interfaces and delete the wan interface. Your use case (dumb AP) only needs a lan network. This will free up the wan port for other uses. Then click the Devices tab at the top of Network->Interfaces and find the line for br-lan. Click the Configure button on that line. Add wan to the list of Bridge Ports that are in br-lan. The three Ethernet ports on the back of the router are named wan, lan1 and lan2. You want them all in the same bridge br-lan so that devices plugged into them are switched to the same network.


perfect. It s working like a charm.

Thank you four your help.