system: add cloud-init lvm config#86
Merged
Merged
Conversation
- add global_filter to avoid create LVM device Signed-off-by: Vicente Cheng <vicente.cheng@suse.com>
tserong
approved these changes
Dec 18, 2023
Member
tserong
left a comment
There was a problem hiding this comment.
Given Harvester doesn't configure LVM on the host, it seems safe to summarily reject everything as you've done here, and I've also done some testing to confirm we don't get the disk I/O errors during migration with this patch applied.
We'll probably need to handle this differently if we later decide to make harvester configure LVM on the host, but IMO we can cross that bridge when we come to it.
bk201
approved these changes
Dec 18, 2023
Collaborator
Author
|
@Mergifyio backport harvester-v1.2.x |
✅ Backports have been createdDetails
|
Collaborator
Author
|
@Mergifyio backport harvester-v1.1.x |
✅ Backports have been createdDetails
|
tserong
added a commit
to tserong/harvester-installer
that referenced
this pull request
Apr 19, 2024
harvester/os2#86 adds a global_filter to /etc/lvm/lvm.conf to avoid activing LVM on the host. Unfortunately, dracut-initqueue runs _very_ early in the boot process (before any of the elemental stages are run), so this filter isn't taken into account on boot, and LVM volumes are still potentially activated. Later, when we try to run `blkdeactivate` in `harv-install`, it doesn't work, because the filter _is_ active then, so it skips deactivation and then the subsequent disk repartitioning fails. We can work around this by setting up a temporary lvm config which has that global_filter stripped out. Related issue: harvester/harvester#5398 Signed-off-by: Tim Serong <tserong@suse.com>
Vicente-Cheng
pushed a commit
to harvester/harvester-installer
that referenced
this pull request
Apr 19, 2024
harvester/os2#86 adds a global_filter to /etc/lvm/lvm.conf to avoid activing LVM on the host. Unfortunately, dracut-initqueue runs _very_ early in the boot process (before any of the elemental stages are run), so this filter isn't taken into account on boot, and LVM volumes are still potentially activated. Later, when we try to run `blkdeactivate` in `harv-install`, it doesn't work, because the filter _is_ active then, so it skips deactivation and then the subsequent disk repartitioning fails. We can work around this by setting up a temporary lvm config which has that global_filter stripped out. Related issue: harvester/harvester#5398 Signed-off-by: Tim Serong <tserong@suse.com>
mergify Bot
pushed a commit
to harvester/harvester-installer
that referenced
this pull request
Apr 19, 2024
harvester/os2#86 adds a global_filter to /etc/lvm/lvm.conf to avoid activing LVM on the host. Unfortunately, dracut-initqueue runs _very_ early in the boot process (before any of the elemental stages are run), so this filter isn't taken into account on boot, and LVM volumes are still potentially activated. Later, when we try to run `blkdeactivate` in `harv-install`, it doesn't work, because the filter _is_ active then, so it skips deactivation and then the subsequent disk repartitioning fails. We can work around this by setting up a temporary lvm config which has that global_filter stripped out. Related issue: harvester/harvester#5398 Signed-off-by: Tim Serong <tserong@suse.com> (cherry picked from commit 43dd846)
mergify Bot
pushed a commit
to harvester/harvester-installer
that referenced
this pull request
Apr 19, 2024
harvester/os2#86 adds a global_filter to /etc/lvm/lvm.conf to avoid activing LVM on the host. Unfortunately, dracut-initqueue runs _very_ early in the boot process (before any of the elemental stages are run), so this filter isn't taken into account on boot, and LVM volumes are still potentially activated. Later, when we try to run `blkdeactivate` in `harv-install`, it doesn't work, because the filter _is_ active then, so it skips deactivation and then the subsequent disk repartitioning fails. We can work around this by setting up a temporary lvm config which has that global_filter stripped out. Related issue: harvester/harvester#5398 Signed-off-by: Tim Serong <tserong@suse.com> (cherry picked from commit 43dd846)
Vicente-Cheng
pushed a commit
to harvester/harvester-installer
that referenced
this pull request
Apr 23, 2024
harvester/os2#86 adds a global_filter to /etc/lvm/lvm.conf to avoid activing LVM on the host. Unfortunately, dracut-initqueue runs _very_ early in the boot process (before any of the elemental stages are run), so this filter isn't taken into account on boot, and LVM volumes are still potentially activated. Later, when we try to run `blkdeactivate` in `harv-install`, it doesn't work, because the filter _is_ active then, so it skips deactivation and then the subsequent disk repartitioning fails. We can work around this by setting up a temporary lvm config which has that global_filter stripped out. Related issue: harvester/harvester#5398 Signed-off-by: Tim Serong <tserong@suse.com> (cherry picked from commit 43dd846)
Vicente-Cheng
pushed a commit
to harvester/harvester-installer
that referenced
this pull request
Apr 23, 2024
harvester/os2#86 adds a global_filter to /etc/lvm/lvm.conf to avoid activing LVM on the host. Unfortunately, dracut-initqueue runs _very_ early in the boot process (before any of the elemental stages are run), so this filter isn't taken into account on boot, and LVM volumes are still potentially activated. Later, when we try to run `blkdeactivate` in `harv-install`, it doesn't work, because the filter _is_ active then, so it skips deactivation and then the subsequent disk repartitioning fails. We can work around this by setting up a temporary lvm config which has that global_filter stripped out. Related issue: harvester/harvester#5398 Signed-off-by: Tim Serong <tserong@suse.com> (cherry picked from commit 43dd846)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
related issue: harvester/harvester#4674
Test Plan:
/etc/lvm/lvm.confcontain the following patch/dev/sda)now we can check the
/dev/sdawith lvm(If we miss this patch, we will see the following result on the host)