Trying to resize two disk partitions  [Solved]

Message
Author
User avatar
fehlix
Developer
Posts: 12604
Joined: Wed Apr 11, 2018 5:09 pm

Re: Trying to resize two disk partitions

#11 Post by fehlix »

Falcon wrote: Tue Apr 29, 2025 6:06 pm Well, that didn't work so good. I set up Gparted with the operations above, and then clicked the Execute button. The first two operations completed successfully, but when the Resize operation for the Windows partition started, it generated an error. The message window only stated that there was an error, but no indication as to what the error was. I'm guessing that for some reason the partition is being blocked from moving into the unallocated space. I had deleted both the MX logical partition and the extended partition so that the unallocated space should be completely clear. I guess that I will need a brain bigger than mine to fix this one.
OK, lessons learnt. For safety reasons: Never "touch" a Window partition from linux, to resize. Do this from within Windows tools, which is proven to be safe.
Now, try to boot into Windows with help of MX LiveUSB -> LiveBootMenu-> Switch to Grub -> Boot Rescue, and search for -> Windows bootloader.
It should find, a windows loader, which when selected might boot to WIndows and it may offer to try to repair the files system.

User avatar
Falcon
Posts: 460
Joined: Mon Apr 22, 2019 9:34 pm

Re: Trying to resize two disk partitions

#12 Post by Falcon »

Thanks, Fehlix. I'll give this a try tomorrow.

User avatar
Falcon
Posts: 460
Joined: Mon Apr 22, 2019 9:34 pm

Re: Trying to resize two disk partitions

#13 Post by Falcon »

Fehlix,

Before I get started on this I should ask a couple of questions, since I've never used the Windows disk management tools.

1) Since I've used Gparted to delete the MX logical drive and the extended partition, I'm assuming that when I look at the available space on the disk, it should appear that the entire disk is available.

2) After expanding the Windows partition I will need to create a new partition for MX. I'm assuming that I should use the Windows tools to create this partition, also. Should I make the new partition a Primary partition or an Extended partition?

3) Once I've finished with the above work, should I then go back and use Gparted to format the new partition to ext4, and then go ahead and use the Live-USB to reinstall MX?

User avatar
fehlix
Developer
Posts: 12604
Joined: Wed Apr 11, 2018 5:09 pm

Re: Trying to resize two disk partitions

#14 Post by fehlix »

Falcon wrote: Wed Apr 30, 2025 8:17 am Fehlix,

Before I get started on this I should ask a couple of questions, since I've never used the Windows disk management tools.

1) Since I've used Gparted to delete the MX logical drive and the extended partition, I'm assuming that when I look at the available space on the disk, it should appear that the entire disk is available.

2) After expanding the Windows partition I will need to create a new partition for MX. I'm assuming that I should use the Windows tools to create this partition, also. Should I make the new partition a Primary partition or an Extended partition?

3) Once I've finished with the above work, should I then go back and use Gparted to format the new partition to ext4, and then go ahead and use the Live-USB to reinstall MX?
First, hurtle, would be to figure out, whether the file system is still in a shape to allow find the windows boot loaded, and that it boots.
Not the entire disk, but the empty part of the disk will be shown within Windows disk manager tool as unused space, so you can increase the windows partition to your liking.
You can create a new partition within Windows, and later reformat in Gparted.
But I do normal just leave empty space, and create with Gparted new partitions with this empty space,
this avoids Windows complains next boot about a missing partition.
Also note: When shutting down Windows, do a "full shutdown" e.g by holding the Shift-Key when clicking on Shutdown ( or disable permanently hyber/fast-boot in windows)

User avatar
Falcon
Posts: 460
Joined: Mon Apr 22, 2019 9:34 pm

Re: Trying to resize two disk partitions

#15 Post by Falcon »

Okay, to recap:

1) Use the Windows tools to expand the Windows partition.

