I’ve been trying to setup my fisrt HomeLab for a couple of days. I am pretty new to all this…
What I am trying to do is a all-in-one server (router, firewall, media server, etc). For that, I have a dedicated PC (128gb ram, AMD 7700, 2tb nvme and 12tg hhd).
I also have 3 NICs, 1 from my motherboard (2.5gbe) and 2 from a dual 10gbe nic connected to PCIe 16x.
The 3 NICs are:
enp1s0f0 10gbe - used for wan
enp1s0f1 10gbe - will eventually be used for vlans
enp9s0 2.5gbe - proxmox management / l’an (my other PC is currently connected here for management purpose)
My first goal is to install Proxmox and a virtualized OpnSense router.
I have followed the guides (on YouTube) and everything seems to work except… I don’t have internet access on Proxmox and opnsense.
I have created 3 Linux bridges for my 3 nics:
vmbr0 for enp1s0 (management)
vmbr1 for enp1s0f0 (WAN)
vmbr2 for enp1s0f1 (VLANs) - not currently used
My router (in bridge mode) is connected to the WAN port.
After setting up OpnSense, I can’t connect to the internet.
I tried to force DHCP (my router in bridge mode uses dhcpp to provide public IP), using “dhclient -4 -v vmbr1” (directly from proxmox shell) and it seems to work… a public IP is assigned/bounded. But when I try to ping anything, it does not work.
Is the vmbr0 using enp1s0 a typo? I imagine you meant enp9s0 since that is your Proxmox management bridge but it also can be used as the OPNsense LAN interface and management bridge for OPNsense.
You could try using the MAC address of your router (since it’s not being used) by setting it on the WAN interface in OPNsense to potentially minimize issues migrating to a new system/VM. Sometimes it can take a while for a lease to swap over to a new device (and sometimes ISPs require you to call them to change the MAC address).
You mentioned the Proxmox bridge you are using for the WAN interface could get the public IP? That seems odd because the VM using the bridge (which will have its own MAC address) should be what receives the public IP. I checked my Proxmox and I do not have any public IPs on my vmbr2 bridge that I am dedicating for the WAN interface in OPNsense.
Also, I tried using the mac address from my router on the wan in opnsense, but it did not help.
I understand now that the IP should not be on the proxmox nic but only inside opnsense on vtnet1.
The thing is, if I connect a laptop with DHCP to the router (while in bridge mode), the public IP is set quickly. Also, before I understood that the IP should not be set on the proxmox side, I tried dhclient (from proxmox client) and it worked.
I also tried to leave opnsense running all night and there was no IP in the morning.
Now I’m trying to force DHCP by using dhclient in shell in opnsense, but no lock for now.
Have you tried rebooting your modem? Some users have suggested doing that. I used to reboot the modem and then the router back in the day when there were Internet issues (on consumer grade equipment that wasn’t so good).
Not sure if that suggestion will help seeing how plugging a desktop directly into the modem gets a public IP immediately.
One other thing I thought of is, I’m assuming you don’t have any IP addresses set on the vmbr1 bridge or the parent interface?
You could check the live firewall logs to make sure something isn’t inadvertently configured to block traffic (sometimes when messing around trying to get set up and fixing things). Might be worth a look.