[libvirt-users] virRandomBits - not very random
by Brian Rak
I just ran into an issue where I had about 30 guests get duplicate mac
addresses assigned. These were scattered across 30 different machines.
Some debugging revealed that:
1) All the host machines were restarted within a couple seconds of each
other
2) All the host machines had fairly similar libvirtd pids (within ~100
PIDs of each other)
3) Libvirt seeds the RNG using 'time(NULL) ^ getpid()'
This perfectly explains why I saw so many duplicate mac addresses.
Why is the RNG seed such a predictable value? Surely there has to be a
better source of a random seed then the timestamp and the pid?
The PID seems to me to be a very bad source of any randomness. I just
ran a test across 60 of our hosts. 43 of them shared their PID with at
least one other machine.
6 years, 3 months
[libvirt-users] Freeze Windows Guests For Consistent Storage Snapshots
by Payes Anand
Hi,
Is it possible to freeze windows guests for a consistent storage level
snapshot.
I am using openstack icehouse on centos 6.6
Hypervisor: KVM
Libvirt: 0.10.2
Qemu: 0.10.2
Guest OS: Windows 7 and Windows Server 2008
I was able to freeze Centos guests by issuing the command:
virsh qemu-agent-command <guest_ID> '{"execute":"guest-fsfreeze-freeze"}'
For CentOS guests, I enabled access between compute nodes and guests
through a socket by setting metadata parameter, hw_qemu_guest_agent=yes for
the guest image.
And then installing qemu-guest-agent inside the guest.
What steps do i have to follow for windows ?
Regars,
Payes
9 years, 3 months
[libvirt-users] Using virsh blockcopy -- what's it supposed to accomplish?
by Gary R Hook
I am experimenting with the blockcopy command, and after figuring out
how to integrate qemu-nbd, nbd-client and
dumpxml/undefine/blockcopy/define/et. al. I have one remaining question:
What's the point?
The "replication" disk file is not, from what I can ascertain, bootable.
I expect this operation to create a pristine copy of my source qcow2
file (at a given point in time) which implies that I can swap that copy
in and use it just like the original.
Neither using --finish nor --pivot (both appear successful) give me a
mirror that seems to serve any purpose. It seems especially pointless if
I use --pivot because anything that happens after the pivot ends up lost
if I don't actually have a usable qcow2 file.
I find lots of discussion online about getting the steps to work, but as
yet find nothing about using the resulting file.
What am I missing here?
libvirt (1.2.2) and qemu (2.2.0) as distributed with Ubuntu Trusty.
--
Gary R Hook
Senior Kernel Engineer
NIMBOXX, Inc
9 years, 8 months
[libvirt-users] Please help me!Thank You!
by 75124955
I am using Libvirt virsh command by vmware esx created a virtual host, has been unable to create success.
My creation process is as follows :
Create a virtual host XML file content is as follows:
<domain type='vmware'>
<name>test1</name>
<memory>524288</memory>
<currentMemory>524288</currentMemory>
<vcpu>1</vcpu>
<os>
<type arch='x86_64'>hvm</type>
</os>
<devices>
<disk type='file' device='disk'>
<source file='[datastore1 (2)] test1/test1.vmdk'/>
<target dev='sda' bus='scsi'/>
<address type='drive' controller='0' bus='0' unit='0'/>
</disk>
<controller type='scsi' index='0' model='vmpvscsi'/>
<controller type='ide' index='0'/>
<interface type='bridge'>
<source bridge='VM Network'/>
</interface>
</devices>
</domain>
Has been unable to create the VMDK files, can you tell me what reason be? Thank you very much !
I will always wait for your reply, this problem is very important to me.
9 years, 8 months
[libvirt-users] Console access for a user.
by Le Bris Gilles
Hi,
I would like to allow a user (non-root) to access the console of his VM
(he's got root access on it).
Using sudo doesn't seem to work:
/bin/virsh console vm
error: failed to get domain 'vm'
error: Domain not found: no domain with matching name 'vm'
If I assign suid to virsh, I get: 'error: Failed to initialize libvirt'
I don't see any information on Internet about this.
What is the procedure to follow to get this result (QEMU conf, libvirt
conf, etc)?
Thank you in advance.
9 years, 8 months
[libvirt-users] Bhyve drv creates duplicate tap0 references
by William B
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Good morning,
I am not sure if this is a known issue or if I should raise as a bug.
When using libvirt 1.2.11 on FreeBSD 10.1-RELEASE with bhyve, I have notice that a machine which defines:
<interface type='bridge'>
<mac address='52:54:00:88:44:08'/>
<source bridge='bridge10'/>
<model type='virtio'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
</interface>
<interface type='bridge'>
<mac address='52:54:00:42:8f:c1'/>
<source bridge='bridge11'/>
<model type='virtio'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x0'/>
</interface>
Generates a bhyve command from domxml-to-native that contains the interfaces such that:
- -s 2:0,virtio-net,tap0,mac=52:54:00:88:44:08 -s 3:0,virtio-net,tap0,mac=52:54:00:42:8f:c1
As a result, in this configuration, no network traffic works due to the duplication of the tap0 device in each command.
When running two machines simultaneously, both are allocated to tap0, again causing issues.
Is this a known issue?
Please include me in replies as I am offlist.
- --
Sincerely,
William Brown
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
iQIcBAEBAgAGBQJUoeiHAAoJEO/EFteBqAmaA2EP/ixYU792vc4K41jnI2Z+cC11
PVMEI4YFiaBwU4xBE7FpOrgnz/oVOKE5r4/PYM+M+c460yJMeEHbUQ3haH0meciN
TuiOBB2uOx2mvaPBbOKL2Kd8u3poR7nBwwisDD6M81HhCGNan1uFoTzCXswZGlEn
C0EgXHh2wTUVl3HWYbKXW6WmuhYTn8IHuPFjWNKGwJdHOzVYOPfmIiMU/qLlNNG1
FEjf+FS9yjuzBFSa6QszQG10DSPNJ6KghDxCVj2hUl0FHHcYbukbHa4FGwc261i0
h6MII67/27ZIaYA+7yqL2A9pa4Pj1FQ/IWWzuemG4TAbETLIEps4PrFvXLHgX0l/
KYE/5vysYrWjNXs6RXQwEcRBPxOHxhrAdl2t6FkYDSGf27WIwEepSPlo3r/bCenZ
5z6RkIq3HRdZy4bnZPcy1hUOOKKDrq2PXRJ3DIWDktfmpHf+IyCBb7jEKUQU8cL8
4ODeHFrQ8RcvEmXvLHk8Gt1y5/cOhs2VI9JDf0IZLfPi3+OETDY54pI7PPkv8mya
LmDS9YdmDfAdks/wTX1a4F80g0m4qR5X9HvgUu0bGSq3k5mefRFzi3PLf45tiKXo
9kEYrq9wmd2b4YIdPzdANE/NAz9sLM/phJNqSoVbHhxgOtAMNr2XPs0l9J/e2cUa
OuFCyESOu2iKL3C5fCU1
=tL0W
-----END PGP SIGNATURE-----
9 years, 8 months
Re: [libvirt-users] Using virsh blockcopy -- what's it supposed to accomplish?
by Gary R Hook
On 12/23/14 2:08 PM, Eric Blake wrote:
> On 12/23/2014 11:35 AM, Gary R Hook wrote:
>> On 12/22/14 4:50 PM, Eric Blake wrote:
>>> On 12/22/2014 03:27 PM, Gary R Hook wrote:
>>>> I am experimenting with the blockcopy command, and after figuring out
>>>> how to integrate qemu-nbd, nbd-client and
>>>> dumpxml/undefine/blockcopy/define/et. al. I have one remaining question:
>>>>
>>>> What's the point?
>>>
>>> Among other uses, live storage migration.
>>
>> There is so very much to say here, but I will endeavor to be brief and
>> to the point. Please note that I am working with libvirt 1.2.2, as
>> stated in my OP. And up front; I'm pretty sure I'm missing data points
>> and working from a position of ignorance and unreasonable expectation.
>
> Did you mean for this to go to the list? Usually, having discussions
> like this in public archives will benefit more people, and allow others
> to chime in.
>
> https://rwmj.wordpress.com/2010/11/08/want-help-dont-email-me-directly/
Dang, dang, dang, dang, dang. Yes, of course I did. *sigh*. Will
resend to the list. Please ignore.
--
Gary R Hook
Senior Kernel Engineer
NIMBOXX, Inc
9 years, 8 months
[libvirt-users] "virsh list" does not show anything after reboot [newbie]
by Kevin Wilson
Hi, libvirt users and gurus,
I am a newbie to visualization, hope this question is not too silly,
please bear with me.
I had installed three guest on Fedora 21 with the virt-install tool, by:
virt-install --name=f21_x86_64_guest
--file=/var/lib/libvirt/images/guest.qcow2 --cdrom
/workStorage/work/down/f21/Fedora-Live-Workstation-x86_64-21-5.iso
--ram=2048
virt-install --name=f21_x86_64_guest1
--file=/var/lib/libvirt/images/guest.qcow2 --cdrom
/workStorage/work/down/f21/Fedora-Live-Workstation-x86_64-21-5.iso
--ram=2048 --force
virt-install --name=f21_x86_64_guest2
--file=/var/lib/libvirt/images/guest.qcow2 --cdrom
/workStorage/work/down/f21/Fedora-Live-Workstation-x86_64-21-5.iso
--ram=2048 --force
When runing "virsh list" I see these three guests as running.
Now, I rebooted the machine, and "virsh list" does not show anything.
It turned out that
running "systemctl status libvirtd" showed some error (about some NFS
path which was not found),
and once I fixed that, I restarted the libvirtd, and this time running
"systemctl status libvirtd"
showed that it is running OK. Yet, runnig "virsh list" does not show anything
Any ideas ? what I should do to run one of these guest I created
before booting the machine ?
Regards,
Kevin
9 years, 8 months
[libvirt-users] why CPU pinning doesn't take effect when using lxc-enter-namespace to run an application
by WANG Cheng D
Dear all,
I want my container to run on the third CPU core and I define this by the following xml scrpits:
<vcpu placement="static" cpuset="3">1</vcpu>
When I run my application in a container terminal, I can see the application runs on the third core as expected.
When I run my application using lxc-enter-namespace, the CPU pinning doesn't take effect, i.e., the application runs on a core which isn't the third one.
How can I solve this problem?
Any replies are highly appreciated.
Cheng
9 years, 8 months
[libvirt-users] Device attach event
by Marek Marczykowski-Górecki
Hi all,
I'm trying to use libvirt events API, but I can't find what event is
fired when some device (disk in this case) got attached to the domain.
In the docs I see only VIR_DOMAIN_EVENT_ID_DEVICE_REMOVED, but not
VIR_DOMAIN_EVENT_ID_DEVICE_ATTACHED. Is there some event for that?
BTW libxl driver implements only VIR_DOMAIN_EVENT_ID_LIFECYCLE, but that's
another story...
--
Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
9 years, 8 months