2) Insure that fast boot is not set up. I've never set up this feature myself, but I'll make sure that it wasn't set up this way by Acer.

3) Use Gparted to create an new partition for Linux in the unallocated space and then re-install MX from the Live-USB.

4) I also wanted to ask if the new partition for MX should be a Primary or Extended partition, or does is really make any difference?

User avatar
j2mcgreg
Global Moderator
Posts: 6559
Joined: Tue Oct 23, 2007 12:04 pm

Re: Trying to resize two disk partitions

#16 Post by j2mcgreg »

Falcon wrote: Wed Apr 30, 2025 9:13 am Okay, to recap:

1) Use the Windows tools to expand the Windows partition.

2) Insure that fast boot is not set up. I've never set up this feature myself, but I'll make sure that it wasn't set up this way by Acer.

3) Use Gparted to create an new partition for Linux in the unallocated space and then re-install MX from the Live-USB.

4) I also wanted to ask if the new partition for MX should be a Primary or Extended partition, or does is really make any difference?
With <= Windows 8.1, Fast Start Up was a bios control called Quick Start. However, I don't remember it ever being present in Win 7 machines.
HP 15; ryzen 3 5300U APU; 500 Gb SSD; 8GB ram
HP 17; ryzen 3 3200; 500 GB SSD; 12 GB ram
Idea Center 3; 12 gen i5; 256 GB ssd;

In Linux, newer isn't always better. The best solution is the one that works.

User avatar
fehlix
Developer
Posts: 12604
Joined: Wed Apr 11, 2018 5:09 pm

Re: Trying to resize two disk partitions

#17 Post by fehlix »

Falcon wrote: Wed Apr 30, 2025 9:13 am 1) Use the Windows tools to expand the Windows partition.
Maybe called diskmgr.cfg (or similar, or search windows menu..)
Falcon wrote: Wed Apr 30, 2025 9:13 am 2) Insure that fast boot is not set up. I've never set up this feature myself, but I'll make sure that it wasn't set up this way by Acer.
That's a Windows feature enabled by default. Just hold the Shift when clicking on Poweroff in Windows.
Falcon wrote: Wed Apr 30, 2025 9:13 am 3) Use Gparted to create an new partition for Linux in the unallocated space and then re-install MX from the Live-USB.

4) I also wanted to ask if the new partition for MX should be a Primary or Extended partition, or does is really make any difference?
You can have max 4 primaries. So in case you want to adjust (e.g add a swap or data partition), may be consider
to add an extended partition (as the 4th primary) and fill the extended partition with real partitions like MX-root etc.
But remember you cant move the "start" of the extented partions without creating trouble, so better think about your space usage.
Within the extended partition, you can add more logical/secondary partitions.

User avatar
DukeComposed
Posts: 1291
Joined: Thu Mar 16, 2023 1:57 pm

Re: Trying to resize two disk partitions

#18 Post by DukeComposed »

fehlix wrote: Wed Apr 30, 2025 10:00 am
Falcon wrote: Wed Apr 30, 2025 9:13 am 1) Use the Windows tools to expand the Windows partition.
Maybe called diskmgr.cfg (or similar, or search windows menu..)
Try diskmgmt.msc.

User avatar
Falcon
Posts: 460
Joined: Mon Apr 22, 2019 9:34 pm

Re: Trying to resize two disk partitions

#19 Post by Falcon »

Here is what I've done so far:

I booted from the Live USB and selected the Boot Repair option. Going through the menus, I found the Windows boot loader and it allowed me to start Windows successfully. I shut down using the Shift-Shutdown procedure. Then I Went through the above process again and started Windows once more.

First, I opened Windows Explorer and ran a Check Disk operation without any of the repair options. The scan operation did not report any errors, so when Gparted reported sector errors, it may have been erroneous.

I used the diskmgmt.msc command and that started the program to allow me to resize the Windows partition. That operation seemed to complete successfully.

