unRAID 6 Beta 6: VM Quick Start Guide (KVM / Xen)


jonp

Recommended Posts

Nope, now the VM won't start at all.  When I do xl top, I see this message repeating every few seconds...

 

                                                                      Found interface vif1.0 but domain 1 does not exist.

 

Should I replace device_model_version="qemu-xen-traditional"  with a different 'version' instead?  Perhaps with device_model_version="qemu-xen"?

 

I'll try that, to see what happens.

 

That didn't work either (not that I really thought it would).

 

thanks for the late evening help!!!  I'll make the changes now, and report back.

 

yes, this VM has the  GPLPV drivers installed already.

 

No problem.  Let me know how this goes.  Also, you can probably drop a bunch of other stuff from the config as well and it'd work just the same if not better.  Here's what I would use (I edited yours):

 

name = 'windows8'
builder = 'hvm'
vcpus = '4'
memory = '2048'
#maxmem = '6144'
localtime = 1
disk = [ 'phy:/mnt/cache/VM/Windows8/windows8.img,hda,w' ]
boot = 'c'
xen_platform_pci='1'
on_poweroff = 'destroy'
on_reboot = 'restart'
on_crash = 'restart'
vif = [ 'mac=00:16:3E:C8:C8:C8,bridge=br0' ]
viridian = '1'
vnc = '1'
vnclisten = '0.0.0.0'
vncpasswd = ''
vncdisplay = 1

usb = '1'
usbdevice = ['tablet','host:0a12:0001','host:045e:0745','host:174c:5106','host:045e:00db','host:147a:e03e']
pci = [ '00:14.0','01:00.0','01:00.1','09:00.0','00:1b.0' ]

 

Also curious about your USB pass through.  you have usb=1 and VNC plus are you doing a GPU pass through?  Is this working properly for both VNC access as well as your USB input devices like mouse and keyboard?  Or are you passing through the PCI controller for the USB devices themselves?

 

That didn't work either.  I get the same recurring message in xl top...

 

                                                                      Found interface vif1.0 but domain 1 does not exist.

 

I don't imagine a reboot of unRAID will help.

 

Weird, I reverted my cfg back to exactly what I posted earlier, which started, but lacked network access.  Even that cfg doesn't actually start windows now.

 

I'll reboot, change it to what you just posted, and try again.

 

love the bleeding edge ;)

Link to comment
  • Replies 87
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Posted Images

Nope, now the VM won't start at all.  When I do xl top, I see this message repeating every few seconds...

 

                                                                      Found interface vif1.0 but domain 1 does not exist.

 

Should I replace device_model_version="qemu-xen-traditional"  with a different 'version' instead?  Perhaps with device_model_version="qemu-xen"?

 

I'll try that, to see what happens.

 

You shouldn't need to replace it at all.  That flag isn't necessary anymore.  Question though, when you upgraded to v6, did you replace the xen file on your flash drive with the new one in the zip file?

Link to comment

Also curious about your USB pass through.  you have usb=1 and VNC plus are you doing a GPU pass through?  Is this working properly for both VNC access as well as your USB input devices like mouse and keyboard?  Or are you passing through the PCI controller for the USB devices themselves?

 

I've struggled a bit with USB passthru.  I tried testing various settings, and here is how far I got before I got something that mostly worked.  I believe this passes thru all of my USB ports on the back of the motherboard, but with the VM not starting right now, I can't confirm that.  it does recognize connecting things to a USB port, as you would expect.  I actually thought it passed thru ALL USB ports, including the one the unRAID thumb drive is connected to, but I would think this must be a mistake, as I wouldn't expect me to have access to that thumb drive in unRAID this way, but I certainly do, so I'm not sure now.

 

usb = '0'
usbdevice = ['tablet','host:0a12:0001','host:045e:0745','host:174c:5106','host:045e:00db','host:147a:e03e']
pci = [ '01:00.0','01:00.1','09:00.0','00:1b.0' ]
Did not work

usb = '1'
usbdevice = ['tablet','host:0a12:0001','host:045e:0745','host:174c:5106','host:045e:00db','host:147a:e03e']
pci = [ '01:00.0','01:00.1','09:00.0','00:1b.0' ]
Only wired USB keyboard worked.  USB IR in other front port did not work

