Allows starting of one or multiple bhyve instances within tmux on boot. See also: http://lists.freebsd.org/pipermail/freebsd-virtualization/2013-November/001694.html. pkg-message: Configuration is done completely though rc.conf. The rc script won't touch any devices for you (neither disk, nor tap) so you need to make sure all of those have been initialized properly. General setup: kldload vmm net.link.tap.up_on_open=1 Make it persistent: echo "net.link.tap.up_on_open=1" >> /etc/sysctl.conf cat >> /boot/loader.conf << EOF vmm_load="YES" EOF Minimal example: cat >> /etc/rc.conf << EOF cloned_interfaces="tap0 bridge0" bhyve_enable="YES" bhyve_diskdev="/dev/zvol/tank/bhyve/virt" EOF ifconfig tap0 create ifconfig bridge0 create service bhyve start tmux list-sessions tmux attach -t bhyve service bhyve status service bhyve stop Multi profile configuration example: cat >> /etc/rc.conf << EOF cloned_interfaces="tap0 tap1 bridge0" bhyve_enable="YES" bhyve_profiles="virt1 virt2" bhyve_virt1_diskdev="/dev/zvol/tank/bhyve/virt1" bhyve_virt2_tapdev="tap1" bhyve_virt2_diskdev="/dev/zvol/tank/bhyve/virt2" bhyve_virt2_memsize="8192" bhyve_virt2_ncpu="4" EOF ifconfig tap0 create ifconfig tap1 create ifconfig bridge0 create service bhyve start # start all service bhyve start virt2 # start individual tmux attach -t bhyve_virt1 tmux attach -t bhyve_virt1 service bhyve stop virt2 # stop individual service bhyve stop # stop all (by default ctrl-b d detaches from tmux). Fix: Patch attached with submission follows:
Hi, if you are still interested in having this port in FreeBSD, it needs to be reworked to support stage. See http://lists.freebsd.org/pipermail/freebsd-ports-announce/2014-May/000080.html Additionally, you need to provide some sort of quality assurance. In order of preference, we are looking for: 1) "poudriere testport" or "poudriere bulk -t" logs 2) Redports or tinderbox logs Please provide an updated shar file and attach a test log. Alternatively, please indicate if you are no longer interested in having this software in the Ports Collection and that we can close the PR. Thanks!
A commit references this bug: Author: adamw Date: Thu Aug 21 15:06:17 UTC 2014 New revision: 365563 URL: http://svnweb.freebsd.org/changeset/ports/365563 Log: Add sysutils/bhyve-rc: FreeBSD RC script to start bhyve guests in tmux. PR: 183604 Submitted by: Michael Gmelin Changes: head/sysutils/Makefile head/sysutils/bhyve-rc/ head/sysutils/bhyve-rc/Makefile head/sysutils/bhyve-rc/files/ head/sysutils/bhyve-rc/files/bhyve.in head/sysutils/bhyve-rc/pkg-descr head/sysutils/bhyve-rc/pkg-message
Committed, thanks. Is there any way you can give a more detailed pkg-descr? It's pretty thin. Maybe something describing what exactly the relationship between tmux and bhyve is here?