<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hello List,<div><br></div><div>I'm attempting to pass a DVD drive of a headless server into a virtual machine.  So far I've managed to mount *something* into the VM, but it's being registered as a blank DVD within the VM. When I mount /dev/dvd into the bare-metal machine it registers normally as the DVD.  How do I pass physical drives into a VM and back out using libvirt?  </div><div><br></div><div>Command used:</div><div><div>#virsh attach-disk Montreal /dev/dvd hdc --mode readonly --driver phy --type cdrom</div><div>Connecting to uri: <a href="qemu:///system">qemu:///system</a></div><div>Disk attached successfully</div></div><div><br></div><div>VM XML file:</div><div><br></div><div><div><domain type='kvm'></div><div>  <name>Montreal</name></div><div>  <uuid>0f79ba7f-27bf-16a0-5887-6cfa2b5569f1</uuid></div><div>  <memory>2097152</memory></div><div>  <currentMemory>2097152</currentMemory></div><div>  <vcpu>1</vcpu></div><div>  <os></div><div>    <type arch='x86_64' machine='pc-0.11'>hvm</type></div><div>    <boot dev='hd'/></div><div>  </os></div><div>  <features></div><div>    <acpi/></div><div>    <apic/></div><div>    <pae/></div><div>  </features></div><div>  <clock offset='utc'/></div><div>  <on_poweroff>destroy</on_poweroff></div><div>  <on_reboot>restart</on_reboot></div><div>  <on_crash>restart</on_crash></div><div>  <devices></div><div>    <emulator>/usr/bin/kvm</emulator></div><div>    <disk type='file' device='cdrom'></div><div>      <target dev='hdc' bus='ide'/></div><div>      <readonly/></div><div>    </disk></div><div>    <disk type='file' device='disk'></div><div>      <source file='(Mangled Purposely)'/></div><div>      <target dev='vda' bus='virtio'/></div><div>    </disk></div><div>    <interface type='bridge'></div><div>      <mac address='(mangled purposly)/> </div><div>      <source bridge='br0'/></div><div>      <model type='virtio'/></div><div>    </interface></div><div>    <serial type='pty'></div><div>      <target port='0'/></div><div>    </serial></div><div>    <console type='pty'></div><div>      <target port='0'/></div><div>    </console></div><div>    <input type='mouse' bus='ps2'/></div><div>    <graphics type='vnc' port='-1' autoport='yes' keymap='en-us'/></div><div>    <video></div><div>      <model type='cirrus' vram='9216' heads='1'/></div><div>    </video></div><div>  </devices></div><div></domain></div><div><br></div></div><div>Thanks in advance,<br><div>
<div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">-----------------------------------------------------------------</div><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><b><font class="Apple-style-span" color="#8C000E">Adam Mooz</font></b><br><font class="Apple-style-span" color="#929292"><i><a href="mailto:Adam.Mooz@gmail.com">Adam.Mooz@gmail.com</a><br></i><i><a href="mailto:AdamMooz@me.com">AdamMooz@me.com</a></i></font><font class="Apple-style-span" color="#929292"><i><br></i></font><font class="Apple-style-span" color="#929292"><a href="http://www.AdamMooz.com">http://www.AdamMooz.com</a><br></font><br><br></div></span></div></span></div></div>
</div>
<br></div></body></html>