usb = '0'
usbdevice = ['tablet','host:174c:3074','host:0a12:0001','host:045e:0745','host:174c:5106','host:045e:00db','host:147a:e03e']
pci = [ '01:00.0','01:00.1','09:00.0','00:1b.0' ]
didn't start, then did start, but soon after updating devices in windows, it shut right down automatically, then would not start again.

usb = '1'
usbdevice = ['tablet','host:174c:3074','host:0a12:0001','host:045e:0745','host:174c:5106','host:045e:00db','host:147a:e03e']
pci = [ '01:00.0','01:00.1','09:00.0','00:1b.0' ]
did not start, gave errors in log about xHCI issues

usb = '0'
usbdevice = ['tablet','host:0a12:0001','host:045e:0745','host:174c:5106','host:045e:00db','host:147a:e03e']
pci = [ '00:14.0','01:00.0','01:00.1','09:00.0','00:1b.0' ]
started, ran for a while, then started updating devices, then froze solid.  shutting down windows didn't 'clear the screen' and windows remained frozen.  had to reboot unRAID to get meaningful input on the screen.

usb = '1'
usbdevice = ['tablet','host:0a12:0001','host:045e:0745','host:174c:5106','host:045e:00db','host:147a:e03e']
pci = [ '00:14.0','01:00.0','01:00.1','09:00.0','00:1b.0' ]
worked

 

As for GPU passthur, yes, I currently am passing thru an HD5550 card to the VM, but hope to figure out how to passthru the iGPU once I get everything else straightened out.

 

I am going to guess that while the CoW format allows for thin provisioning it is not going to dynamically check the existing volume and collapse white space when converting. Since you had a 40GB disk image that was using 40GB of space, the new file will do the same. It's only when you are creating a brand new file that it's going to start tiny and grow with usage.

 

Makes sense.  Unfortunate, but I'll 'worry' about it later, if ever.  I don't feel like installing Windows 8.1 from scratch again just now ;)

 

 

** unRAID just finished rebooting, and your modified cfg did start windows this time!  :D  I have not checked to see if passthru is all working, as the family has turned to old fashioned live TV right now.

Link to comment

Question though, when you upgraded to v6, did you replace the xen file on your flash drive with the new one in the zip file?

 

yes, definitely.

 

Also, is this the VM you just converted to QCOW2 as well?  We hadn't tested that image format with Xen yet, so you might be treading on foreign territory there...

 

No, my original VM, which I've been using all along.  I know better than try too many changes at one time.  Once I confirm this is working fine, I'll try to amend to see if the new image works with this also.

 

One thing at a time.

Link to comment

I've struggled a bit with USB passthru.  I tried testing various settings, and here is how far I got before I got something that mostly worked.  I believe this passes thru all of my USB ports on the back of the motherboard, but with the VM not starting right now, I can't confirm that.  it does recognize connecting things to a USB port, as you would expect.  I actually thought it passed thru ALL USB ports, including the one the unRAID thumb drive is connected to, but I would think this must be a mistake, as I wouldn't expect me to have access to that thumb drive in unRAID this way, but I certainly do, so I'm not sure now.

 

Ok, there are two ways to accomplish USB pass through:  passing through the USB PCI Host Bust Adapter or passing through individual USB devices themselves.  To pass through the USB HBA, you have to locate it using lspci and enter it's location in the pci flag in the CFG file.  I don't use this method for USB controllers because I haven't found a reason to do so yet.  The other method is using USB Pass Through which is done through the usb flag in the CFG file.  Here you specify the specific devices, not ports, that you want to pass through.  You can move a device to different ports but it will still have the same ID on your system under lsusb.  Even after reboots!

 

