Resizing the linux partition

Questions about Grub, UEFI,the liveCD and the installer
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
townsbg
Level 1
Level 1
Posts: 30
Joined: Tue Dec 03, 2019 10:40 pm

Resizing the linux partition

Post by townsbg »

What is the easiest way to resize the linux partition? I mirrored the install to a larger hard drive and it did an exact copy without allotting the additional space.
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
User avatar
AndyMH
Level 21
Level 21
Posts: 13583
Joined: Fri Mar 04, 2016 5:23 pm
Location: Wiltshire

Re: Resizing the linux partition

Post by AndyMH »

Boot your mint install stick and run gparted from that. You cannot resize your / partition booting normally - it is in use and cannot be unmounted.
Thinkcentre M720Q - LM21.3 cinnamon, 4 x T430 - LM21.3 cinnamon, Homebrew desktop i5-8400+GTX1080 Cinnamon 19.0
townsbg
Level 1
Level 1
Posts: 30
Joined: Tue Dec 03, 2019 10:40 pm

Re: Resizing the linux partition

Post by townsbg »

I tried resizing from a bootable gparted but I don't have the option of resizing. When trying from the command line I get the error message "Couldn't find valid filesystem superblock." I took a pic but it isn't very good but you can see the hard drive properties. Does it matter than the drive is encrypted? If so how do I decrypt it?
Last edited by townsbg on Fri Dec 10, 2021 1:43 am, edited 1 time in total.
User avatar
AndyMH
Level 21
Level 21
Posts: 13583
Joined: Fri Mar 04, 2016 5:23 pm
Location: Wiltshire

Re: Resizing the linux partition

Post by AndyMH »

I don't use full disk encryption, so can't help. Hopefully someone who does will be along.
Thinkcentre M720Q - LM21.3 cinnamon, 4 x T430 - LM21.3 cinnamon, Homebrew desktop i5-8400+GTX1080 Cinnamon 19.0
Menard
Level 7
Level 7
Posts: 1730
Joined: Wed May 08, 2019 5:14 am
Location: Angers (France)

Re: Resizing the linux partition

Post by Menard »

What I know is that Gparted Live is a bad tool except on a recent Linux? Gparted live is on a too old Linux
so it is possible that what you tried with it, would work from it in a recent Linux Mint Live
Linux Mint 20.3 Cinnamon - K 5.15 - Desktop - english
AMD APU A8 7600 - DDR3 1833 MHz 8 GB x2 Dual Channel
--

If you think tough men are dangerous, wait until you see what weak men are capable of.
townsbg
Level 1
Level 1
Posts: 30
Joined: Tue Dec 03, 2019 10:40 pm

Re: Resizing the linux partition

Post by townsbg »

I've tried with the install disk and I am running into the same problem. So does the drive have to be decrypted and if so how do I do that?
Rooo
Level 2
Level 2
Posts: 52
Joined: Sun Nov 21, 2021 9:00 am

Re: Resizing the linux partition

Post by Rooo »

i resized my mint partition last week using a Ventoy usb pendrive (boots .iso`s easily)

https://www.ventoy.net/en/index.html

i have a few recovery .iso`s on ... i used Hirens to resize my windows partition first,rebooted to make sure the changes were recognised (and win would still boot :D) ... booted back into hirens then resized my mint partition (only my home folder is encrypted) using the free space stolen from the win partition


its still working :D
Forum Pest ...

"Easy tips for Linux Mint and Ubuntu, both for beginners and for advanced users" https://easylinuxtipsproject.blogspot.com/p/1.html
Menard
Level 7
Level 7
Posts: 1730
Joined: Wed May 08, 2019 5:14 am
Location: Angers (France)

Re: Resizing the linux partition

Post by Menard »

But what did you use to resize the Mint partition ? GParted ?
Linux Mint 20.3 Cinnamon - K 5.15 - Desktop - english
AMD APU A8 7600 - DDR3 1833 MHz 8 GB x2 Dual Channel
--

If you think tough men are dangerous, wait until you see what weak men are capable of.
townsbg
Level 1
Level 1
Posts: 30
Joined: Tue Dec 03, 2019 10:40 pm

Re: Resizing the linux partition

Post by townsbg »

i tried with gparted and the command line.
townsbg
Level 1
Level 1
Posts: 30
Joined: Tue Dec 03, 2019 10:40 pm

Re: Resizing the linux partition

Post by townsbg »

Does anyone have anything?
SimonPeter
Level 5
Level 5
Posts: 582
Joined: Tue Jul 13, 2021 5:13 am

Re: Resizing the linux partition

Post by SimonPeter »

townsbg wrote: Sat Dec 04, 2021 1:44 am Does anyone have anything?
This is how I resize LUKS partitions:
1) BACKUP ALL IMPORTANT DATA ON THAT DISK.
2) Launch GParted from the Linux Mint installation medium (NOT from GParted live).
3) Resize the LUKS partition to the right (if you want to resize it to the left, you have to move it to the left, then resize to the right), then apply changes.
4) sudo cryptsetup luksOpen /dev/sdXY luks_part
5) sudo gparted /dev/mapper/luks_part
6) Right-click on the only LUKS volume, then choose "Check" and apply changes.
Rooo
Level 2
Level 2
Posts: 52
Joined: Sun Nov 21, 2021 9:00 am

