indeed I did polish it a bit and upload: https://youtu.be/w0WuoKVWAgI ;)

Thank you for the script though! I will have a look at modifying it in the
git

On Sun, 26 Aug 2018 at 20:04, Paul Vixie <vi...@fsi.io> wrote:

> On Sunday, August 26, 2018 4:25:13 PM UTC Paul Webster wrote:
> > howto start stuff auto:
> > https://www.youtube.com/watch?v=MidLqBs4_B8&feature=youtu.be
>
> very entertaining. some notes:
>
> note that rc.local is executed by the "." command from the /bin/sh
> instance
> that runs /etc/rc.d/local, and so, #! isn't relevant there, nor is "chmod
> +x".
>
> net.link.ether.inet.proxyall is documented in arp(4) and just means don't
> drop
> arp requests about addresses that aren't local. i prefer to let the bhyve
> guests answer for themselves, which they'll do, because the arp request is
> sent to the all ones address, and thus reaches all the guests.
>
> i do not use daemon -r for bhyve, because it ignores the the exit status.
> if
> bhyve exits with 0 i want to loop (recreate bhyve), if it's nonzero i want
> it
> to exit (poweroff, shutdown, or kernel panic). according to bhyve(8):
>
> > EXIT STATUS
> >
> >      Exit status indicates how the VM was terminated:
> >
> >      0       rebooted
> >      1       powered off
> >      2       halted
> >      3       triple fault
>
> you might be planning to explain how you interpret these exit statuses in
> the
> shell script you run from daemon, which in turn starts bhyve. however, it
> looks as if daemon -r only avoids the restart loop if it receives a
> SIGTERM,
> and i don't know how you'll deliver that. my /etc/rc.local script looks
> like
> this:
>
> > while true; do
> >
> >       ...
> >
> >         # we're using file descriptor #3 to get the bhyve exit code out.
> ugly.
> >         set $( ( ( sh vmrun.sh \
> >                 -c $cpucount \
> >                 -m $memorysize \
> >                 -t tap$tapif \
> >                 -d /dev/zvol/$zvol \
> >                 -C /dev/$cons \
> >                 -x \
> >                 $@ $vm \
> >                 2>&1; \
> >           echo $? >&3; ) | logger -t "$tag" ) 3>&1 )
> >         bhyve_exit=$1
> >
> >         echo === $bhyve_exit
> >         if [ "$bhyve_exit" -ne 0 ]; then
> >                 break
> >         fi
> >
> >         sleep 10
> > done
>
> --
> Vixie
>
>
_______________________________________________
freebsd-virtualization@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-virtualization
To unsubscribe, send any mail to 
"freebsd-virtualization-unsubscr...@freebsd.org"

Reply via email to