<div dir="ltr">Hi All., <div>         I am not sure if this is possible in xen via Libvirt, but what I am trying to do is, I want libvirt to launch a VM and attach a pre-created tap interface to that VM ( I do not want XEN to create one, as I am running a lot of custom scripts on my tap interface). I also dont want xen to attach this tap interface to a bridge.</div>
<div><br></div><div>For example, lets say I have created a tap interface with name "tap123456" when libvirt launches my VM in xen, I want the VM to read its networking info from this tap interface. </div><div><br>
</div><div>But I wasn't so successful in doing this when ever I am trying to do this, I am seeing the following error message "VmError: Device 0 (vif) could not be connected. Hotplug scripts not working." and "error: POST operation failed: xend_post: error from xen daemon: (xend.err 'Device 0 (vif) could not be connected. Cannot rename interface vif4.0. An interface with name tap12345 already exists.')". But I dont want xen to create  another interface and rename it, rather want xen to use the existing one</div>
<div><br></div><div>=== output of lsmod ===</div><div><br></div><div><div>bash-4.1# lsmod | grep xen</div><div>xen_acpi_processor      4465  0 </div><div>xen_netback            25455  0 [permanent]</div><div>xen_gntdev              9504  2 </div>
<div>xen_evtchn              4899  3 </div><div>xenfs                   2943  1 </div><div>xen_privcmd             4972  19 xenfs</div><div><br></div></div><div>==== end of output ====</div><div><br></div><div>My Configuration : Centos 6.2 with Xen 4.2.5 along with Libvirt</div>
<div> </div><div><br></div><div>Libvirt Configuration file, </div><div><br></div><div><div><domain type='xen'></div><div><br></div><div><name>raghu_12345</name></div><div><uuid>12113325-d948-4a1b-b673-888a16b90726</uuid></div>
<div><memory>1048576</memory></div><div><vcpu>1</vcpu></div><div><br></div><div><br></div><div><os></div><div><span class="" style="white-space:pre">     </span><type>hvm</type></div>
<div><span class="" style="white-space:pre">    </span><loader>/usr/lib/xen/boot/hvmloader</loader></div><div><span class="" style="white-space:pre">   </span><boot dev='hd'/></div><div></os></div>
<div><br></div><div><on_poweroff>destroy</on_poweroff></div><div><on_reboot>restart</on_reboot></div><div><on_crash>restart</on_crash></div><div><br></div><div><features></div><div>
<span class="" style="white-space:pre">       </span><pae/></div><div><span class="" style="white-space:pre">       </span><acpi/></div><div><span class="" style="white-space:pre">      </span><apic/></div><div></features></div>
<div><br></div><div><br></div><div><devices></div><div><span class="" style="white-space:pre">    </span><emulator>/usr/lib/xen/bin/qemu-dm</emulator></div><div><span class="" style="white-space:pre">  </span><interface type="ethernet"></div>
<div><span class="" style="white-space:pre">            </span><mac address='00:25:90:3f:25:91'/>  <!-- I want this mac to be mac address of a vm --></div><div><span class="" style="white-space:pre">         </span><target dev='tap123456'/> </div>
<div><span class="" style="white-space:pre">    </span></interface></div><div><span class="" style="white-space:pre"> </span><disk type='file' device='disk'></div><div><span class="" style="white-space:pre">             </span><source file='~/tmp/lucid.img'/></div>
<div><span class="" style="white-space:pre">            </span><target dev='hda'/></div><div><span class="" style="white-space:pre">  </span></disk></div><div><span class="" style="white-space:pre">      </span><console type='pty'></div>
<div><span class="" style="white-space:pre">            </span><target port='0'/></div><div><span class="" style="white-space:pre">   </span></console></div><div><span class="" style="white-space:pre">   </span><graphics port='-1' type='vnc' autoport='yes' listen='0.0.0.0'/></div>
<div></devices></div><div><br></div><div></domain></div><div><br></div><div><br></div><div>I have a pre-created  tap interface with name 'tap123456'  with all the networking setup with dhcp and dns running.</div>
<div><br></div><div>Thanks for your time and help.</div><div><br></div><div>Regards</div><div>Raghu</div><div><br></div><div><br></div><div><br></div></div></div>