Re: Resizing the linux partition

Post by Rooo »

Menard wrote: Wed Dec 01, 2021 6:30 am But what did you use to resize the Mint partition ? GParted ?
sorry for the late reply ... usually i go through the listed apps till one loads up im familiar with,and use that :)
Forum Pest ...

"Easy tips for Linux Mint and Ubuntu, both for beginners and for advanced users" https://easylinuxtipsproject.blogspot.com/p/1.html
townsbg
Level 1
Level 1
Posts: 30
Joined: Tue Dec 03, 2019 10:40 pm

Re: Resizing the linux partition

Post by townsbg »

SimonPeter wrote: Sat Dec 04, 2021 2:15 am
townsbg wrote: Sat Dec 04, 2021 1:44 am Does anyone have anything?
This is how I resize LUKS partitions:
1) BACKUP ALL IMPORTANT DATA ON THAT DISK.
2) Launch GParted from the Linux Mint installation medium (NOT from GParted live).
3) Resize the LUKS partition to the right (if you want to resize it to the left, you have to move it to the left, then resize to the right), then apply changes.
4) sudo cryptsetup luksOpen /dev/sdXY luks_part
5) sudo gparted /dev/mapper/luks_part
6) Right-click on the only LUKS volume, then choose "Check" and apply changes.
Install is a mirror from another drive and I stall have that drive so backup isn't a problem. As stated I don't have the option of resizing from gparted but I'll try those commands later.
townsbg
Level 1
Level 1
Posts: 30
Joined: Tue Dec 03, 2019 10:40 pm

Re: Resizing the linux partition

Post by townsbg »

Those commands aren't working.
root@mint:~# sudo cryptsetup luksOpen /dev/sda5 luks_part
Enter passphrase for /dev/sda5:
root@mint:~# gparted /dev/mapper/luks_part
Unit boot.mount does not exist, proceeding anyway.
Unable to init server: Could not connect: Connection refused

(gpartedbin:2853): Gtk-WARNING **: 11:32:30.052: cannot open display:
Can someone answer if I need to disable encryption and if so how do I do so?
townsbg
Level 1
Level 1
Posts: 30
Joined: Tue Dec 03, 2019 10:40 pm

Re: Resizing the linux partition

Post by townsbg »

Can someone help? I don't know enough about linux to know where to go from here. I'm wondering if I mirrored incorrectly. I used macrium with the drives slaved to my desktop running Windows. Should I have done it a different way? How should I have mirrored the drive?
SimonPeter
Level 5
Level 5
Posts: 582
Joined: Tue Jul 13, 2021 5:13 am

Re: Resizing the linux partition

Post by SimonPeter »

townsbg wrote: Tue Nov 30, 2021 3:46 pm I tried resizing from a bootable gparted but I don't have the option of resizing. When trying from the command line I get the error message "Couldn't find valid filesystem superblock." I took a pic but it isn't very good but you can see the hard drive properties. Does it matter than the drive is encrypted? If so how do I decrypt it?

IMG_3577.JPG
I think you can leave that partition untouched.
Your partition is ~300GB and you want to resize it to get ~30GB more (you may ignore that ~30GB increase).
townsbg
Level 1
Level 1
Posts: 30
Joined: Tue Dec 03, 2019 10:40 pm

Re: Resizing the linux partition

Post by townsbg »

You don't have any other suggestions? Just ignore it? What about trying to decrypt it or maybe I mirrored it wrong and should us another method?
SimonPeter
Level 5
Level 5
Posts: 582
Joined: Tue Jul 13, 2021 5:13 am

Re: Resizing the linux partition

Post by SimonPeter »

townsbg wrote: Tue Dec 07, 2021 2:02 pm You don't have any other suggestions? Just ignore it? What about trying to decrypt it or maybe I mirrored it wrong and should us another method?
- You can create a new partition table on the new disk (deleting all data on it), reinstall Linux on it and copy over personal files from the old disk.
- You can clone the disk with Foxclone, GNU ddrescue, GNU dd etc.,
townsbg
Level 1
Level 1
Posts: 30
Joined: Tue Dec 03, 2019 10:40 pm

Re: Resizing the linux partition

Post by townsbg »

I am not reinstalling. Which method is the easiest to use clone it and how do i do it?
SimonPeter
Level 5
Level 5
Posts: 582
Joined: Tue Jul 13, 2021 5:13 am

Re: Resizing the linux partition

Post by SimonPeter »

Foxclone may be the easiest of these (foxclone, ddrescue and dd).
It is made by the well-respected forum member @AndyMH .

https://foxclone.com/ (Official website)
viewtopic.php?t=315557 ( @AndyMH talking about it on this forum )
Locked

Return to “Installation & Boot”