Re: mdadm serious does wrong partition changes
On Sun, Dec 03, 2017 at 01:22:53PM +0100, Frans van Berckel wrote:
> Dear Team,
> I am creating raid partitions. First only sdd1, wanna add sdc1 later
> on. But creating sdd1 does serious wrong partition changes. Because it
> drops the partition tabel. And creates a new one.
> First what do we have ...
> # fdisk -l /dev/sdd
> Disk /dev/sdd: 33.9 GiB, 36420075008 bytes, 71132959 sectors
> Geometry: 255 heads, 63 sectors/track, 4427 cylinders
> Units: sectors of 1 * 512 = 512 bytes
> Sector size (logical/physical): 512 bytes / 512 bytes
> I/O size (minimum/optimal): 512 bytes / 512 bytes
> Disklabel type: sun
> Device Start End Sectors Size Id
> Type Flags
> /dev/sdd1 0 58589054 58589055 28G fd Linux raid autodetect
here is the issue: Partition sdd1 starts on sector 0, which is common
on sparc but normaly never setup so on x86/amd64 (fdisk refuses
it on x86/64 even in expert mode, tried that last week). On sparc that only
works as many filesystems (for example ext2/3/4) leave enough space
at the beginning to keep the partition table intact.
So for Linux this setup could also be an md device without an partition
table - which is also allowed and I use(d) such setups.
I even used partitioned mirrored root devices some time and it
works (the partion table is mirrord than too), but it's a very special
setup and you need to know all details - like the location of md superblocks.
Never used lsblk, but my feeling is, you can't blame it or the md code
really in that case - as it's not distinguishable on md level what you mean.
Hope this helps and greetings
Netzwerkadministration/Zentrale Dienste, Interdiziplinaeres
Zentrum fuer wissenschaftliches Rechnen der Universitaet Heidelberg
IWR; INF 205; 69120 Heidelberg; Tel: (06221)54-14405 Fax: -14427