* master - scan: md metadata version 0.90 is at the end of disk
@ 2018-11-29 18:36 David Teigland
2018-12-03 2:43 ` Gang He
0 siblings, 1 reply; 4+ messages in thread
From: David Teigland @ 2018-11-29 18:36 UTC (permalink / raw)
To: lvm-devel
Gitweb: https://sourceware.org/git/?p=lvm2.git;a=commitdiff;h=cb04b84c79f10e6b3f1b376cf7611d0afed26c39
Commit: cb04b84c79f10e6b3f1b376cf7611d0afed26c39
Parent: cd0fb0846db0d0bc04469914f6866a04af377548
Author: Peter Rajnoha <prajnoha@redhat.com>
AuthorDate: Thu Nov 29 12:35:54 2018 -0600
Committer: David Teigland <teigland@redhat.com>
CommitterDate: Thu Nov 29 12:35:54 2018 -0600
scan: md metadata version 0.90 is at the end of disk
commit de28637
scan: use full md filter when md 1.0 devices are present
missed the fact that md superblock version 0.90 also puts
metadata at the end of the device, so the full md filter
needs to be used when either 0.90 or 1.0 is present.
---
lib/device/dev-md.c | 2 +-
lib/filters/filter-md.c | 6 +++---
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/lib/device/dev-md.c b/lib/device/dev-md.c
index ac99f42..9c626dd 100644
--- a/lib/device/dev-md.c
+++ b/lib/device/dev-md.c
@@ -422,7 +422,7 @@ int dev_is_md_with_end_superblock(struct dev_types *dt, struct device *dev)
log_very_verbose("Device %s %s is %s.",
dev_name(dev), attribute, version_string);
- if (!strcmp(version_string, "1.0"))
+ if (!strcmp(version_string, "1.0") || !strcmp(version_string, "0.90"))
return 1;
return 0;
}
diff --git a/lib/filters/filter-md.c b/lib/filters/filter-md.c
index 2214986..0275923 100644
--- a/lib/filters/filter-md.c
+++ b/lib/filters/filter-md.c
@@ -46,7 +46,7 @@
* 3. use udev to detect components
*
* mode 1 will not detect and exclude components of md devices
- * that use superblock version 1.0 which is at the end of the device.
+ * that use superblock version 0.9 or 1.0 which is at the end of the device.
*
* mode 2 will detect these, but mode 2 doubles the i/o done by label
* scan, since there's a read at both the start and end of every device.
@@ -59,11 +59,11 @@
*
* - the command is pvcreate/vgcreate/vgextend, which format new
* devices, and if the user ran these commands on a component
- * device of an md device 1.0, then it would cause problems.
+ * device of an md device 0.9 or 1.0, then it would cause problems.
* FIXME: this would only really need to scan the end of the
* devices being formatted, not all devices.
*
- * - it sees an md device on the system using version 1.0.
+ * - it sees an md device on the system using version 0.9 or 1.0.
* The point of this is just to avoid displaying md components
* from the 'pvs' command.
* FIXME: the cost (double i/o) may not be worth the benefit
^ permalink raw reply related [flat|nested] 4+ messages in thread* master - scan: md metadata version 0.90 is at the end of disk
2018-11-29 18:36 master - scan: md metadata version 0.90 is at the end of disk David Teigland
@ 2018-12-03 2:43 ` Gang He
2018-12-03 17:22 ` David Teigland
0 siblings, 1 reply; 4+ messages in thread
From: Gang He @ 2018-12-03 2:43 UTC (permalink / raw)
To: lvm-devel
Hello David,
This patch can be used to fix this problem, or not?
https://www.redhat.com/archives/linux-lvm/2018-October/msg00049.html
Thanks
Gang
>>> On 2018/11/30 at 2:36, in message
<201811291836.wATIaSVc015670@lists01.pubmisc.prod.ext.phx2.redhat.com>, David
Teigland <teigland@sourceware.org> wrote:
> Gitweb:
> https://sourceware.org/git/?p=lvm2.git;a=commitdiff;h=cb04b84c79f10e6b3f1b376
> cf7611d0afed26c39
> Commit: cb04b84c79f10e6b3f1b376cf7611d0afed26c39
> Parent: cd0fb0846db0d0bc04469914f6866a04af377548
> Author: Peter Rajnoha <prajnoha@redhat.com>
> AuthorDate: Thu Nov 29 12:35:54 2018 -0600
> Committer: David Teigland <teigland@redhat.com>
> CommitterDate: Thu Nov 29 12:35:54 2018 -0600
>
> scan: md metadata version 0.90 is at the end of disk
>
> commit de28637
> scan: use full md filter when md 1.0 devices are present
>
> missed the fact that md superblock version 0.90 also puts
> metadata at the end of the device, so the full md filter
> needs to be used when either 0.90 or 1.0 is present.
> ---
> lib/device/dev-md.c | 2 +-
> lib/filters/filter-md.c | 6 +++---
> 2 files changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/lib/device/dev-md.c b/lib/device/dev-md.c
> index ac99f42..9c626dd 100644
> --- a/lib/device/dev-md.c
> +++ b/lib/device/dev-md.c
> @@ -422,7 +422,7 @@ int dev_is_md_with_end_superblock(struct dev_types *dt,
> struct device *dev)
> log_very_verbose("Device %s %s is %s.",
> dev_name(dev), attribute, version_string);
>
> - if (!strcmp(version_string, "1.0"))
> + if (!strcmp(version_string, "1.0") || !strcmp(version_string, "0.90"))
> return 1;
> return 0;
> }
> diff --git a/lib/filters/filter-md.c b/lib/filters/filter-md.c
> index 2214986..0275923 100644
> --- a/lib/filters/filter-md.c
> +++ b/lib/filters/filter-md.c
> @@ -46,7 +46,7 @@
> * 3. use udev to detect components
> *
> * mode 1 will not detect and exclude components of md devices
> - * that use superblock version 1.0 which is at the end of the device.
> + * that use superblock version 0.9 or 1.0 which is at the end of the
> device.
> *
> * mode 2 will detect these, but mode 2 doubles the i/o done by label
> * scan, since there's a read at both the start and end of every device.
> @@ -59,11 +59,11 @@
> *
> * - the command is pvcreate/vgcreate/vgextend, which format new
> * devices, and if the user ran these commands on a component
> - * device of an md device 1.0, then it would cause problems.
> + * device of an md device 0.9 or 1.0, then it would cause problems.
> * FIXME: this would only really need to scan the end of the
> * devices being formatted, not all devices.
> *
> - * - it sees an md device on the system using version 1.0.
> + * - it sees an md device on the system using version 0.9 or 1.0.
> * The point of this is just to avoid displaying md components
> * from the 'pvs' command.
> * FIXME: the cost (double i/o) may not be worth the benefit
>
> --
> lvm-devel mailing list
> lvm-devel at redhat.com
> https://www.redhat.com/mailman/listinfo/lvm-devel
^ permalink raw reply [flat|nested] 4+ messages in thread* master - scan: md metadata version 0.90 is at the end of disk
2018-12-03 2:43 ` Gang He
@ 2018-12-03 17:22 ` David Teigland
2018-12-10 5:29 ` Gang He
0 siblings, 1 reply; 4+ messages in thread
From: David Teigland @ 2018-12-03 17:22 UTC (permalink / raw)
To: lvm-devel
On Sun, Dec 02, 2018 at 07:43:34PM -0700, Gang He wrote:
> Hello David,
>
> This patch can be used to fix this problem, or not?
> https://www.redhat.com/archives/linux-lvm/2018-October/msg00049.html
On the stable branch there are three recent commits to fix/improve
md component detection. I hope these will close any remaining gaps
in this area, let me know how these work.
scan: md metadata version 0.90 is at the end of disk
https://sourceware.org/git/?p=lvm2.git;a=commit;h=0e42ebd6d4012d210084a9ccf8d76f853726de3c
pvscan lvmetad: use full md filter when md 1.0 devices are present
https://sourceware.org/git/?p=lvm2.git;a=commit;h=a01e1fec0fe7c2fa61577c0e636e907cde7279ea
pvscan lvmetad: use udev info to improve md component detection
https://sourceware.org/git/?p=lvm2.git;a=commit;h=a188b1e513ed5ca0f5f3702c823490f5610d4495
^ permalink raw reply [flat|nested] 4+ messages in thread
* master - scan: md metadata version 0.90 is at the end of disk
2018-12-03 17:22 ` David Teigland
@ 2018-12-10 5:29 ` Gang He
0 siblings, 0 replies; 4+ messages in thread
From: Gang He @ 2018-12-10 5:29 UTC (permalink / raw)
To: lvm-devel
Hello David,
Some feedback from our user is as below,
It still does not work out and ends up in the emergency console, although error messages are different now:
in journal (journalctl -xb):
Unit lvm2-pvscan at 259:0.service has finished starting up.
[...]
Dec 08 15:27:28 big lvmetad[560]: vg_lookup vgid 6zO4JX-piC2-OaCG-GptZ-MT2F-NH4J-jL6gNj name vghome found incomplete mapping uuid none name none
[...]
Dec 08 15:28:57 big systemd[1]: dev-vghome-data.device: Job dev-vghome-data.device/start timed out.
Dec 08 15:28:57 big systemd[1]: Timed out waiting for device dev-vghome-data.device.
-- Subject: Unit dev-vghome-data.device has failed
[...]
During boot following can be seen:
"A start job is running for dev-vghome-data.device (counting secs/1min 30s)"
This one fails and emergency console starts.
What can I provide additionally?
Do you think his problem is related to these patches, or it is another problem?
Thanks
Gang
>>> On 2018/12/4 at 1:22, in message <20181203172221.GA6362@redhat.com>, David
Teigland <teigland@redhat.com> wrote:
> On Sun, Dec 02, 2018 at 07:43:34PM -0700, Gang He wrote:
>> Hello David,
>>
>> This patch can be used to fix this problem, or not?
>> https://www.redhat.com/archives/linux-lvm/2018-October/msg00049.html
>
> On the stable branch there are three recent commits to fix/improve
> md component detection. I hope these will close any remaining gaps
> in this area, let me know how these work.
>
> scan: md metadata version 0.90 is at the end of disk
> https://sourceware.org/git/?p=lvm2.git;a=commit;h=0e42ebd6d4012d210084a9ccf8
> d76f853726de3c
>
> pvscan lvmetad: use full md filter when md 1.0 devices are present
> https://sourceware.org/git/?p=lvm2.git;a=commit;h=a01e1fec0fe7c2fa61577c0e63
> 6e907cde7279ea
>
> pvscan lvmetad: use udev info to improve md component detection
> https://sourceware.org/git/?p=lvm2.git;a=commit;h=a188b1e513ed5ca0f5f3702c82
> 3490f5610d4495
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2018-12-10 5:29 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-11-29 18:36 master - scan: md metadata version 0.90 is at the end of disk David Teigland
2018-12-03 2:43 ` Gang He
2018-12-03 17:22 ` David Teigland
2018-12-10 5:29 ` Gang He
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.