Date: Thu, 23 Jan 2014 17:26:19 -0500 From: Aryeh Friedman <aryeh.friedman@gmail.com> To: =?ISO-8859-1?Q?Jonas_B=FClow?= <jonas.bulow@gmail.com> Cc: "freebsd-virtualization@freebsd.org" <freebsd-virtualization@freebsd.org> Subject: Re: Linux on BHyVe in 10.0-RELEASE Message-ID: <CAGBxaXkaY_ZYKpmdHcRvkuY-kxK9F50jqmFjc__qj2pfarg_3Q@mail.gmail.com> In-Reply-To: <CAEGOEeUhWNTbTbT4j6BioQiAK2VMkGWTq3KPb4uc5DVBys4yug@mail.gmail.com> References: <CAEGOEeUo-spSp051MWg-4%2B_vDACBK9NqWOPz7LBdDEHvGS3=_w@mail.gmail.com> <52E0C1D4.9000304@freebsd.org> <CAEGOEeWbysCn5Ma-aGOLGmbJPTn0CTa%2BMjRvwGVYm7jJJ57coQ@mail.gmail.com> <52E0D1BB.2050807@callfortesting.org> <CAEGOEeVUvHmypGBgd0V=Ffhzex2zsVuihA8rbxhLX9QCFxvO%2Bg@mail.gmail.com> <CAGBxaXm1-0NBwOTx40V9C-Z0wF5a9y%2BHNMRuM-N5UansiiREeQ@mail.gmail.com> <CAEGOEeV2=3Nn-5rebUJfNL-xeutSZH5_i7HkiB9ucEC%2BPD2_nw@mail.gmail.com> <CAGBxaXkui_vc0RLNcXab6qE2YRXyXRcP-p=KmwtQBsF87mDYXw@mail.gmail.com> <CAEGOEeV7rOogDA3NhZFMjbQ30ygJ4s%2BnD=DkvMNj-KR3Vah35w@mail.gmail.com> <CAGBxaX=aBYeXVKC5TNW%2Bu_VNMbbrgU251XA0w7rVUmqZ=PvjAA@mail.gmail.com> <CAEGOEeVhK9mQ2xh3VPCoUNDQR5X-SE1ZEjnNp3CcRwmkMMCzRA@mail.gmail.com> <CAGBxaXkq=AG%2B%2BdwxpAu3W=0UQBgbWzutkSV=EauNGDsgTYNS1Q@mail.gmail.com> <CAEGOEeVshDQPm5pU0B5Mq5M3Bw3F2u1oMteTRbm8PY7qyWt=zA@mail.gmail.com> <CA%2BD9QhvsQ1oB%2BXL8fmB3P2XCXnuO2ONnf5zUSNB-CBdpVm5XWg@mail.gmail.com> <CAEGOEeXWE0hZhLBCXR2CNVwE9GH9xOMgzKGtfoxEkq9HhRretQ@mail.gmail.com> <CAEGOEeWt2YKieThBrK-fC51_Jq5MWQr38fZ05oJtkTG6WOkWww@mail.gmail.com> <CAFgRE9GNh%2BbVEhW5COtx4CattM0aVMFiEFabqWcw8dXf9Pc36w@mail.gmail.com> <CAEGOEeUhWNTbTbT4j6BioQiAK2VMkGWTq3KPb4uc5DVBys4yug@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
I will have this or something like this encapslated into the petitecloud run scripts by monday (as well fixing the issues in the other thread) On Thu, Jan 23, 2014 at 5:20 PM, Jonas B=FClow <jonas.bulow@gmail.com> wrot= e: > Hi, > > I managed to get it working again. I did the last grub step wrong. So, th= e > step-by-step instructions how to install ubuntu 13.10 are: > > kldload vmm > kldload if_tap > kldload bridgestp > kldload if_bridge > ifconfig tap0 create > ifconfig bridge0 create > ifconfig bridge0 up > ifconfig bridge0 addm tap0 addm em0 > > mkdir ubuntu > ...fetch ubuntu13.10 iso image and put it in ubuntu/ubuntu.iso > create the file ubuntu/device.map with the following content (2 lines): > (hd0) ./ubuntu/ubuntu.img > (cd0) ./ubuntu/ubuntu.iso > > truncate -s 8G ubuntu/ubuntu.img > > grub-bhyve -r cd0 -m ./ubuntu/device.map -M 2048 ubuntu > /usr/sbin/bhyve -c 1 -m 2048 -A -I -H -s 0,hostbridge -s > 2,virtio-blk,./ubuntu/ubuntu.img -s 3,virtio-net,tap0 -s > 4,ahci-cd,./ubuntu/ubuntu.iso -S 31,uart,stdio ubuntu > > ...install ubuntu. > > bhyvectl --destroy --vm=3Dubuntu > > grub-bhyve -r hd0,msdos1 -m ./ubuntu/device.map -M 2048 ubuntu > ...select ubuntu > ...see some errors: > > error: file `/boot/grub/x86_64-emu/all_video.mod' not found. > > error: file `/boot/grub/x86_64-emu/gzio.mod' not found. > > error: file `/boot/grub/x86_64-emu/part_msdos.mod' not found. > > error: file `/boot/grub/x86_64-emu/ext2.mod' not found. > > /usr/sbin/bhyve -c 1 -m 2048 -A -I -H -s 0,hostbridge -s > 2,virtio-blk,./ubuntu/ubuntu.img -s 3,virtio-net,tap0 -s > 4,ahci-cd,./ubuntu/ubuntu.iso -S 31,uart,stdio ubuntu > ...boots > ...login > > jonas@ubuntu:~$ lsb_release -a > > No LSB modules are available. > > Distributor ID: Ubuntu > > Description: Ubuntu 13.10 > > Release: 13.10 > > Codename: saucy > > jonas@ubuntu:~$ uname -a > > Linux ubuntu 3.11.0-12-generic #19-Ubuntu SMP Wed Oct 9 16:20:46 UTC 2013 > x86_64 x86_64 x86_64 GNU/Linux > > > Note: there is no clean way of exiting a bhyve vm other than killing it > (after halt or shutdown in the guest). The vm must be destroyed before > starting it again. Trying to run the same bhyve command line again just > hangs (vmidle, high CPU). procstat gives: > > PID TID COMM TDNAME KSTACK > > 2381 100531 bhyve mevent <running> > > 2381 100532 bhyve vtnet-3:0 tx mi_switch > sleepq_catch_signals sleepq_wait_sig _sleep umtxq_sleep do_wait > __umtx_op_wait_uint_private amd64_syscall Xfast_syscall > > 2381 100533 bhyve vcpu 0 mi_switch sleepq_timedwait > msleep_spin_sbt vm_run vmmdev_ioctl devfs_ioctl_f kern_ioctl sys_ioctl > amd64_syscall Xfast_syscall > > > > /J > > > > > On Thu, Jan 23, 2014 at 10:45 PM, Neel Natu <neelnatu@gmail.com> wrote: > > > Hi Jonas, > > > > On Thu, Jan 23, 2014 at 1:02 PM, Jonas B=FClow <jonas.bulow@gmail.com> > > wrote: > > > I had one working ubuntu13.10 vm instance but I'm unable to reproduce > it. > > > When I try to start the vm I get: > > > > > > /usr/sbin/bhyve -c 1 -m 2048 -A -I -H -s 0,hostbridge -s > > > 2,virtio-blk,./vm/vm1/vm1.img -s 3,virtio-net,tap1 -s > > > 4,ahci-cd,./vm/vm1/vm1.iso -S 31,uart,stdio vm1 > > > > > > vm exit[0] > > > > > > reason VMX > > > > > > rip 0x0000000000000000 > > > > > > > > > inst_length 0 > > > > > > > > > error 0 > > > > > > > > > exit_reason 33 > > > > > > > > > > > > qualification 0x0000000000000000 > > > > > > > Looks like you are running into every possible problem there is :-) > > > > Anyways, could you confirm that you are loading the guest kernel into > > 'vm1' using grub-bhyve before executing the command above? > > > > best > > Neel > > > > > > > > > > > > > > > > > /J > > > > > > > > > On Thu, Jan 23, 2014 at 5:00 PM, Jonas B=FClow <jonas.bulow@gmail.com= > > > wrote: > > > > > >> I will describe the steps when I manage to reproduce the installatio= n. > > >> Right now I get stuck with undestroyable vm instances: > > >> > > >> root@bulow:/mnt/bhyve-script # ls /dev/vmm/ > > >> > > >> lin0 > > >> > > >> root@bulow:/mnt/bhyve-script # bhyvectl --destroy --vm=3Dlin0 > > >> > > >> errno =3D 22 > > >> > > >> > > >> On Thu, Jan 23, 2014 at 3:44 PM, Matthias Gamsjager < > > mgamsjager@gmail.com>wrote: > > >> > > >>> Could you elaborate what you did to get it working? > > >>> > > >>> > > >>> On Thu, Jan 23, 2014 at 3:41 PM, Jonas B=FClow <jonas.bulow@gmail.c= om > > >wrote: > > >>> > > >>>> Success. I have a working ubuntu 13.10 running under bhyve on > FreeBSD > > >>>> 10.0-RELEASE. > > >>>> > > >>>> > > >>>> > > >>>> /J > > >>>> > > >>>> > > >>>> On Thu, Jan 23, 2014 at 11:37 AM, Aryeh Friedman > > >>>> <aryeh.friedman@gmail.com>wrote: > > >>>> > > >>>> > > > >>>> > > > >>>> > > > >>>> > On Thu, Jan 23, 2014 at 5:05 AM, Jonas B=FClow < > jonas.bulow@gmail.com > > >>>> >wrote: > > >>>> > > > >>>> >> I do use the precanned bhyve-script "vm0" (if that is what you > > mean). > > >>>> It > > >>>> >> explicitly mentions linux support. bhyveload can't be user for > > other > > >>>> images > > >>>> >> than FreeBSD so I don't know how to use your script for a linux > OS > > >>>> >> > > >>>> > > > >>>> > Since I have not used bhyve-grub personally yet I can not > recommend > > >>>> what > > >>>> > the correct loader command line but if bhyve-script is in anyway > > >>>> related to > > >>>> > vmrun.sh I would be highly suspicious of any command lines you > > manage > > >>>> to > > >>>> > extract from it since they are often not the ones actual called. > > >>>> > > > >>>> > > > >>>> >> > > >>>> >> I assume the image is file backed as I have not assigned a > > dedicated > > >>>> >> partition to the vm (and I don't know how to do that). > > >>>> >> > > >>>> > > > >>>> > You can keep them anywhere no need for a special volume (mater o= f > > fact > > >>>> I > > >>>> > was just reusing the name of one of the diretoriess that PC > creates > > >>>> during > > >>>> > install even without it being a different vol [just assumes any = FS > > >>>> > boundaries are the host OS's problem)... you can put the disk > image > > any > > >>>> > where (your home directory would be fine for example) > > >>>> > > > >>>> _______________________________________________ > > >>>> freebsd-virtualization@freebsd.org mailing list > > >>>> http://lists.freebsd.org/mailman/listinfo/freebsd-virtualization > > >>>> To unsubscribe, send any mail to " > > >>>> freebsd-virtualization-unsubscribe@freebsd.org" > > >>>> > > >>> > > >>> > > >> > > > _______________________________________________ > > > freebsd-virtualization@freebsd.org mailing list > > > http://lists.freebsd.org/mailman/listinfo/freebsd-virtualization > > > To unsubscribe, send any mail to " > > freebsd-virtualization-unsubscribe@freebsd.org" > > > _______________________________________________ > freebsd-virtualization@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-virtualization > To unsubscribe, send any mail to " > freebsd-virtualization-unsubscribe@freebsd.org" > --=20 Aryeh M. Friedman, Lead Developer, http://www.PetiteCloud.org
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAGBxaXkaY_ZYKpmdHcRvkuY-kxK9F50jqmFjc__qj2pfarg_3Q>