mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 05:35:25 +00:00
virt-sanlock-cleanup; Fix augtool usage
Surprisingly, augtool get (or print) returns "path = value" while we are only interested in the value. We need to remove the "path = " part from the augtool's output. The following is an example of the augtool command as used in virt-sanlock-cleanup script: $ augtool get /files/etc/libvirt/qemu-sanlock.conf/disk_lease_dir /files/etc/libvirt/qemu-sanlock.conf/disk_lease_dir = /var/lib/libvirt/sanlock
This commit is contained in:
parent
ac43da705f
commit
74c5156f9d
@ -26,7 +26,8 @@ fi
|
||||
|
||||
LOCKSPACE="__LIBVIRT__DISKS__"
|
||||
|
||||
LOCKDIR=`augtool print '/files@sysconfdir@/libvirt/qemu-sanlock.conf/disk_lease_dir'`
|
||||
LOCKDIR=`augtool get '/files@sysconfdir@/libvirt/qemu-sanlock.conf/disk_lease_dir'`
|
||||
LOCKDIR=${LOCKDIR#* = }
|
||||
if test $? != 0 || test "x$LOCKDIR" = "x" ; then
|
||||
LOCKDIR="@localstatedir@/lib/libvirt/sanlock"
|
||||
fi
|
||||
|
Loading…
Reference in New Issue
Block a user