[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [virt-tools-list] question about clustering

Ok, thanks Daniel, that makes FAR better sense.

Now for a stupid question:  Since the cluster suite has to manage the
vm's (as far as starting, stopping, migrating), if I were to log into
a vm, then shut it off, will the cluster suite know that it was an
intended shutdown or will I have to always power off my vm's through


On Thu, Feb 17, 2011 at 9:25 AM, Daniel P. Berrange <berrange redhat com> wrote:
> On Thu, Feb 17, 2011 at 09:10:01AM -0500, Kenneth Armstrong wrote:
>> Ok, I'm trying to get my head wrapped around this:
>> 1.  I know that KVM apparently doesn't have the ability to share it's
>> xml configuration files for the vm's across multiple nodes.  However,
>> for a live migration to work, the xml file must exist on each node in
>> order to migrate between them.  According to
>> http://www.mail-archive.com/libvir-list redhat com/msg16921.html ,
>> that is not a good idea.
> This isn't entirely accurate. There are potentially 2 XML files
> for any guest
>  - A persistent guest has a XML file on disk in /etc/libvirt/qemu.
>   If it is running it also has a live XML config in
>   /var/lib/libvirt/qemu reflecting current state
>  - A transient guest only has the live XML config in
>   /var/lib/libvirt/qemu reflecting current state
> During migration, libvirt automatically transfers the *live*
> XML config (ie the one in /var) across to the destination.
> For transient guests everything is working just fine.  For
> persistent guests, this means that by default, they will
> not have any config in /etc/libvirt/qemu after migration.
> With a new enough libvirt, you can ask it to also persist
> the configuration on the new host, using the --persistent
> flag to 'virsh migrate'. You can also make it delete the
> XML on the original host with  --undefinesource.
>> 2.  I have been reading about KvmMigration using rgmanager,
>> http://sources.redhat.com/cluster/wiki/KvmMigration, and here it
>> implies that the xml files can be on gfs2 filesystems.  In particular:
>>  Example vm using xmlfile:
>>   <vm name="mydomain" xmlfile="/mounts/gfs-guests/mydomain.xml" />
>> I assume that this would go in the cluster.conf file within the <rm> tags?
> This kind of setup is fine. From libvirt's POV the guests are all
> transient, since there is no persistent confi in /etc/libvirt/qemu.
> The persistent configs are all in your seperate GFS2 cluster FS.
> When ClusterSuite needs to start a guest, the XML is loaded off
> GFS2 and given to libvirt at time of boot creating a transient
> guest.
> Any architecture with a centralized management server will typically
> use transient guests, and ignore libvirt's persistent guest capability.
> They will either have XML configs in some shared FS as is described
> above, or may not store XML anywhere at all. eg RHEV-M/oVirt would
> store a description of the guest in a SQL database and auto-generate
> XML only when needing to boot it
>> Essentially, this is what I'm trying to get ironed out:
>> A.  I have 2 SAN arrays that I will use multipath on between my two
>> hosts, so I would like to use GFS2 formatted partitions to store the
>> vm disk images.
>> B.  I would then have to have another partition that is GFS2 formatted
>> to hold the vm xml files.  Would this partition also be on the SAN, or
>> can I have the same mount point on both host servers (on local disks
>> there), formatted to GFS2, and they would share with each other the
>> xml files?
> If you're keeping the master XML files outside of /etc/libvirt/qemu,
> on some shared FS, they there's no restrictions, since they won't
> be managed by libvirt at all. You could thus even put the XML files
> at the same place as the disk images if you like.
> Daniel
> --
> |: http://berrange.com      -o-    http://www.flickr.com/photos/dberrange/ :|
> |: http://libvirt.org              -o-             http://virt-manager.org :|
> |: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
> |: http://entangle-photo.org       -o-       http://live.gnome.org/gtk-vnc :|

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]