Ensure lvm2-lvmetad service running on Fedora
When the lvm package gets installed the meta service does not gets started automatically, but it becomes enabled so it would be running on the next reboot. The lvm commands are configured to use this service. In the past this issue just causes warnings in the cinder log, but now it can lead to a real issue. It is better to ensure it is really running, because it speeds up the lvm related commands. Change-Id: I17fe2c3bcf77a6505ed2b6c824c5b20807beb725
This commit is contained in:
parent
2e9d32baf2
commit
380d92cc7a
9
lib/lvm
9
lib/lvm
@ -103,14 +103,17 @@ function _create_lvm_volume_group {
|
||||
function init_lvm_volume_group {
|
||||
local vg=$1
|
||||
local size=$2
|
||||
# Start with a clean volume group
|
||||
_create_lvm_volume_group $vg $size
|
||||
|
||||
# Start the lvmetad and tgtd services
|
||||
if is_fedora || is_suse; then
|
||||
# service is not started by default
|
||||
# services is not started by default
|
||||
start_service lvm2-lvmetad
|
||||
start_service tgtd
|
||||
fi
|
||||
|
||||
# Start with a clean volume group
|
||||
_create_lvm_volume_group $vg $size
|
||||
|
||||
# Remove iscsi targets
|
||||
sudo tgtadm --op show --mode target | grep Target | cut -f3 -d ' ' | sudo xargs -n1 tgt-admin --delete || true
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user