So just put the usb flags in for the devices you want (host:####:####) and drop the rest, including tablet.  I also recommend setting usb = 0.  usb = 1 is to EMULATE a fake USB device for VNC control which conflicts with how USB pass through works normally.  Same reason you should NOT use VNC with a GPU pass through VM.  One or the other ;-).

 

Also, what are all your PCI devices?  I imagine 01:00.0/1 is your GPU/HDMI Audio, but what is 09:00.0 and 00:1b.0?  If these are PCI pass through for USB Host Bus Adapters, get rid of them.  Just pass through your GPU/HDMI Audio.

 

** unRAID just finished rebooting, and your modified cfg did start windows this time!  :D  I have not checked to see if passthru is all working, as the family has turned to old fashioned live TV right now.

 

Glad to hear that it booted!  Hoping we can figure out the root cause of any of the other issues you've been having.  Gonna call it a night for tonight, but keep us posted!

Link to comment

 

I have not checked to see if passthru is all working, as the family has turned to old fashioned live TV right now.

 

AHH THE HORROR!!

 

Yeah, I hate commercials!!

 

sadly, windows won't actually start.  It's telling me it didn't start correctly, and offering me to restart or automatic repair, none of which is working :(

 

I don't know if this is related to the several tries to start it before I rebooted unRAID, or a side effect of the new cfg, or something else.  I'll try a few repair options to see if I can get it running, and if not, I'll change the cfg back to what I had, but with just that qemu line removed, and see how that goes.

Link to comment

Ok, there are two ways to accomplish USB pass through:  passing through the USB PCI Host Bust Adapter or passing through individual USB devices themselves.  To pass through the USB HBA, you have to locate it using lspci and enter it's location in the pci flag in the CFG file.  I don't use this method for USB controllers because I haven't found a reason to do so yet.  The other method is using USB Pass Through which is done through the usb flag in the CFG file.  Here you specify the specific devices, not ports, that you want to pass through.  You can move a device to different ports but it will still have the same ID on your system under lsusb.  Even after reboots!

 

So just put the usb flags in for the devices you want (host:####:####) and drop the rest, including tablet.  I also recommend setting usb = 0.  usb = 1 is to EMULATE a fake USB device for VNC control which conflicts with how USB pass through works normally.  Same reason you should use VNC with a GPU pass through VM.  One or the other ;-).

 

Also, what are all your PCI devices?  I imagine 01:00.0/1 is your GPU/HDMI Audio, but what is 09:00.0 and 00:1b.0?  If these are PCI pass through for USB Host Bus Adapters, get rid of them.  Just pass through your GPU/HDMI Audio.

 

...

 

Glad to hear that it booted!  Hoping we can figure out the root cause of any of the other issues you've been having.  Gonna call it a night for tonight, but keep us posted!

 

I couldn't get anything to work without 'tablet' in my testing earlier, nor with usb=0.  I think I prefer to passthru the whole controller, so that if/when I connect any new device (phone, camera, GPS, keyboard, new mouse, whatever), it would just be recognized by windows, by virtue of being on the controller, whereas if I only pass thru the devices indivindually, I would have to restart the VM, after finding the host # in unRAID, then changing the syslinux.cfg file, which is a pita if you just want to grab some photos, or something from a friends phone, as one example.

 

With that said, it's not that often this happens, so not a huge deal.  so far, even when only passing on USB controller (or 4 shown by lsusb), it seems to passthru ALL the USB ports, so not perfect either.  I'll probably play around with this some more in the next week or so, once the basics are working again.

 

as for what my devices are...

 

Bus	Device      	ID      	Description                        	Driver/Note                	Speed
001	002	8087:8008	Intel Corp.                 		                                       	2.00
002	002	8087:8000	Intel Corp.                 		                                       	2.00
003	002	174c:2074	ASMedia Technology Inc.                 	                	        2.10
004	003	174c:3074	ASMedia Technology Inc                 		                         	3.00
001	001	1d6b:0002	Linux Foundation 2.0 root hub     	Linux 3.10.24p-unRAID ehci_hcd  	2.00
002	001	1d6b:0002	Linux Foundation 2.0 root hub     	Linux 3.10.24p-unRAID ehci_hcd  	2.00
003	001	1d6b:0002	Linux Foundation 2.0 root hub     	Linux 3.10.24p-unRAID xhci_hcd         	2.00
004	001	1d6b:0003	Linux Foundation 3.0 root hub     	Linux 3.10.24p-unRAID xhci_hcd         	3.00
002	003	13fe:3d00	Kingston Technology Company Inc.	Patriot thumb drive             	2.00
003	003	045e:00db	Microsoft Corp.                   	Natural Ergonomic Keyboard 4000 V1.0    2.00
003	004	147a:e03e	Formosa Industrial Computing, Inc.	Infrared Receiver [iR605A/Q]       	2.00
003	005	045e:00dd	Microsoft Corp.                   	Comfort Curve Keyboard 2000 V1.0    	2.00
003	006	051d:0002	American Power Conversion         	Uninterruptible Power Supply       	2.00
003	007	045e:0745	Microsoft Corp.                   	Nano Transceiver v1.0 for Bluetooth    	2.00
003	008	0a12:0001	Cambridge Silicon Radio, Ltd        	Bluetooth Dongle (HCI mode)       	1.10
004	002	174c:5106	ASMedia Technology Inc.             	Transcend StoreJet (external drive)    	3.00

 

As for the PCI devices, here they are (sorry, I'm too lazy/tired to format this table tonight)...

 

Address	Device               	Description                                	What is
00:03.0	Audio device	Intel Corporation Haswell HD Audio Controller (rev 06)	HDMI Audio
01:00.1	Audio device	AMD/ATI Redwood HDMI Audio [Radeon HD 5000 Series]	HDMI Audio
00:1b.0	Audio device	Intel Corporation Lynx Point High Definition Audio Controller (rev 04)	Creative Sound Core3D
00:19.0	Ethernet controller	Intel Corporation Ethernet Connection I217-V (rev 04)	Left Motherboard LAN
07:00.0	Ethernet controller	Intel Corporation I211 Gigabit Network Connection (rev 03)	Right Motherboard LAN
00:00.0	Host bridge	Intel Corporation Haswell DRAM Controller (rev 06)	8GB DDR3 Memory
00:1f.0	ISA bridge	Intel Corporation Lynx Point LPC Controller (rev 04)	
09:00.0	Multimedia controller	Philips Semiconductors SAA7160 (rev 02)	TV Tuner Card
00:01.0	PCI bridge	Intel Corporation Haswell PCI Express x16 Controller (rev 06)	
00:01.1	PCI bridge	Intel Corporation Haswell PCI Express x8 Controller (rev 06)	
00:01.2	PCI bridge	Intel Corporation Haswell PCI Express x4 Controller (rev 06)	
00:1c.0	PCI bridge	Intel Corporation Lynx Point PCI Express Root Port #1 (rev d4)	
00:1c.1	PCI bridge	Intel Corporation Lynx Point PCI Express Root Port #2 (rev d4)	
00:1c.2	PCI bridge	Intel Corporation Lynx Point PCI Express Root Port #3 (rev d4)	
00:1c.3	PCI bridge	Intel Corporation Lynx Point PCI Express Root Port #4 (rev d4)	
00:1c.4	PCI bridge	Intel Corporation Lynx Point PCI Express Root Port #5 (rev d4)	
00:1c.5	PCI bridge	Intel Corporation Lynx Point PCI Express Root Port #6 (rev d4)	
06:00.0	SATA controller	ASMedia Technology Inc.ASM1062 Serial ATA Controller (rev 01)	SATA3_A4 shared with eSATA
08:00.0	SATA controller	ASMedia Technology Inc.ASM1062 Serial ATA Controller (rev 01)	SATA3_A4 shared with eSATA
00:1f.2	SATA controller	Intel Corporation Lynx Point 6-port SATA Controller 1 [AHCI mode] (rev 04)	6 x SATA3 controller
03:00.0	SCSI storage controller	Marvell Technology Group Ltd. 88SX7042 PCI-e 4-port SATA-II (rev 02)	Rosewill 4 x SATA2 controller
00:1f.3	SMBus	Intel Corporation Lynx Point SMBus Controller (rev 04)	
00:14.0	USB controller	Intel Corporation Lynx Point USB xHCI Host Controller (rev 04)	USB3 controller
00:1a.0	USB controller	Intel Corporation Lynx Point USB Enhanced Host Controller #2 (rev 04)	USB2 controller
00:1d.0	USB controller	Intel Corporation Lynx Point USB Enhanced Host Controller #1 (rev 04)	USB2 controller
00:02.0	VGA compatible controller	Intel Corporation Haswell Integrated Graphics Controller (rev 06)	HD4600
01:00.0	VGA compatible controller	AMD/ATI Redwood LE [Radeon HD 5550]	HD5550

Link to comment

I converted a CentOS IMG to qcow and used the example XML you provided and modified only to apply to my local paths and CPU.

 

I get the following error on launch:

root@NAS:/mnt/vm/CentOS# virsh create centos.xml
error: Failed to create domain from centos.xml
error: internal error: unexpected domain type kvm, expecting xen

 

XML file:

	<domain type='kvm'>
  <name>CentOS</name>
  <uuid>0ea490aa-5de5-4d04-a383-50a1ec6f1639</uuid><!-- uuidgen -->

  <memory unit='GB'>8</memory>
  <currentMemory unit='GB'>8</currentMemory>

  <vcpu>8</vcpu>

  <os>
    <type arch='x86_64' machine='q35'>hvm</type>
    <loader>/usr/share/qemu/bios-256k.bin</loader>
    <boot dev='cdrom'/>
  </os>

  <features>
    <acpi/>
  </features>

  <on_poweroff>destroy</on_poweroff>
  <on_reboot>restart</on_reboot>
  <on_crash>destroy</on_crash>

  <devices>
<!-- VIRTUAL DISK (IMG)-->
    <disk type='file' device='disk'>
     <source file='/mnt/xen/CentOS/centos.qcow'/>
     <target dev='hda'/>
    </disk>

<!-- VIRTUAL CD-ROM (ISO)
    <disk type='file' device='cdrom'>
     <source file='/mnt/path/to/isos/boot.iso'/>
     <target dev='hda' bus='ide'/>
     <readonly/>
    </disk> -->


    <graphics type='vnc' port='5900'>
      <listen type='address' address='0.0.0.0'/>
    </graphics>

    <interface type='bridge'>
        <source bridge='xenbr0'/>
    </interface>

    <emulator>/usr/bin/qemu-system-x86_64</emulator>

    <input type='mouse' bus='ps2'/>

  </devices>

</domain>

Link to comment

I'm completely new to VM setups.  Do I need to give UnRAID dedicated RAM?  How do I workout the correct amount of RAM to use for each VM?  Is their a n00b/novice guide?

 

No, you give each VM dedicated RAM, which takes from the RAM available to unRAID.  As for how much you need for each VM, it really depends on what you intend to do with each VM.  For Windows, I wouldn't go less than 2GB.  In previous betas, if you gave over 3GB of RAM to windows AND passed thru a GPU, it could cause problems, but I think that might have been fixed with beta6, but I'm still working on getting my windowsVM running in the new beta, so cannot test.

 

For VM's that will see a lot of transcoding action, or other memory heavy usage, maybe 4GB is a good place to start.

 

The good news is that once you have the VM built and running, it's really fast and easy to change the amount you allocate, so you can pretty much just do trial and error.

 

Have fun.

Link to comment
Justin, drop this: device_model_version="qemu-xen-traditional"

Not necessary anymore.

Jon, both of my Windows ( Windows 7 & Windows 8 ) VM's do not start if I'm not using device_model_version="qemu-xen-traditional.

Seems to be the same issue that Justin has. Here is my entire win7.cfg (win8.cfg looks similar, only the path information is different) that is working:

name = 'win7'
builder = 'hvm'
vcpus = '4'
memory = '2048'
device_model_version="qemu-xen-traditional"
disk = [
        'file:/mnt/cache/.VMs/win7/win7.img,hda,w',
#       'phy:/dev/sr0,ioemu:hdc:cdrom,w',
#       'file:/mnt/cache/.VMs/win7/win7.iso,ioemu:hdc:cdrom,r'
        ]
vif = [ 'mac=00:16:3e:a1:bc:a5, bridge=br0' ]
on_poweroff = 'destroy'
on_reboot = 'restart'
on_crash = 'restart'
boot = 'dc'
acpi = '1'
apic = '1'
viridian = '1'
xen_platform_pci='1'
sdl = '0'
vnc = '1'
vnclisten = '0.0.0.0'
vncpasswd = ''
stdvga = '0'

# CONFIG FOR VNC ACCESSIBILITY:
# usb=1
# usbdevice='tablet'

# WITH USB PASSTHROUGH, COMMENT OUT THE ABOVE TWO ITEMS AND UNCOMMENT THESE:
# LOOK UP VIA lsusb COMMAND IN CONSOLE
usb=0
usbdevice = [ 'host:0d8c:013c' ]
# pci = [ '03:00.0' ]

Link to comment

Okay, I finally got Windows to boot.  I had to add the path to my .iso, so that windows could use it to "Refresh" the image, which was basically removing all my programs, and many updates.  So, it's currently downloading/installing about 40 updates, and I have to reinstall all my programs from scratch again.

 

Here is the cfg which worked...

 

name = 'windows8'
builder = 'hvm'
vcpus = '4'
memory = '2048'
#maxmem = '6144'
localtime = 1

disk = [ 'phy:/mnt/cache/VM/Windows8/windows8.img,hda,w','file:/mnt/user/backup/Programs/Windows_Slipstream_files/en_windows_8_1_x64_dvd_2707217.iso,hdc:cdrom,r' ]
boot = 'dc'
xen_platform_pci='1'
on_poweroff = 'destroy'
on_reboot = 'restart'
on_crash = 'restart'
vif = [ 'mac=00:16:3E:C8:C8:C8,bridge=br0,model=e1000' ]
acpi = '1'
apic = '1'
sdl = '0'
stdvga = '0'
viridian = '1'
vnc = '1'
vnclisten = '0.0.0.0'
vncpasswd = ''
vncdisplay = 1

usb = '1'
usbdevice = ['tablet','host:0a12:0001','host:045e:0745','host:174c:5106','host:045e:00db','host:147a:e03e']
pci = [ '00:14.0','01:00.0','01:00.1','09:00.0','00:1b.0' ]

 

However, since I have to basically start over, I'm really considering just starting completely from scratch, and building a qcow2 image from scratch, so that it can grow as necessary.  I converted my windows image to qcow yesterday, but that image is 38GB already, so it didn't seem to 'remove' the unused space, and if I have to basically start over, I may just start completely fresh and see if I can get the 'grow as necessary' benefit as well.

 

However, before I do anything else, I wanted to ask if anyone (jonp) has installed a windows7 VM, and had success with GPU passthru.  I was unsuccessful with doing so on the last beta, but now that we have KVM, XEN 4.4, btrfs, qcow2, etc, maybe I would have more luck getting passthru on Windows7 now.

 

Anyone?

Link to comment

I converted a CentOS IMG to qcow and used the example XML you provided and modified only to apply to my local paths and CPU.

 

I get the following error on launch:

root@NAS:/mnt/vm/CentOS# virsh create centos.xml
error: Failed to create domain from centos.xml
error: internal error: unexpected domain type kvm, expecting xen

 

 

 

You're booted into Xen mode. Boot into 'standard' unRAID as KVM is built into the Linux kernel but can't work alongside Xen concurrently.

Link to comment

Having my own issue. Not used KVM before so need a pointer please someone.

 

root@unRAID:/mnt/cache/VM/archVM# virsh create arch.xml 
error: Failed to create domain from arch.xml
error: internal error: process exited while connecting to monitor: qemu-system-x86_64: -drive file=/mnt/cache/archlinux-2014.06.01-dual.iso,if=none,id=drive-ide0-0-0,readonly=on,format=raw: Duplicate ID 'drive-ide0-0-0' for drive

 

Here is my .xml. I'm trying to install Arch.

 

	<domain type='kvm'>
  <name>ArchVM</name>
  <uuid>554cbf6b-aa75-4044-b1b3-c1005bea6062</uuid>

  <memory unit='GB'>8</memory>
  <currentMemory unit='GB'>8</currentMemory>

  <vcpu>2</vcpu>

  <os>
    <type arch='x86_64' machine='q35'>hvm</type>
    <loader>/usr/share/qemu/bios-256k.bin</loader>
    <boot dev='cdrom'/>
  </os>

  <features>
    <acpi/>
  </features>

  <on_poweroff>destroy</on_poweroff>
  <on_reboot>restart</on_reboot>
  <on_crash>destroy</on_crash>

  <devices>
<!-- VIRTUAL DISK (IMG)-->
    <disk type='file' device='disk'>
     <source file='/mnt/cache/VM/archVM/ArchVM.qcow2'/>
     <target dev='hda'/>
    </disk>

<!-- VIRTUAL CD-ROM (ISO) -->
    <disk type='file' device='cdrom'>
     <source file='/mnt/cache/archlinux-2014.06.01-dual.iso'/>
     <target dev='hda' bus='ide'/>
     <readonly/>
    </disk>


    <graphics type='vnc' port='5900'>
      <listen type='address' address='0.0.0.0'/>
    </graphics>

    <interface type='bridge'>
        <source bridge='br0'/>
    </interface>

    <emulator>/usr/bin/qemu-system-x86_64</emulator>

    <input type='mouse' bus='ps2'/>

  </devices>

</domain>

Link to comment

Having my own issue. Not used KVM before so need a pointer please someone.

 

root@unRAID:/mnt/cache/VM/archVM# virsh create arch.xml 
error: Failed to create domain from arch.xml
error: internal error: process exited while connecting to monitor: qemu-system-x86_64: -drive file=/mnt/cache/archlinux-2014.06.01-dual.iso,if=none,id=drive-ide0-0-0,readonly=on,format=raw: Duplicate ID 'drive-ide0-0-0' for drive

 

Here is my .xml. I'm trying to install Arch.

 

	<domain type='kvm'>
  <name>ArchVM</name>
  <uuid>554cbf6b-aa75-4044-b1b3-c1005bea6062</uuid>

  <memory unit='GB'>8</memory>
  <currentMemory unit='GB'>8</currentMemory>

  <vcpu>2</vcpu>

  <os>
    <type arch='x86_64' machine='q35'>hvm</type>
    <loader>/usr/share/qemu/bios-256k.bin</loader>
    <boot dev='cdrom'/>
  </os>

  <features>
    <acpi/>
  </features>

  <on_poweroff>destroy</on_poweroff>
  <on_reboot>restart</on_reboot>
  <on_crash>destroy</on_crash>

  <devices>
<!-- VIRTUAL DISK (IMG)-->
    <disk type='file' device='disk'>
     <source file='/mnt/cache/VM/archVM/ArchVM.qcow2'/>
     <target dev='hda'/>
    </disk>

<!-- VIRTUAL CD-ROM (ISO) -->
    <disk type='file' device='cdrom'>
     <source file='/mnt/cache/archlinux-2014.06.01-dual.iso'/>
     <target dev='hda' bus='ide'/>
     <readonly/>
    </disk>


    <graphics type='vnc' port='5900'>
      <listen type='address' address='0.0.0.0'/>
    </graphics>

    <interface type='bridge'>
        <source bridge='br0'/>
    </interface>

    <emulator>/usr/bin/qemu-system-x86_64</emulator>

    <input type='mouse' bus='ps2'/>

  </devices>

</domain>

 

Badger,

 

I will help you with this today.  Going to test with your V4 image.  Should be able to get that running under KVM without much difficulty.

 

I'll post an XML when done...

Link to comment

To be clear, to use KVM, we need to boot into the basic unRAID (without XEN), correct?

 

if so, this is a bit limiting, as we can't have our current XEN stuff running while working on KVM stuff; right?

yes. you can't have two hypervisors running alongside one another.

 

Sent from my Nexus 5 using Tapatalk

 

 

Link to comment

To be clear, to use KVM, we need to boot into the basic unRAID (without XEN), correct?

 

if so, this is a bit limiting, as we can't have our current XEN stuff running while working on KVM stuff; right?

 

Badger is right, it's one or the other.  This isn't an unRAID limitation, this is how virtualization works.  Good news is that Docker loads alongside either one!!

Link to comment

Ok, first and foremost, I have an archVM (based on Badger's v4) that I have had successfully running with Plex specifically now on two different hosts (an unRAID AVS 10/4 Server and a custom-built tower with consumer-grade desktop/PC components).

 

I'm looking for the networking issues you guys have reported, but I don't experience any.  As of now, these VMs are running under Xen mode using the webGUI to start/stop them (not using virsh/libvirt or domain XML yet).  My Xen CFG file is as simple as this:

 

name = "archVM"
bootloader = "pygrub"
memory = 2048
vcpus = 8
disk = ['file:/mnt/cache/domains/ArchVM/arch.img,xvda,w']
vif = [ 'mac=00:16:3e:12:22:23,bridge=xenbr0' ]

 

You can lower the vCPUs / change the memory as well, no problems...

Link to comment

My issues happened while running SABnzbd.  I don't have plex installed.  I'm also using the Archv5 image, although if you just pacman -Syyu in either I think they end up being the very same thing.

 

I'm not sure if it's a dependency of SAB (or SickRage or uTorrent) that might have caused my issues, but those are the only things I've added to my ArchVM since I re-created mine with Archv5 about 10 days ago.

Link to comment

Converting my CentOS & WHS2011 images from IMG to QCOW didn't seem to work.

 

I think you may have to change how you reference the image in the Xen CFG or the virsh domXML file.  I don't think you just convert from RAW to QCOW2 without updating the cfg file.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.