0

due to a failing hard disk, I would like to deactivate the volume groups living on it, to make sure that the disk is messed with as little as possible until it gets replaced.

I know that I can deactivate the logical volumes and the volume group with lvchange/vgchange --activate n, however as soon as the system is rebooted, these LVs and VGs get auto-reactivate.

I cannot understand how the auto-reactivation can be suppressed in ubuntu 20.04. The parameters that should be relevant in the lvm configuration appear to do nothing.

I suspect that in ubuntu the VG/LV auto activation logic sits in udev rules and completely ignore the lvm configuration. Is this the case? How can the desired behavior be obtained, then?

Any hint?

callegar
  • 123
  • 3

1 Answers1

0

You can configure exactly which volume groups and logical volumes to auto-activate during boot using the activation/auto_activation_volume_list option in /etc/lvm/lvm.conf

This way you can list which vg's to activate, excluding the one you don't want to have auto-activated.