How to resize linux partition with RAID1?
I have a Proxmox disk with 130Gb LVM image. I moved it to 235Gb disk. And resized in the Proxmox. Done.
But in my Linux distro, the partition still 130Gb (disk become 235Gb).
The partitions:
/dev/sda1
/dev/sdb1
They are part of RAID1 volume: /dev/md0
What is the correct way to resize it from 130Gb to 235Gb without loosing data?
**root@debian:~# fdisk -l**
Disk /dev/sdb: 235 GiB, 252329328640 bytes, 492830720 sectors
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: dos
Disk identifier: 0xd098f1da
Device Boot Start End Sectors Size Id Type
/dev/sdb1 2048 273436671 273434624 130.4G fd Linux raid autodetect
/dev/sdb2 273436672 291502079 18065408 8.6G fd Linux raid autodetect
Disk /dev/sda: 235 GiB, 252329328640 bytes, 492830720 sectors
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: dos
Disk identifier: 0x559572cb
Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 273436671 273434624 130.4G fd Linux raid autodetect
/dev/sda2 273436672 291502079 18065408 8.6G fd Linux raid autodetect
Disk /dev/md0: 130.3 GiB, 139864309760 bytes, 273172480 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/md1: 8.6 GiB, 9241100288 bytes, 18049024 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
**root@debian:~# cat /proc/mdstat**
Personalities : [raid1]
md1 : active (auto-read-only) raid1 sda2[0] sdb2[1]
9024512 blocks super 1.2 [2/2] [UU]
md0 : active raid1 sda1[0] sdb1[1]
136586240 blocks super 1.2 [2/2] [UU]
bitmap: 0/2 pages [0KB], 65536KB chunk
unused devices: <none>
**root@debian:~# cat /proc/partitions**
major minor #blocks name
8 16 246415360 sdb
8 17 136717312 sdb1
8 18 9032704 sdb2
8 0 246415360 sda
8 1 136717312 sda1
8 2 9032704 sda2
11 0 1048575 sr0
9 0 136586240 md0
9 1 9024512 md1
I tried without succes:
**root@debian:~# mdadm --grow --size max /dev/md0**
mdadm: component size of /dev/md0 unchanged at 136586240K
unfreeze
**root@debian:~# resize2fs /dev/md0**
resize2fs 1.43.3 (04-Sep-2016)
The filesystem is already 34146560 (4k) blocks long. Nothing to do!
partition fdisk raid1 resize2fs
add a comment |
I have a Proxmox disk with 130Gb LVM image. I moved it to 235Gb disk. And resized in the Proxmox. Done.
But in my Linux distro, the partition still 130Gb (disk become 235Gb).
The partitions:
/dev/sda1
/dev/sdb1
They are part of RAID1 volume: /dev/md0
What is the correct way to resize it from 130Gb to 235Gb without loosing data?
**root@debian:~# fdisk -l**
Disk /dev/sdb: 235 GiB, 252329328640 bytes, 492830720 sectors
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: dos
Disk identifier: 0xd098f1da
Device Boot Start End Sectors Size Id Type
/dev/sdb1 2048 273436671 273434624 130.4G fd Linux raid autodetect
/dev/sdb2 273436672 291502079 18065408 8.6G fd Linux raid autodetect
Disk /dev/sda: 235 GiB, 252329328640 bytes, 492830720 sectors
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: dos
Disk identifier: 0x559572cb
Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 273436671 273434624 130.4G fd Linux raid autodetect
/dev/sda2 273436672 291502079 18065408 8.6G fd Linux raid autodetect
Disk /dev/md0: 130.3 GiB, 139864309760 bytes, 273172480 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/md1: 8.6 GiB, 9241100288 bytes, 18049024 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
**root@debian:~# cat /proc/mdstat**
Personalities : [raid1]
md1 : active (auto-read-only) raid1 sda2[0] sdb2[1]
9024512 blocks super 1.2 [2/2] [UU]
md0 : active raid1 sda1[0] sdb1[1]
136586240 blocks super 1.2 [2/2] [UU]
bitmap: 0/2 pages [0KB], 65536KB chunk
unused devices: <none>
**root@debian:~# cat /proc/partitions**
major minor #blocks name
8 16 246415360 sdb
8 17 136717312 sdb1
8 18 9032704 sdb2
8 0 246415360 sda
8 1 136717312 sda1
8 2 9032704 sda2
11 0 1048575 sr0
9 0 136586240 md0
9 1 9024512 md1
I tried without succes:
**root@debian:~# mdadm --grow --size max /dev/md0**
mdadm: component size of /dev/md0 unchanged at 136586240K
unfreeze
**root@debian:~# resize2fs /dev/md0**
resize2fs 1.43.3 (04-Sep-2016)
The filesystem is already 34146560 (4k) blocks long. Nothing to do!
partition fdisk raid1 resize2fs
add a comment |
I have a Proxmox disk with 130Gb LVM image. I moved it to 235Gb disk. And resized in the Proxmox. Done.
But in my Linux distro, the partition still 130Gb (disk become 235Gb).
The partitions:
/dev/sda1
/dev/sdb1
They are part of RAID1 volume: /dev/md0
What is the correct way to resize it from 130Gb to 235Gb without loosing data?
**root@debian:~# fdisk -l**
Disk /dev/sdb: 235 GiB, 252329328640 bytes, 492830720 sectors
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: dos
Disk identifier: 0xd098f1da
Device Boot Start End Sectors Size Id Type
/dev/sdb1 2048 273436671 273434624 130.4G fd Linux raid autodetect
/dev/sdb2 273436672 291502079 18065408 8.6G fd Linux raid autodetect
Disk /dev/sda: 235 GiB, 252329328640 bytes, 492830720 sectors
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: dos
Disk identifier: 0x559572cb
Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 273436671 273434624 130.4G fd Linux raid autodetect
/dev/sda2 273436672 291502079 18065408 8.6G fd Linux raid autodetect
Disk /dev/md0: 130.3 GiB, 139864309760 bytes, 273172480 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/md1: 8.6 GiB, 9241100288 bytes, 18049024 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
**root@debian:~# cat /proc/mdstat**
Personalities : [raid1]
md1 : active (auto-read-only) raid1 sda2[0] sdb2[1]
9024512 blocks super 1.2 [2/2] [UU]
md0 : active raid1 sda1[0] sdb1[1]
136586240 blocks super 1.2 [2/2] [UU]
bitmap: 0/2 pages [0KB], 65536KB chunk
unused devices: <none>
**root@debian:~# cat /proc/partitions**
major minor #blocks name
8 16 246415360 sdb
8 17 136717312 sdb1
8 18 9032704 sdb2
8 0 246415360 sda
8 1 136717312 sda1
8 2 9032704 sda2
11 0 1048575 sr0
9 0 136586240 md0
9 1 9024512 md1
I tried without succes:
**root@debian:~# mdadm --grow --size max /dev/md0**
mdadm: component size of /dev/md0 unchanged at 136586240K
unfreeze
**root@debian:~# resize2fs /dev/md0**
resize2fs 1.43.3 (04-Sep-2016)
The filesystem is already 34146560 (4k) blocks long. Nothing to do!
partition fdisk raid1 resize2fs
I have a Proxmox disk with 130Gb LVM image. I moved it to 235Gb disk. And resized in the Proxmox. Done.
But in my Linux distro, the partition still 130Gb (disk become 235Gb).
The partitions:
/dev/sda1
/dev/sdb1
They are part of RAID1 volume: /dev/md0
What is the correct way to resize it from 130Gb to 235Gb without loosing data?
**root@debian:~# fdisk -l**
Disk /dev/sdb: 235 GiB, 252329328640 bytes, 492830720 sectors
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: dos
Disk identifier: 0xd098f1da
Device Boot Start End Sectors Size Id Type
/dev/sdb1 2048 273436671 273434624 130.4G fd Linux raid autodetect
/dev/sdb2 273436672 291502079 18065408 8.6G fd Linux raid autodetect
Disk /dev/sda: 235 GiB, 252329328640 bytes, 492830720 sectors
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: dos
Disk identifier: 0x559572cb
Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 273436671 273434624 130.4G fd Linux raid autodetect
/dev/sda2 273436672 291502079 18065408 8.6G fd Linux raid autodetect
Disk /dev/md0: 130.3 GiB, 139864309760 bytes, 273172480 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/md1: 8.6 GiB, 9241100288 bytes, 18049024 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
**root@debian:~# cat /proc/mdstat**
Personalities : [raid1]
md1 : active (auto-read-only) raid1 sda2[0] sdb2[1]
9024512 blocks super 1.2 [2/2] [UU]
md0 : active raid1 sda1[0] sdb1[1]
136586240 blocks super 1.2 [2/2] [UU]
bitmap: 0/2 pages [0KB], 65536KB chunk
unused devices: <none>
**root@debian:~# cat /proc/partitions**
major minor #blocks name
8 16 246415360 sdb
8 17 136717312 sdb1
8 18 9032704 sdb2
8 0 246415360 sda
8 1 136717312 sda1
8 2 9032704 sda2
11 0 1048575 sr0
9 0 136586240 md0
9 1 9024512 md1
I tried without succes:
**root@debian:~# mdadm --grow --size max /dev/md0**
mdadm: component size of /dev/md0 unchanged at 136586240K
unfreeze
**root@debian:~# resize2fs /dev/md0**
resize2fs 1.43.3 (04-Sep-2016)
The filesystem is already 34146560 (4k) blocks long. Nothing to do!
partition fdisk raid1 resize2fs
partition fdisk raid1 resize2fs
edited Jan 6 at 12:21
Rui F Ribeiro
39.5k1479132
39.5k1479132
asked Jan 5 at 15:21
user1443462user1443462
61
61
add a comment |
add a comment |
2 Answers
2
active
oldest
votes
Although the mdadm grow command is correct, it doesn't help here because your partitions are still of the old size.
Disk /dev/sdb: 235 GiB, 252329328640 bytes, 492830720 sectors
Device Boot Start End Sectors Size Id Type
/dev/sdb1 2048 273436671 273434624 130.4G fd Linux raid autodetect
/dev/sdb2 273436672 291502079 18065408 8.6G fd Linux raid autodetect
Your disk is 235G, but the partition is only 130G large and mdadm only sees those 130G.
So you'd have to grow the partition, but there's your next problem, another partition is already there and in the way. So you have to move the 2nd partition away first before you can grow the 1st partition. Another option would be to create a new, 3rd partition and a new RAID on top and use them separately.
If that 8G RAID happens to be swap space, you could also disable swap temporarily, stop the swap RAID, delete those partitions and then grow/re-create as you see fit. Unlike user data, swap can be discarded and re-created on a whim, without a migration step.
Thanks! So, I need to delete sda2 and sdb2 (yes, it's swap). How to I do all that exactly? Can you help me with the command please?
– user1443462
Jan 5 at 19:21
add a comment |
So, if somebody need it. I found working way. I used systemrescuecd.
First step it to remove sda1/2 from RAID1:
mdadm /dev/md0 --fail /dev/sda1
mdadm /dev/md1 --fail /dev/sda2
mdadm /dev/md0 --remove /dev/sda1
mdadm /dev/md1 --remove /dev/sda2
After I removed /dev/sda2 in Gparted (via systemrescuecd)
Removed labels "boot" and "raid" from SDA1 in Gparted
Then, in the command line:
Parted /dev/sda
resizepart
1
245000
quit
Created sda2 in Gparted linux-swap.
mdadm --add /dev/md0 /dev/sda1
mdadm --add /dev/md1 /dev/sda2
Same thing for sdb1/2.
After:
e2fsck -f /dev/sda1
e2fsck -f /dev/sdb1
And:
mdadm --grow --size max /dev/md0
Then I used "check" for md0 in GParted.
Done. Works fine.
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "106"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f492672%2fhow-to-resize-linux-partition-with-raid1%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
Although the mdadm grow command is correct, it doesn't help here because your partitions are still of the old size.
Disk /dev/sdb: 235 GiB, 252329328640 bytes, 492830720 sectors
Device Boot Start End Sectors Size Id Type
/dev/sdb1 2048 273436671 273434624 130.4G fd Linux raid autodetect
/dev/sdb2 273436672 291502079 18065408 8.6G fd Linux raid autodetect
Your disk is 235G, but the partition is only 130G large and mdadm only sees those 130G.
So you'd have to grow the partition, but there's your next problem, another partition is already there and in the way. So you have to move the 2nd partition away first before you can grow the 1st partition. Another option would be to create a new, 3rd partition and a new RAID on top and use them separately.
If that 8G RAID happens to be swap space, you could also disable swap temporarily, stop the swap RAID, delete those partitions and then grow/re-create as you see fit. Unlike user data, swap can be discarded and re-created on a whim, without a migration step.
Thanks! So, I need to delete sda2 and sdb2 (yes, it's swap). How to I do all that exactly? Can you help me with the command please?
– user1443462
Jan 5 at 19:21
add a comment |
Although the mdadm grow command is correct, it doesn't help here because your partitions are still of the old size.
Disk /dev/sdb: 235 GiB, 252329328640 bytes, 492830720 sectors
Device Boot Start End Sectors Size Id Type
/dev/sdb1 2048 273436671 273434624 130.4G fd Linux raid autodetect
/dev/sdb2 273436672 291502079 18065408 8.6G fd Linux raid autodetect
Your disk is 235G, but the partition is only 130G large and mdadm only sees those 130G.
So you'd have to grow the partition, but there's your next problem, another partition is already there and in the way. So you have to move the 2nd partition away first before you can grow the 1st partition. Another option would be to create a new, 3rd partition and a new RAID on top and use them separately.
If that 8G RAID happens to be swap space, you could also disable swap temporarily, stop the swap RAID, delete those partitions and then grow/re-create as you see fit. Unlike user data, swap can be discarded and re-created on a whim, without a migration step.
Thanks! So, I need to delete sda2 and sdb2 (yes, it's swap). How to I do all that exactly? Can you help me with the command please?
– user1443462
Jan 5 at 19:21
add a comment |
Although the mdadm grow command is correct, it doesn't help here because your partitions are still of the old size.
Disk /dev/sdb: 235 GiB, 252329328640 bytes, 492830720 sectors
Device Boot Start End Sectors Size Id Type
/dev/sdb1 2048 273436671 273434624 130.4G fd Linux raid autodetect
/dev/sdb2 273436672 291502079 18065408 8.6G fd Linux raid autodetect
Your disk is 235G, but the partition is only 130G large and mdadm only sees those 130G.
So you'd have to grow the partition, but there's your next problem, another partition is already there and in the way. So you have to move the 2nd partition away first before you can grow the 1st partition. Another option would be to create a new, 3rd partition and a new RAID on top and use them separately.
If that 8G RAID happens to be swap space, you could also disable swap temporarily, stop the swap RAID, delete those partitions and then grow/re-create as you see fit. Unlike user data, swap can be discarded and re-created on a whim, without a migration step.
Although the mdadm grow command is correct, it doesn't help here because your partitions are still of the old size.
Disk /dev/sdb: 235 GiB, 252329328640 bytes, 492830720 sectors
Device Boot Start End Sectors Size Id Type
/dev/sdb1 2048 273436671 273434624 130.4G fd Linux raid autodetect
/dev/sdb2 273436672 291502079 18065408 8.6G fd Linux raid autodetect
Your disk is 235G, but the partition is only 130G large and mdadm only sees those 130G.
So you'd have to grow the partition, but there's your next problem, another partition is already there and in the way. So you have to move the 2nd partition away first before you can grow the 1st partition. Another option would be to create a new, 3rd partition and a new RAID on top and use them separately.
If that 8G RAID happens to be swap space, you could also disable swap temporarily, stop the swap RAID, delete those partitions and then grow/re-create as you see fit. Unlike user data, swap can be discarded and re-created on a whim, without a migration step.
answered Jan 5 at 16:01
frostschutzfrostschutz
26.3k15282
26.3k15282
Thanks! So, I need to delete sda2 and sdb2 (yes, it's swap). How to I do all that exactly? Can you help me with the command please?
– user1443462
Jan 5 at 19:21
add a comment |
Thanks! So, I need to delete sda2 and sdb2 (yes, it's swap). How to I do all that exactly? Can you help me with the command please?
– user1443462
Jan 5 at 19:21
Thanks! So, I need to delete sda2 and sdb2 (yes, it's swap). How to I do all that exactly? Can you help me with the command please?
– user1443462
Jan 5 at 19:21
Thanks! So, I need to delete sda2 and sdb2 (yes, it's swap). How to I do all that exactly? Can you help me with the command please?
– user1443462
Jan 5 at 19:21
add a comment |
So, if somebody need it. I found working way. I used systemrescuecd.
First step it to remove sda1/2 from RAID1:
mdadm /dev/md0 --fail /dev/sda1
mdadm /dev/md1 --fail /dev/sda2
mdadm /dev/md0 --remove /dev/sda1
mdadm /dev/md1 --remove /dev/sda2
After I removed /dev/sda2 in Gparted (via systemrescuecd)
Removed labels "boot" and "raid" from SDA1 in Gparted
Then, in the command line:
Parted /dev/sda
resizepart
1
245000
quit
Created sda2 in Gparted linux-swap.
mdadm --add /dev/md0 /dev/sda1
mdadm --add /dev/md1 /dev/sda2
Same thing for sdb1/2.
After:
e2fsck -f /dev/sda1
e2fsck -f /dev/sdb1
And:
mdadm --grow --size max /dev/md0
Then I used "check" for md0 in GParted.
Done. Works fine.
add a comment |
So, if somebody need it. I found working way. I used systemrescuecd.
First step it to remove sda1/2 from RAID1:
mdadm /dev/md0 --fail /dev/sda1
mdadm /dev/md1 --fail /dev/sda2
mdadm /dev/md0 --remove /dev/sda1
mdadm /dev/md1 --remove /dev/sda2
After I removed /dev/sda2 in Gparted (via systemrescuecd)
Removed labels "boot" and "raid" from SDA1 in Gparted
Then, in the command line:
Parted /dev/sda
resizepart
1
245000
quit
Created sda2 in Gparted linux-swap.
mdadm --add /dev/md0 /dev/sda1
mdadm --add /dev/md1 /dev/sda2
Same thing for sdb1/2.
After:
e2fsck -f /dev/sda1
e2fsck -f /dev/sdb1
And:
mdadm --grow --size max /dev/md0
Then I used "check" for md0 in GParted.
Done. Works fine.
add a comment |
So, if somebody need it. I found working way. I used systemrescuecd.
First step it to remove sda1/2 from RAID1:
mdadm /dev/md0 --fail /dev/sda1
mdadm /dev/md1 --fail /dev/sda2
mdadm /dev/md0 --remove /dev/sda1
mdadm /dev/md1 --remove /dev/sda2
After I removed /dev/sda2 in Gparted (via systemrescuecd)
Removed labels "boot" and "raid" from SDA1 in Gparted
Then, in the command line:
Parted /dev/sda
resizepart
1
245000
quit
Created sda2 in Gparted linux-swap.
mdadm --add /dev/md0 /dev/sda1
mdadm --add /dev/md1 /dev/sda2
Same thing for sdb1/2.
After:
e2fsck -f /dev/sda1
e2fsck -f /dev/sdb1
And:
mdadm --grow --size max /dev/md0
Then I used "check" for md0 in GParted.
Done. Works fine.
So, if somebody need it. I found working way. I used systemrescuecd.
First step it to remove sda1/2 from RAID1:
mdadm /dev/md0 --fail /dev/sda1
mdadm /dev/md1 --fail /dev/sda2
mdadm /dev/md0 --remove /dev/sda1
mdadm /dev/md1 --remove /dev/sda2
After I removed /dev/sda2 in Gparted (via systemrescuecd)
Removed labels "boot" and "raid" from SDA1 in Gparted
Then, in the command line:
Parted /dev/sda
resizepart
1
245000
quit
Created sda2 in Gparted linux-swap.
mdadm --add /dev/md0 /dev/sda1
mdadm --add /dev/md1 /dev/sda2
Same thing for sdb1/2.
After:
e2fsck -f /dev/sda1
e2fsck -f /dev/sdb1
And:
mdadm --grow --size max /dev/md0
Then I used "check" for md0 in GParted.
Done. Works fine.
answered Jan 5 at 22:29
user1443462user1443462
61
61
add a comment |
add a comment |
Thanks for contributing an answer to Unix & Linux Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f492672%2fhow-to-resize-linux-partition-with-raid1%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown