From: Hadmut Danisch <hadmut@danisch.de>
To: linux-lvm@redhat.com
Subject: [linux-lvm] LVM can't detect raid-1 mirrors?
Date: Mon, 18 Jul 2005 11:02:26 +0200 [thread overview]
Message-ID: <20050718090226.GA4083@danisch.de> (raw)
Hi,
I need some help with a strange lvm problem:
I want to put LVM on a Linux Raid-1 device. I already did this several
times successfully. But this time I have a strange problem:
The raid device is /dev/md3, and it should consist of the two partitions
/dev/hda3 and /dev/hdc3.
I created the raid device with just /dev/hdc3, second missing,
then pvcreate /dev/md3 and created the volume group 'raid'.
Works well.
pvscan correctly shows the raid device instead of /dev/hdc3:
sodom# pvscan
PV /dev/hdc4 VG nord lvm2 [58,59 GB / 33,59 GB free]
PV /dev/md3 VG raid lvm2 [54,35 GB / 21,35 GB free]
Total: 2 [112,94 GB] / in use: 2 [112,94 GB] / in no VG: 0 [0 ]
(ignore hdc4, it is just another lvm because hdc is larger than
hda, there is no problem with hdc4)
But as soon as I add /dev/hda3 to the raid system (mdad /dev/md3 -a
/dev/hda3), lvm confuses the partitions. It does not detect /dev/md3
anymore and complains that there are two different partitions with the
same ID:
sodom# pvscan
Found duplicate PV 39jeBxsxpKtJrwP6FN3Yvq6zB7khU6Pa: using /dev/hdc3
not /dev/hda3
PV /dev/hdc4 VG nord lvm2 [58,59 GB / 33,59 GB free]
PV /dev/hda3 VG raid lvm2 [54,35 GB / 21,35 GB free]
Total: 2 [112,94 GB] / in use: 2 [112,94 GB] / in no VG: 0 [0 ]
The volume group can't then be used. As soon as I take out /dev/hda3
and wipe the first sectors, everything is ok again.
Any idea what's going wrong here?
Just in case it matters, the partition tables:
sodom# sfdisk -l /dev/hda
Disk /dev/hda: 116301 cylinders, 16 heads, 63 sectors/track
Warning: The partition table looks like it was made
for C/H/S=*/255/63 (instead of 116301/16/63).
For this listing I'll assume that geometry.
Units = cylinders of 8225280 bytes, blocks of 1024 bytes, counting
from 0
Device Boot Start End #cyls #blocks Id System
/dev/hda1 0+ 100 101- 811251 fd Linux raid autodetect
/dev/hda2 101 201 101 811282+ fd Linux raid autodetect
/dev/hda3 202 7296 7095 56990587+ fd Linux raid autodetect
/dev/hda4 0 - 0 0 0 Empty
sodom# sfdisk -l /dev/hdc
Disk /dev/hdc: 238216 cylinders, 16 heads, 63 sectors/track
Warning: The partition table looks like it was made
for C/H/S=*/255/63 (instead of 238216/16/63).
For this listing I'll assume that geometry.
Units = cylinders of 8225280 bytes, blocks of 1024 bytes, counting
from 0
Device Boot Start End #cyls #blocks Id System
/dev/hdc1 0+ 100 101- 811251 fd Linux raid autodetect
/dev/hdc2 101 201 101 811282+ fd Linux raid autodetect
/dev/hdc3 202 7296 7095 56990587+ fd Linux raid autodetect
/dev/hdc4 7297 14945 7649 61440592+ 8e Linux LVM
regards
Hadmut
next reply other threads:[~2005-07-18 9:02 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-07-18 9:02 Hadmut Danisch [this message]
2005-07-18 9:29 ` [linux-lvm] LVM can't detect raid-1 mirrors? Hadmut Danisch
2005-07-18 14:56 ` Jonathan E Brassow
2005-07-19 19:40 ` Hadmut Danisch
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20050718090226.GA4083@danisch.de \
--to=hadmut@danisch.de \
--cc=linux-lvm@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.