Building a Site-2-Site network manually using two GL.iNet routers

maybe you can help me again

How can I undo the line ?

sed -i "/rm \/var\/run\/glwgserver.lock -rf/a\ip route add\/24 dev wg0" /etc/init.d/wireguard_server

the line
ip route add dev wg0
i can undo by changing the add with del

I don’t know why you dont want this line. But you can just comment out this line.

# sed -i "/rm \/var\/run\/glwgserver.lock -rf/a\ip route add\/24 dev wg0" /etc/init.d/wireguard_server

Hello alzhao,

Thanks for the answer unfortunately I don’t know so well.
Comment out in the wireguard_server file ?

or is the autostart something else inside ?

Yes I have made a mistake in the IP address :slight_smile: :exploding_head:

It is easier to use WinSCP to edit files, such as /etc/init.d/wireguard_server in this case:

I do not work for and I do not have formal association with GL.iNet

Sorry I don’t know. As you pointed out that line, I thought you know that.

Hi, Thanks for help,
Is it not correct to have both subnets with same range
In my case, in my office everything is in 192.168.0.x, and my devices already in the world are with same range…
Does it means that it will never work?

No. You cannot use the same subnet for different nodes.

Ok, bad news then… :neutral_face:
Because all the PLC devices already in the world are with 192.168.0.x…
and what if is created a separated range for the server in the office?? 192.168.8.x

The PLC devices, connected to GL router, has static IP 192.168.0.x??

Maybe should let them use DHCP or set static IP according to the subnet of GL router.

You have remote control to the PLC devices remotely?

Yes, they have static IP address…
I don’t have yet get the remote control, for now I am in the office trying to get in green the dot in the client side.
I modified the LAN IP of the fix mango server to
I am connected with cable to LAN port of fix mango server.
Mango server is connected to the WIFI of the router of the office…

CLIENT (as new user I only can attach 1 picture)

In the client side, you cannot use as the LAN IP because it is used in the server side already.

Hi, Yes, I saw it, later I modified to to 192.168.5.x

But still in yellow… :pensive:

Have you set up portforward in the server side, on the gateway

Which port? server side:


On your main router, you should port forward 51820 to

Hi, you mean open port 51820 to 192.168.???.??? :51820
Excuse me, but seems typing was wrong…
I will request it to IT deparment…

Hi, Just the last question… :upside_down_face:
Because seems that the message was to typed right…
Which address/port to be opened in the router of the office??

I am not sure what you are asking because I said
“On your main router, you should port forward 51820 to”
which seems having answered your question.

yes but the is what is was strange, because in my layout there is no device with the end address .19
I apologize for this duplicated answer