How to setup OPNsense for preconfigure - as another machine on the network?

Started by wotcha, March 02, 2023, 09:58:14 PM

Previous topic - Next topic
I want to preconfigure the OPNsense router first, without replacing my main router at the moment while I work on it. And I would like to go have internet access. 

On the WAN interface:
- have already unchecked block Private Networks.
- have checked allow DNS/PP to be overridden by WAN (or smthg along those lines)

On my WAN port, I get assigned an IP address (192.168.1.30) from my existing router, but I can't access the internet.

How can I preconfigured the box AND connect it to the internet, while not replacing my existing router?

Quote from: wotcha on March 02, 2023, 09:58:14 PM
I can't access the internet.

That's a bit vague. What works and what doesn't work? Ping to upstream firewall, ping to 8.8.8.8, DNS resolution, protocols working and protocols blocked?

Quote from: bartjsmit on March 03, 2023, 10:49:15 AM
Quote from: wotcha on March 02, 2023, 09:58:14 PM
I can't access the internet.

That's a bit vague. What works and what doesn't work? Ping to upstream firewall, ping to 8.8.8.8, DNS resolution, protocols working and protocols blocked?

Any access to the internet at all including pings, DNS, etc. There is no WAN connection, except it receiving a local ip address from my lan

Can you ping 8.8.8.8 from the firewall? Interfaces: Diagnostics: Ping

If you can, it's likely to be your internal routing. Do you have NAT configured on OPNsense? If not, does your upstream firewall have a static route to the LAN behind OPNsense?

Bart...

Not sure if OPNsense automatically adjusts the default LAN address if it detects conflicting network on the WAN side, otherwise you have 192.168.1.x on both WAN and LAN; I assume the default LAN has default 192.168.1.1?

Besides that, are you on your current 192.168.1.x (the WAN side of your new box) or on the LAN side of the new box? I assume by no internet you meant you're on a computer or whatever in the same network, or you mean on the Web GUI of the new box?
If on the WAN side of the new box (i.e. the LAN side of your current network), then no internet means something wrong in your current network's router, nothing to do with the new box I guess. Check IP address etc?

If on the LAN of the new box, same check IP address, make sure not conflicting with existing..
And then think about the LAN address...if you make it the same as your current one , it won't work; if not the same, then you might not be able to pre-configure unless you will be using different numbers  ;)

If no internet on the new box itself, guessing some sort of address conflict, will need more info to determine.

If the new box's WAN interface is connected to your current network's LAN, then getting a local address from the current LAN is as expected. Should have internet access, if not, something else not known. Would be much easier to determine the issue if you can draw or explain the topology a little more.

Quote from: RoamingJay on March 07, 2023, 01:46:56 PM
Not sure if OPNsense automatically adjusts the default LAN address if it detects conflicting network on the WAN side, otherwise you have 192.168.1.x on both WAN and LAN; I assume the default LAN has default 192.168.1.1?

No, it doesn't and this setup won't work. @micneu posted a small network diagram suitable for preconfiguration:

https://forum.opnsense.org/index.php?topic=32818.msg158893#msg158893

if your current network uses 192.168.1.0/24, you will have to change the LAN address of OPNsense via the console, though.

HTH,
Patrick
Deciso DEC750
People who think they know everything are a great annoyance to those of us who do. (Isaac Asimov)