I shutdown using the Shift-Shutdown and then restarted again and used Windows Explorer to check to see if it reflected the new partition size, and it did.

I shut down and then restarted with the Live-USB, then ran Gparted to create the new Extended partition and the new Logical partition for MX. I also formatted the partition for ext4.

Then I went back to the desktop to run the Installer and put MX on the new partition. Everything seemed to go alright until the installation of GRUB started about 93% of the way in. I got a message that the installation of GRUB failed and that I could use Boot Repair to fix it. So I aborted the installation and opened MX Tools and selected.Boot Repair. Then I ran Reinstall GRUB. I got the following error message:

Code: Select all

Installing for i386-pc platform.
grub-install: error: cannot copy `/usr/share/locale/sr.gmo' to `/boot/grub/locale/sr.mo': Is a directory.
Then I ran the Repair GRUB Configuration File operation and it seemed to complete successfully with the following output:

Code: Select all

Generating grub configuration file ...
Found theme: /boot/grub/themes/mx_linux/theme.txt
Found linux image: /boot/vmlinuz-6.2.14-1-liquorix-amd64
Found initrd image: /boot/initrd.img-6.2.14-1-liquorix-amd64
Found linux image: /boot/vmlinuz-5.10.0-34-amd64
Found initrd image: /boot/initrd.img-5.10.0-34-amd64
Found memtest86+ image: /boot/memtest86+.bin
Found Windows Recovery Environment on /dev/sda1
Found Windows 7 on /dev/sda2
done
I tried rebooting normally, i.e., not from the Live-USB. but the reboot failed. How do I proceed from here? Thanks for all of the help, so far.

User avatar
fehlix
Developer
Posts: 12604
Joined: Wed Apr 11, 2018 5:09 pm

Re: Trying to resize two disk partitions

#20 Post by fehlix »

Falcon wrote: Thu May 01, 2025 1:39 pm

Code: Select all

Installing for i386-pc platform.
grub-install: error: cannot copy `/usr/share/locale/sr.gmo' to `/boot/grub/locale/sr.mo': Is a directory.
Not sure about this error.
But:
Falcon wrote: Thu May 01, 2025 1:39 pm Then I ran the Repair GRUB Configuration File operation and it seemed to complete successfully with the following output:

Code: Select all

Generating grub configuration file ...
Found theme: /boot/grub/themes/mx_linux/theme.txt
Found linux image: /boot/vmlinuz-6.2.14-1-liquorix-amd64
Found initrd image: /boot/initrd.img-6.2.14-1-liquorix-amd64
Found linux image: /boot/vmlinuz-5.10.0-34-amd64
Found initrd image: /boot/initrd.img-5.10.0-34-amd64
Found memtest86+ image: /boot/memtest86+.bin
Found Windows Recovery Environment on /dev/sda1
Found Windows 7 on /dev/sda2
done
I tried rebooting normally, i.e., not from the Live-USB. but the reboot failed. How do I proceed from here? Thanks for all of the help, so far.
You would want to run also the "grub-install " part, to "install" the grub-boot loader into the MBR.
Only with a valid GRUB-loader within the MBR, the grub-config can be loaded.
So Try first again with "MX Boot Repai" to "install grub" into the MBR again.
The grub,cfg is probaly already ok, but wouldn't hurt to rerun.
But make sure you select the correct target drive sda or sdb of the internal drive, b/c with LiveUSB you may now have sda is LiveUSB and what a sda was is now sdb.
The kernels assign the names at boot, depending how the LiveUSB is connect you might get different names on LiveBoot.
IF still failed, boot into the LiveSystem and open "Change root" rescue.
Select the found installtion.
on "chroot>" check the namse with

Code: Select all

lsblk 
or

Code: Select all

lsblk -f
and run

Code: Select all

grub-install /dev/sdX
where sdX is the device name of the internal drive, you want to boot from.

Post Reply

Return to “Software / Configuration”