Re: [fedora-virt] Sanlock + libvirt

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

 



Hello,

On Mon, Sep 09, 2013 at 01:51:19PM +0100, Daniel P. Berrange wrote:
> On Mon, Sep 09, 2013 at 08:43:39AM -0400, Cole Robinson wrote:
> > cc-ing libvir-list
> > 
> > On 09/09/2013 08:20 AM, Ján ONDREJ (SAL) wrote:
> > >   in sanlock docs (https://fedorahosted.org/sanlock/) there is described,
> > > how to use it. There is no mention about NFS. Can I use sanlock with LVM
> > > (without NFS) with livbirt? It this feature implemented in libvirt for
> > > Fedora or RHEL?
> > > 
> > >   For libvirt I need to define lease dir as:
> > >     disk_lease_dir = "/var/lib/libvirt/sanlock"
> > > but this have to be a directory. How to configure it to use sanlock on LVM?
> 
> There are two ways to use sanlock in libvirt.
> 
> With the automatic way, libvirt will create leases for each disk in a VM's
> config. This requires a shared filesystem of some kind, such as NFS. This
> is what all the config parameters in /etc/libvirt/qemu-sanlock.conf are
> about.
> 
> With the manual way, the application / admin creating the guest XML files
> must manually specify leases using the <lease> XML element. This lets you
> use any type of storage including LVM or raw block devices.
> 
> oVirt/RHEV-M is the only thing I know of that uses the manual approach.
> 
> I would not recommend using the manual approach outside of oVirt since it
> requires alot of tedious work to get it right. The automatic approach is
> what we recomend for everyone else, and that's filesystem based only.

This manual method looks to work well. It's enough to create an sanlock
device init and add lockspace. But after each reboot I need to again
add lockspaces and init resources. Is there an suggested way to add
them into configuration files? Or do I need to create my own init script run
between sanlock and libvirt?

Another problem looks to be same for automatic and manual approach.
My storage configuration is fully redundant. Each storage is in different
location and each guest has 2 virtual disks in software mirror (mirrored in
guest). If one storage fails, mirror fails, but guests are running without
problems from secondary storage.

Can I somehow configure sanlock storage same way? I tested to have 2 sanlock
pools and lockspaces, but I can't init resource on 2 lockspaces.
Second resource init removes my virtual disk from first lockspace.
Is it possible to configure 2 fully redundant lockspaces.
Shutdown of all virtual machines if first storage sounds a bit problematic.

					SAL

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list





[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]