How to create a separate subnet with gateway?
mdbraber last edited by mdbraber
On my Docker VM I've created a separate (Docker) macvlan network with subnet 172.16.0.0/16 and gateway 172.16.1.1/32 (just as within the rest of the network). I'd like it to have its own subnet (e.g. 172.16.60.0/24) but that will also mean it needs a gateway within that subnet.
The solution I'm thinking of is creating a Virtual IP on the pfSense LAN interface with 172.16.60.1 and also create a gateway on the LAN interface under Sytem > Routing > Gateways. A bit similar to what is described here: https://www.reddit.com/r/PFSENSE/comments/9pa6t1/issue_with_virtual_ip_routing_in_hyperv/
I've got two questions:
- Would Virtual IP + extra gateways be the recommended solution for creating multiple subnets behind pfSense?
- Is it a problem that a new gateway e.g. 172.16.60.1 would fall inside the LAN subnet of 172.16.0.0/16 (or is this exactly how it should be)?
Current network configuration
Pfsense LAN interface: 172.16.10.1/16
VM hypervisor IP: 172.16.1.1/32 - gateway 172.16.10.1
VM (Docker host ) IP: 172.16.1.7/32 - gateway 172.16.10.1