<div dir="ltr"><div>Another difference between libvirt and VirtualBox.<br><br></div>I was able to take the Ubuntu Server stock .iso file, and install it inside of VirtualBox normally. That includes installing grub in the virtual disk's MBR.<br>
<br>With libvirt, grub installation does not complete, with no errors. The step proceeds, then returns to the tasks.<br><br>So, I am unable to have a working VM with KVM and libvirt so far because of grub aborting.<br></div>
<div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, Aug 1, 2014 at 4:03 PM, Khalid Baheyeldin <span dir="ltr"><<a href="mailto:kb@2bits.com" target="_blank">kb@2bits.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr"><div>After defining br0 in the host's network, if I specify bridge=br0, it works fine, but only with sudo, which is annoying.<br><br></div><div>VirtualBox did not need any host changes, and did not require sudo.<br>
<br></div><div>Is there a way to do this on kvm/libvirt?<br></div></div><div class="gmail_extra"><div><div class="h5"><br><br><div class="gmail_quote">On Fri, Aug 1, 2014 at 3:03 PM, William Park <span dir="ltr"><<a href="mailto:opengeometry@yahoo.ca" target="_blank">opengeometry@yahoo.ca</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div>On Fri, Aug 01, 2014 at 12:27:21PM -0400, Khalid Baheyeldin wrote:<br>
> On VirtualBox, I was able as non-root to get bridged networking by doing:<br>
><br>
> vboxmanage createvm --name p1 --ostype Ubuntu_64 --register<br>
> vboxmanage modifyvm p1 ... --nic1 bridged --bridgeadapter1 eth0 --nictype1<br>
> 82543GC<br>
><br>
> And that provided me functional two-way networking, assigning a new IP<br>
> address from the router, and allows incoming and outgoing networking<br>
> transparently.<br>
><br>
> On KVM, I did:<br>
><br>
> virt-install --name p1 --ram 512 --disk path=~/p.img,size=2 --cdrom<br>
> ./media/precise64/ubuntu-12.04.4-server-amd64.iso --boot cdrom --network<br>
> bridge=eth0<br>
><br>
> That would not work because it requires root (VirtualBox worked without<br>
> sudo).<br>
><br>
> So, I need to use sudo before that command. But when I do this, I get the<br>
> error:<br>
><br>
> ERROR Unable to add bridge eth0 port vnet0: Operation not supported<br>
><br>
> Googling for that error suggests that this command should fix it:<br>
><br>
> virsh iface-bridge eth0 br0<br>
><br>
> But it does not work, with or without sudo, with the following error:<br>
><br>
> error: failed to get interface 'eth0'<br>
> error: this function is not supported by the connection driver:<br>
> virInterfaceLookupByName<br>
><br>
> So, the question is, using libvirt and kvm, how does one get bridged<br>
> networking to work?<br>
<br>
</div></div>From memory, QEMU simply adds its tap interface to existing bridge. I<br>
had to setup bridge and add wlan0 (my wireless connection) to it. Then,<br>
the virtual machine got its IP from the wireless router.<br>
<span><font color="#888888">--<br>
William<br>
<br>
<br>
_______________________________________________<br>
kwlug-disc mailing list<br>
<a href="mailto:kwlug-disc@kwlug.org" target="_blank">kwlug-disc@kwlug.org</a><br>
<a href="http://kwlug.org/mailman/listinfo/kwlug-disc_kwlug.org" target="_blank">http://kwlug.org/mailman/listinfo/kwlug-disc_kwlug.org</a><br>
</font></span></blockquote></div><br><br clear="all"><br></div></div><div class="">-- <br>Khalid M. Baheyeldin<br><a href="http://2bits.com" target="_blank">2bits.com</a>, Inc.<br>Fast Reliable Drupal<br>Drupal optimization, development, customization and consulting.<br>
Simplicity is prerequisite for reliability. -- Edsger W.Dijkstra<br>Simplicity is the ultimate sophistication. -- Leonardo da Vinci<br>For every complex problem, there is an answer that is clear, simple, and wrong." -- H.L. Mencken<br>
</div></div>
</blockquote></div><br><br clear="all"><br>-- <br>Khalid M. Baheyeldin<br><a href="http://2bits.com" target="_blank">2bits.com</a>, Inc.<br>Fast Reliable Drupal<br>Drupal optimization, development, customization and consulting.<br>
Simplicity is prerequisite for reliability. -- Edsger W.Dijkstra<br>Simplicity is the ultimate sophistication. -- Leonardo da Vinci<br>For every complex problem, there is an answer that is clear, simple, and wrong." -- H.L. Mencken<br>
</div>