:: Re: [DNG] [OT] Help on change (spli…
Top Page
Delete this message
Reply to this message
Author: al3xu5
Date:  
To: dng
Subject: Re: [DNG] [OT] Help on change (split) partitions of an md raid
Tue, 27 Jun 2023 19:51:31 +0200 - Antony Stone
<Antony.Stone@???>:

> On Tuesday 27 June 2023 at 19:34:25, al3xu5 via Dng wrote:
>
> > Hi all
> >
> > I know I am OT (again), but I need help and hope you will excuse me...
> >
> > I have two identical disk, each with two partitions of the same size,
> > with no unpartitioned space left:
> >
> > DISK1: Disk1Part1 + Disk1Part2
> > DISK2: Disk2Part1 + Disk2Part2
> >
> > I have a md RAID1 (mirror) on those disks:
> >
> > md1: Disk1Part1 + Disk2Part1
> > md2: Disk1Part2 + Disk2Part2
> >
> > Now I need to split each of the 2nd partitions in two smaller
> > partitions, so as to obtain:
> >
> > DISK1: Disk1Part1 + Disk1Part2 + Disk1Part3
> > DISK2: Disk2Part1 + Disk2Part2 + Disk2Part3
> >
> > and:
> >
> > md1: Disk1Part1 + Disk2Part1
> > md2: Disk1Part2 + Disk2Part2
> > md3: Disk1Part3 + Disk2Part3
> >
> > Please can you suggest the best and safe way (correct procedure,
> > commands, tools to use etc.) to do this (obviously, I have a backup of
> > all the data)?
>
> 1. Unmount anything which is using /dev/md2
>
> 2. mdadm --stop /dev/md2
>
> 3. Use fdisk, sfdisk, parted or whatever your preferred tool of choice
> is, to delete /dev/sda2 and /dev/sdb2 (I'm guessing at your device names
> here)
>
> 4. Create /dev/sda2 / sda3 and /dev/sdb2 / sdb3 with whatever sizes you
> require
>
> 5. mdadm --create /dev/md2 --level=1 --raid-devices=2 /dev/sda2 /dev/sdb2
>
> 6. Same as above for md3 / sda3 / sdb3
>
> 7. Use /usr/share/mdadm/mkconf to re-create /etc/mdadm/mdadm.conf
>
> 8. Use "update-initramfs -u -k all" to re-create your initramfs with
> knowledge of the new arrays
>
> 9. Format /dev/md2 and /dev/md3 and mount as you wish...
>
>
> I would expect steps 4, 5 and 6 to show some warnings about the
> partitions containing raid signatures. Confirm that you want to delete
> them.
>
>
> Antony.
>


Great.
Thank you

al3xu5

--
Property is theft! (P-J Proudhon) ...today more than ever.
____________________________________________________________________________

Public GPG/PGP key: 8FC2 3121 2803 86E9 F7D8 B624 DA50 835B 2624 A36B