Proxmox Ballooning and pfSense

I have a pfsense vm in proxmox. With Automatic Memory Allocation enabled, proxmox web management still reports different ram usage than that on pfsense GUI. Does it mean that ballooning isn't working?

I assumed it'd work out of the box according to this: "The following instructions are not necessary on pfSense 2.2 and later ..."
https://doc.pfsense.org/index.php/VirtIO_Driver_Support

In addition, the guide below states that fixed memory should be used. To what extent is this necessary? I did not come across an issue that FreeBSD has with ballooning.
https://doc.pfsense.org/ind…/Virtualizing_pfSense_on_Proxmox

Thanks

You probably don't have guest tools installed because it's pfSense.
https://pve.proxmox.com/wiki/PfSense_Guest_Notes
It'd make sense that those tools would need to be installed for proper guest introspection.

Guest tools? There aren't any for proxmox as far as I know and according to a quick google search.

Proxmox is OpenVZ or KVM if I understand correctly.
"Proxmox is fake hypervisor software" -NetBandit

LXC and KVM.

Ain't fake though.

1 Like

Proxmox is sort of its own animal.... But it's certainly not on the level of ESX or Xen.

1 Like

Just give PfSense 512MB or a Gig and leave it be. I keep my PfSense install at 512MB in ESXI and it only uses 40% of it (and that's from looking at the pf gui currently)


ESXI Free Version FTW btws

1 Like

I use free ESXi in production, and it's great... until you have to do anything like move VMs to different datastores, or change drives, etc. It has practically no tools built in to facilitate that stuff.

1 Like

I have a tiny ssd (32GB) to store my FreeNas and PfSense installs and then I keep everything else on a NFS datastore hosted by FreeNas, so I don't really have issues migrating VMs to other places since there is only the NFS datastore as an option, and also because I don't really have other VMs that I really need running that often as it is. But I do love it for the hardware passthrough and the ease of use, which is A+.

You want the VirtIO tools. Frankly, working with FreeBSD is a big enough pain in the ass that I don't use VirtIO tools with it. But if you want to give it a shot, here are a couple of links that may help.

https://www.freebsd.org/cgi/man.cgi?query=virtio_balloon&sektion=4&apropos=0&manpath=FreeBSD+11.0-RELEASE+and+Ports

https://www.area536.com/projects/freebsd-as-a-kvm-guest-using-virtio/

And for when you virtualize a Windows environment.

https://fedoraproject.org/wiki/Windows_Virtio_Drivers

LOL! Linode disagrees with you. Which is pretty impressive given that they were stalwart supporters of Xen for some time.

pfSense 2.3.4 (the one that I'm using) runs on Freebsd 10.3 therefore the VirtIO drivers are built into the kernel and are supposed to work out of the box. The VirtIO network interface do but my issue here is with the ballooning.

1 Like

It is nothing like that. It is more like a Front-end for existing badass technologies (KVM and LXC).

It is actually the only hypervisor that isn't its own animal. Also, you can't beat the performance and efficiency of LXC :slight_smile:.

3 Likes

I'm dealing with a system of 4 Gig ram here :sweat_smile:. Every MB counts, and pfsense most of the time doesn't go past 128MB (but the makers of pfsense say the minimum is 256). It is also a good thing to learn.

Those drivers are indeed installed. I tested it in a VM on my server, granted I'm just using straight libvirt+KVM rather than Proxmox, but it should work the same. The balloon driver did indeed work as expected.

When installing pfSense, did you use the standard kernel or the embedded kernel? I used the standard. Also are you just using top to check the free memory, or is there something else you're looking at? Just want to make sure we're both looking at the same stuff.

I used the standard kernel. I look at the memory usage on pfsense's web gui and compare it the the memory usage of the pfsense vm on proxmox's web gui. And they are off by a couple hundred MBs.

Maybe try hopping into pfSense's command line and hitting up top to see how much memory is free when you restrict the VM. I mean, the usage should show up in pfSense's gui, but just to be sure.

If you're not tied to pfSense, you could get OpenWRT x86_64 ext4 images , they happily fit inside 64M of ram for basic routing/firewalling/nat/shaping/DNS/DHCP/upnp... type of usage, as you install more stuff, you can add ram to the VM

I will only consider it if somehow it can install as a LXC. I got used to pfsense.

I don't see why it wouldn't be possible to run it in a container - same as you would any other distro, just make sure you assign it its own network namespace.

EDIT: on second thought, you probably want all the namespaces separate .. just because it is a distro