Skip to main content

Guest Setup

As discussed in Introduction: Novice to Network Admin the goal is to run a router/firewall inside a LXC guest so there is little to no overhead when routing packets around. So I created an unpriviledged LXC guest with a Debian 10 template.

Resources

The mini PC this will run on isn't a powerhouse but should provide more than enough resources to serve the purpose and have a few spare cycles leftover for something useful like running Pi-hole.

Cores unlimited (4 cores)
Memory 2048 MiB
Swap 512 MiB
Root Disk 2 GB

Networking

DeviceIDName
physicalnet0eth0
virtionet1eth1

Because there is some overhead with using an Ethernet Bridge I only wanted to use one where it made the most sense. Since the Ethernet connection from the modem is a conceptual direct run I am passing one of the physical Ethernet interfaces from Proxmox to the LXC guest. This makes it unavailable to the host and allows the LXC guest direct access to it similar to how PCIPCI(e) Passthrough would work.

This can be accomplished with the following Proxmox/LXC configuration…configuration similar to what is shown below.

Be careful to not reuse the same index for `lxc.net.[index]` and `net[index]` values or else you'll have trouble booting your guest.

# /etc/pve/lxc/100.conf
net1: name=eth1,bridge=vmbr0,hwaddr=D6:A9:67:D5:66:22,type=veth
+ lxc.net.0.type: phys
+ lxc.net.0.link: enp1s0
+ lxc.net.0.name: eth0
DeviceIDName
physicalnet0eth0
virtionet1eth1