Bridged Networking - Virtual Environments
by Jorge Fábregas
Hello everyone,
I'm learning about bridged networking and how it is applied to virtual
environments (bypassing all the automation provided by libvirtd etc) .
I have a question regarding ip configuration for the virtual bridge.
Let's say I have a host (my machine) where I want to run 3 VMs bridged
to my home network (thru eth0). I have a DHCP server running on my DSL
router, and I have dhcp enabled on my 3 VMs so they all should get a
lease from the DHCP.
As far as a I know these are the raw steps needed to accomplish this:
1- create br0
2- remove current ip address from eth0
3- enslave eth0 to br0
4- create tap devices
5- attach tap devices to br0
6- assign tap devices to every VM
As you can see I haven't assigned an ip address to the virtual bridge
(br0). Why is it that (on almost any site that I visit with this setup)
they always end up assigning an ip address to br0?
Thanks in advance!
Jorge
11 years, 9 months
virsh start --console "some-guest" booting options F17 host
by Frank Murphy
Q1:
virsh start --console "some-guest"
How can a different kernel be booted from?
If kernel=0 won't complete boot.
Q2:
On one Guest, cannot enter luks pw.
It shows where to enter it,
just no asterisks.
even though all console=tty*
is in last position on grub2 cmd line.
--
Regards,
Frank
"Jack of all, fubars"
11 years, 9 months
guestfish change since f16?
by Tom Horsley
I have this silly script I use to make a copy of a Windows XP
virtual machine, changing the machine name and default
wallpaper.
I've just tried to use it for the first time in fedora 17
and the part that updates the cached wallpaper image with
the .bmp file XP wants seems to not work.
I don't see any errors when I run it, but the background
comes up solid blue. If I right click and look at desktop
properties, it does claim to have the correct default
background set, and if I re-set it, it does display
correctly.
Here's the relevant bit of code in my script:
# But wait! There's more, we not only need to fix the registry, but also
# update the cached bitmap image of the jpg file.
guestfish --ro -i -a $name.img download 'WIN:C:\WINDOWS\Web\Wallpaper\'"$wallpaper"'.jpg' $tmpdir/wall.jpg
bmp="$tmpdir/Wallpaper1.bmp"
convert $tmpdir/wall.jpg $bmp
guestfish -i -a $name.img upload $bmp 'WIN:C:\Documents and Settings\'"$user"'\Local Settings\Application Data\Microsoft\Wallpaper1.bmp'
Does this look like it ought to work? (Or maybe ImageMagick is
busted and isn't making a .bmp that XP likes?).
11 years, 10 months
virt-install: not a bootable disk on VM creation
by Marco Guazzone
Hello,
I recently get the following error message from virt-install which
unable me to create new VMs:
Boot from Hard Disk failed: not a bootable disk
The command that I use to create a new VM is:
sudo virt-install -v -l
http://mirror3.mirror.garr.it/mirrors/CentOS/6.2/os/x86_64 --ram 1024
--disk path=./images/olio_ruby-c62_64-xen.img,size=10 --name
olio_ruby-c62_64 --graphics
vnc,password=foobar,port=5901,listen=0.0.0.0 --debug
I've also tried with another distro:
sudo virt-install -v -l
http://download.fedoraproject.org/pub/fedora/linux/releases/17/Fedora/x86...
--ram 1024 --disk path=./images/olio_ruby-f17_64-xen.img,size=10
--name olio_ruby-f17_64 --graphics
vnc,password=foobar,port=5904,listen=0.0.0.0 --debug
but the problem persists.
This is strange since until recently I was able to successfully create
a new VM with the above commands.
Before reporting a bug I would like to know some opinion since I am
not an expert in this field.
Some possibly useful info:
Host system:
Fedora 16 x86_64 with kernel 3.4.2-1.fc16.x86_64 and fully
up-to-date (according to yum)
Hypervisor:
Xen
release : 3.4.2-1.fc16.x86_64
version : #1 SMP Thu Jun 14 20:17:26 UTC 2012
machine : x86_64
nr_cpus : 4
nr_nodes : 1
cores_per_socket : 4
threads_per_core : 1
cpu_mhz : 2400
hw_caps :
bfebfbff:20100800:00000000:00000940:0000e3bd:00000000:00000001:00000000
virt_caps : hvm
total_memory : 4094
free_memory : 1046
free_cpus : 0
xen_major : 4
xen_minor : 1
xen_extra : .2
xen_caps : xen-3.0-x86_64 xen-3.0-x86_32p
hvm-3.0-x86_32 hvm-3.0-x86_32p hvm-3.0-x86_64
xen_scheduler : credit
xen_pagesize : 4096
platform_params : virt_start=0xffff800000000000
xen_changeset : unavailable
xen_commandline : placeholder
cc_compiler : gcc version 4.6.3 20120306 (Red Hat 4.6.3-2) (GCC)
cc_compile_by : mockbuild
cc_compile_domain : phx2.fedoraproject.org
cc_compile_date : Mon May 7 23:28:57 UTC 2012
xend_config_format : 4
For your interest, here are some snippets of various logs (I've added
only the most interesting parts):
- /var/log/libvirt/libvirtd.log:
2012-06-24 08:28:04.399+0000: 1195: error : virNetSocketReadWire:912 :
End of file while reading data: Input/output error
- /var/log/xen/xend.log
[2012-06-20 14:55:29 1106] DEBUG (XendDomainInfo:260)
XendDomainInfo.createDormant({'vcpus_params': {'cap': 0, 'weight':
256}, 'PV_args': '', 'features': '', 'cpus': [[]], 'use_tmp_kernel':
False, 'devices': {'adb0a566-cb2a-cd60-0e77-262f089d4d06': ('vbd',
{'uuid': 'adb0a566-cb2a-cd60-0e77-262f089d4d06', 'bootable': 0,
'driver': 'paravirtualised', 'dev': 'hdc:cdrom', 'mode': 'r', 'VDI':
'', 'backend': '0'}), '5c063c17-4b63-7ffb-9ed9-7033864998ee': ('vfb',
{'vncunused': '0', 'other_config': {'vncunused': '0', 'vnc': '1',
'vnclisten': '0.0.0.0', 'vncdisplay': '4', 'vncpasswd': 'XXXXXXXX',
'keymap': 'en-us'}, 'vnc': '1', 'uuid':
'5c063c17-4b63-7ffb-9ed9-7033864998ee', 'vnclisten': '0.0.0.0',
'vncdisplay': '4', 'vncpasswd': 'XXXXXXXX', 'keymap': 'en-us',
'location': '0.0.0.0:5904'}), '91500fef-ba69-2d52-3909-c44de37aa543':
('vif', {'bridge': 'virbr0', 'mac': '00:16:3e:e3:fa:32', 'script':
'/etc/xen/scripts/vif-bridge', 'uuid':
'91500fef-ba69-2d52-3909-c44de37aa543', 'backend': '0'}),
'ea7ee8d5-2611-22fd-939a-06ac7b2d3ab4': ('console', {'protocol':
'vt100', 'location': '3', 'uuid':
'ea7ee8d5-2611-22fd-939a-06ac7b2d3ab4'}),
'1c22e2d8-34b8-f54f-8917-3577a3b52cb1': ('vkbd', {'uuid':
'1c22e2d8-34b8-f54f-8917-3577a3b52cb1', 'backend': '0'}),
'5cedc9f6-9a0d-4113-a8c9-05fe7a30d65e': ('vbd', {'uuid':
'5cedc9f6-9a0d-4113-a8c9-05fe7a30d65e', 'bootable': 1, 'driver':
'paravirtualised', 'dev': 'hda:disk', 'uname':
'file:/home/testbed/images/winXP.img', 'mode': 'w', 'VDI': '',
'backend': '0'})}, 'memory_sharing': 0, 'superpages': '0',
'VCPUs_live': 1, 'PV_bootloader': '', 'actions_after_crash':
'restart', 'vbd_refs': ['5cedc9f6-9a0d-4113-a8c9-05fe7a30d65e',
'adb0a566-cb2a-cd60-0e77-262f089d4d06'], 'PV_ramdisk': '',
'is_control_domain': False, 'name_label': 'winXP', 'VCPUs_at_startup':
1, 'HVM_boot_params': {'order': 'c'}, 'platform': {'tsc_mode': '0',
'timer_mode': '1', 'usb': '1', 'hpet': '0', 'device_model':
'/usr/lib64/xen/bin/qemu-dm', 'vpt_align': '1', 'nomigrate': '0',
'boot': 'c', 'rtc_timeoffset': '1', 'loader':
'/usr/lib/xen/boot/hvmloader', 'xen_platform_pci': '1', 'acpi': '1',
'pci': [], 'pae': '1', 'apic': '1', 'serial': 'pty', 'viridian': '0',
'parallel': 'none'}, 'PV_kernel': '', 'console_refs':
['ea7ee8d5-2611-22fd-939a-06ac7b2d3ab4',
'5c063c17-4b63-7ffb-9ed9-7033864998ee'], 'vif_refs':
['91500fef-ba69-2d52-3909-c44de37aa543'], 'on_xend_stop': 'ignore',
'pool_name': 'Pool-0', 'memory_static_min': 0, 'HVM_boot_policy':
'BIOS order', 'description': '', 'VCPUs_max': 1, 'start_time':
1338369536.8, 'memory_static_max': 1073741824,
'actions_after_shutdown': 'destroy', 'use_tmp_ramdisk': False,
'on_xend_start': 'ignore', 'memory_dynamic_max': 1073741824,
'actions_after_suspend': '', 'is_a_template': False,
'PV_bootloader_args': '', 'memory_dynamic_min': 1073741824, 'uuid':
'73abb58e-a567-b761-9aa6-4f4c388125c1', 'cpu_time': 38.523277069,
'shadow_memory': 9, 'target': 0, 'vcpu_avail': 1L, 'notes':
{'SUSPEND_CANCEL': '1'}, 'other_config': {}, 'auto_power_on': False,
'actions_after_reboot': 'restart', 'Description': '', 'status': '1',
'vtpm_refs': []})
- /var/log/xen/qemu-dm-olio_ruby-c62_64.log
domid: 2
config qemu network with xen bridge for tap2.0 virbr0
Using file /home/testbed/images/olio_ruby-c62_64-xen.img in read-write mode
Watching /local/domain/0/device-model/2/logdirty/cmd
Watching /local/domain/0/device-model/2/command
Watching /local/domain/2/cpu
char device redirected to /dev/pts/2
qemu_map_cache_init nr_buckets = 10000 size 4194304
shared page at pfn feffd
buffered io page at pfn feffb
Guest uuid = 59448e26-2dda-8114-86f1-9c8e57723f87
Time offset set 0
populating video RAM at ff000000
mapping video RAM from ff000000
Register xen platform.
Done register platform.
platform_fixed_ioport: changed ro/rw state of ROM memory area. now is rw state.
xs_read(/local/domain/0/device-model/2/xen_extended_power_mgmt): read error
Log-dirty: no command yet.
I/O request not ready: 0, ptr: 0, port: 0, data: 0, count: 0, size: 0
vcpu-set: watch node error.
char device redirected to /dev/pts/3
xen be: console-0: xen be: console-0: initialise() failed
initialise() failed
xs_read(/local/domain/2/log-throttling): read error
qemu: ignoring not-understood drive `/local/domain/2/log-throttling'
medium change watch on `/local/domain/2/log-throttling' - unknown
device, ignored
xen be: console-0: xen be: console-0: initialise() failed
initialise() failed
xen be: console-0: xen be: console-0: initialise() failed
initialise() failed
xen be: console-0: xen be: console-0: initialise() failed
initialise() failed
xen be: console-0: xen be: console-0: initialise() failed
initialise() failed
xen be: console-0: xen be: console-0: initialise() failed
initialise() failed
xen be: console-0: xen be: console-0: initialise() failed
initialise() failed
xen be: console-0: xen be: console-0: initialise() failed
initialise() failed
xen be: console-0: xen be: console-0: initialise() failed
initialise() failed
xen be: console-0: xen be: console-0: initialise() failed
initialise() failed
xen be: console-0: xen be: console-0: initialise() failed
initialise() failed
xen be: console-0: xen be: console-0: initialise() failed
initialise() failed
cirrus vga map change while on lfb mode
mapping vram to f0000000 - f0400000
platform_fixed_ioport: changed ro/rw state of ROM memory area. now is rw state.
platform_fixed_ioport: changed ro/rw state of ROM memory area. now is ro state.
Any idea?
Thank you very much for helping me.
-- Marco
11 years, 10 months
Sound not working on vm clients
by David Highley
We have two vm clients and neither have sound.
hosting platform is Fedora 16 x86_64
first client is Fedora 17 i686
second client is Ubuntu 12.04 i686
libvirt-0.9.6-5.fc16.x86_64
qemu-kvm-0.15.1-5.fc16.x86_64
Tried both VNC and Spice modes. Did set, vnc_allow_host_audio = 1, in
/etc/libvirt/qemu.conf file. Just in case we put selinux in Permissive
mode. Still no sound.
Another question is, when and if graphics 3D acceleration will work? We
tried the HoN game, disabled graphics detection, it segfaulted.
11 years, 10 months
Support for modems and other such physical hardware?
by Greg Scott
Hi have a situation with a Windows 2003 server that uses a fax modem.
I'd love to P2V this server but I need support for a Brooktrout
faxmodem. The idea is, just pass anything to/from this hardware
directly to the Windows guest VM, so the guest VM "thinks" it's
connected to the faxmodem. I haven't run across anything that says I
can do that with KVM virtual machines. Any ideas?
Thanks
- Greg Scott
11 years, 10 months
How to use virtio-scsi on F17 host and F17 guest
by Gianluca Cecchi
Hello,
reading here:
https://fedoraproject.org/wiki/Features/virtio-scsi
it should be possible to use virtio-scsi, even if not completely
integrated in libvirt.
And installation would require this part for the hard disk:
-drive if=none,id=hd,file=/path/to/test.img -device
virtio-scsi-pci,id=scsi -device scsi-hd,drive=hd
I have now an F17 host (kernel 3.3.7) and F17 guest (3.4.0) configured
with a virtio_blk disk
guest definition for the disk is this:
<disk type='file' device='disk'>
<driver name='qemu' type='qcow2'/>
<source file='/var/lib/libvirt/images/f17.img'/>
<target dev='vda' bus='virtio'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x06'
function='0x0'/>
</disk>
Can I change it with "virsh edit" so that I can use virtio-scsi inside
guest and test?
What would be the xml snippet for it? Or do I have to use also a
wrapper to start qemu-kvm with particular options as during install?
Thanks in advance,
Gianluca
11 years, 10 months
Multi-head SPICE support in virt-manager?
by Ian Pilcher
Just wondering if there are any plans to add $SUBJECT.
--
========================================================================
Ian Pilcher arequipeno(a)gmail.com
"If you're going to shift my paradigm ... at least buy me dinner first."
========================================================================
11 years, 10 months
Off Topic - CPU upgrade
by drew einhorn
I have a box with a LGA775 cpu socket.
Anybody know where I can find a list of LGA775 cpus that support VT-X
hardware virtualization, that is has the vmx flag?
--
Drew Einhorn
"You can see a lot by just looking."
-- Yogi Berra
11 years, 10 months
Fedora virt status May 2012
by Cole Robinson
Hey all,
I'm going to try and revive the monthly virt status report, detailing
core virt happenings in Fedora, as well as upstream bits that are
particularly interesting for Fedora.
Any comments or suggestions welcome!
Fedora virt status for April + May 2012:
Fedora 17
=========
After a week slip, Fedora 17 was released Tuesday May 29! There
were 4 core virt features advertised:
https://fedoraproject.org/wiki/Features/virtio-scsi
https://fedoraproject.org/wiki/Features/KVM_Guest_PMU
https://fedoraproject.org/wiki/Features/Open_vSwitch
https://fedoraproject.org/wiki/Features/VirtSandbox
Other interesting virt developments include the availability of
Gnome Boxes, which integrates virt management into the core Gnome Shell
experience. Some info here:
https://live.gnome.org/Boxes
http://fedoraproject.org/wiki/Test_Day:2012-05-17_Gnome_Boxes
OpenStack Essex, the latest release of the popular cloud computing
stack, was also a Fedora 17 feature:
http://fedoraproject.org/wiki/Features/OpenStack_Essex
And finally, oVirt, an advanced server virtualization management system
based on libvirt and KVM, is fully packaged for Fedora 17:
http://fedoraproject.org/wiki/Features/oVirt
All in all a pretty exciting release!
Fedora 18
=========
Since F17 is wrapped, we've started down the Fedora 18 cycle. Some
interesting dates:
2012-07-24 Feature Submission Deadline
2012-08-07 Feature Freeze--Planning & Development Ends
2012-08-07 Branch Fedora 18 from Rawhide-- Branch Freeze
2012-08-14 Alpha Change Deadline
So the first real freeze is still two months off, plenty of time! :)
On the features front, nothing has been proposed yet, but expect
announcements in the near future.
If anyone out there has an interesting virt feature they are working
on and that they plan on getting into Fedora 18, drop this list a line
and we can help it get nominated as a part of the Fedora feature process.
Libvirt stable releases
=======================
There are now official libvirt maintenance releases:
http://wiki.libvirt.org/page/Maintenance_Releases
Right not they are just for the libvirt 0.9.11 version in Fedora 17,
but 0.9.6 releases for Fedora 16 are coming soon, as started by Eric Blake:
http://www.redhat.com/archives/libvir-list/2012-May/msg00932.html
libvirt-0.9.11.3 is now in Fedora 17:
https://admin.fedoraproject.org/updates/FEDORA-2012-6964/libvirt-0.9.11.3...
This should mean better quality updates, and quicker turnaround on bugfixes
making their way to fedora.
Bugs of note
============
* https://bugzilla.redhat.com/show_bug.cgi?id=714271
libvirt pinned to single CPU after suspend/resume cycle ->
all VMs running on the same single core
Basically doing suspend/resume of a machine with a running VM using
with vcpus > 1 causes a performance regression as all guest vcpus
end up running on only 1 host CPU. It sounds like a fix is finally
close to hitting upstream kernel git. Currently this affects all
supported versions of Fedora :(
For people needing an immediate fix, there are workarounds noted here:
https://bugzilla.redhat.com/show_bug.cgi?id=813228
* https://bugzilla.redhat.com/show_bug.cgi?id=796479
firewalld conflicts with libvirt's default network. Basically
if firewalld is started after libvirtd has started, it blows
away the firewall rules libvirt's default network requires to
function.
firewalld is a new stateful daemon, providing a nice dbus API for
applications to interact with iptables related bits.
This was a problem around F17 beta time, since firewalld was on
by default. However that bit was eventually reverted. You will
still see issues if you manually install firewalld though.
Medium term, libvirt will talk directly to firewalld for it's
iptables management, and everything will play nice together.
Expect that, as well as firewalld by default, in the Fedora 18
timeframe.
Admin bits
==========
There have been some recent administrative changes.
virt-maint(a)lists.fedoraproject.org now receives many more
build notifications, as well as bugzilla mail. virt-maint is now a
good list to subscribe to if you are intersted in spam about daily
virt changes in Fedora land:
https://admin.fedoraproject.org/mailman/listinfo/virt-maint/
http://lists.fedoraproject.org/pipermail/virt-maint/2012-May/003712.html
http://lists.fedoraproject.org/pipermail/virt-maint/2012-May/003954.html
Also, we now have a nice stable place to host virt related bits on
fedorapeople:
http://fedorapeople.org/groups/virt/
The virtualization preview repository, which builds rawhide packages
for latest stable fedora, is now available for Fedora 17, and at the
above location. More info here:
https://fedoraproject.org/wiki/Virtualization_Preview_Repository
http://lists.fedoraproject.org/pipermail/virt/2012-June/003287.html
Thanks,
Cole
11 years, 10 months