TrueNAS Core install qemu-guest-agent from FreeBSD repo

someone23

Cadet
Joined
Nov 26, 2023
Messages
4
Hey, I'm realtiv new in using FreeBSD. so please forgive me if trivial.
I use TrueNAS Core inside proxmox and want to install quemu-guest-agent. I know there some ready to use binary's from other users, but i don't want to use them, because of security concerns.

So what i did was editing /usr/local/etc/pkg/repos/local.conf & /usr/local/etc/pkg/repos/FreeBSD.conf and changed enabled state in both.
Code:
pkg install -F qemu-guest-agent
# change back edition of repo files
pkg add /var/cache/pkg/qemu-guest-agent*.pkg


But wen i try to start it, i get an error:
Code:
critical: error opening channel '/dev/vtcon/org.qemu.guest_agent.0': No such file or directory
critical: failed to create guest agent channel
critical: failed to initialize guest agent channel

maybe i miss some dependencys, but how i can get them?

Or is there a better way to build qemu-guest-agent for it?
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
You are missing the VirtIO console driver. Maybe you can load it with kldload. Maybe you can't and you will need to mess with your TN in ways that might break it. Good luck.
 

someone23

Cadet
Joined
Nov 26, 2023
Messages
4
Thank you for the hints. I guess i will try, worst case its a test of my backup concept ;)
 

someone23

Cadet
Joined
Nov 26, 2023
Messages
4
Some small update, I got it partially running.
It is possible to get the kernel modules from a native FreeBSD installation, there the modules are all pre installed.
You can find it under `/boot/kernel/virtio*` the FreeBSD version must match the TrueNAS Version, best check `/etc/os-release` on TrueNAS.

But this is only a partially success, the main reason for me are the balloon drivers, currently my TrueNAS System has 24GB RAM assigned, without balloon driver, there consume all of this regardless of real needs.

I can only hop that the next Core release will include driver and had (better) support for qemu , which should not be a problem as the drivers are already available in native FreeBSD.

For now i guess i switch to scale because of balloon support and switch back if the situation is better.
 

someone23

Cadet
Joined
Nov 26, 2023
Messages
4
oh i miss the point that only the console driver get loaded, the TN kernel won't load the other modules, not fully clear what the problem here is, maybe some lack of support inside the kernel.
 
Top