16

I have a dual-boot laptop with both Windows 10 and Ubuntu 16.04.

Currently, the Windows side has too much disk space, and I want to resize things so that the Ubuntu side has more.

Firstly, I went into the Windows disk management and shrunk the Windows partition by 20GB. I then wanted to expand the Ubuntu partition, but it seemed like this option was greyed out.

Can I expand the Linux partition from Windows or do I need to be in Ubuntu or do I need to create a boot disk and do it that way?

Or do I need third party software?

Any help gratefully received.


enter image description here

2
  • 1
    Do use Windows to resize NTFS partitions and reboot immediately so it can run chkdsk. If Windows 8 or 10 make sure fast start up is off, so Linux NTFS driver can mount partition and Linux tools correctly see the NTFS partition(s). Then use gparted for changing Linux partitions. Gparted may work to edit NTFS, but safer to use Windows tools. askubuntu.com/questions/343268/…
    – oldfred
    Sep 19, 2017 at 19:16
  • 3
    Possible duplicate of How to resize partitions?
    – Pilot6
    Sep 19, 2017 at 19:46

5 Answers 5

5

Below worked for me! Please check if this will work for your setup, I cannot guarantee anything.

I had a similar problem. having dual boot W10 and Cinnamon Mint, the diskspace for linux was fully used and I could not start up linux. I therefore had to enlarge the linux partition (EXT4) and reduce the W10-partition(NTFS) at the same time.

I am not an expert and found it a little scary, afraid of disabling both W10 and Cinnamon Mint.

I therfore started to make a backup of all my data on an external HD (data from both W10 and Linux). I made a recovery USB-stick for W10 (from within windows) and looked up how to repair a possibly corrputed GRUB2 form linux. This is because by changing partition sizes one may actually move complete parttitions on the drive and corrupt the startups from both W10 and linux.

Once done my next step was to shrink the W10-ntfs data partition (I had 2 main partitions, one containing the W10 operating system (Drive C:) and one containing the data (Drive D:)). I did this from within windows on the PC. After shrinking restart your PC and confirm windows works correctly and chek if the resize was succesful.

Next step was to create a GParted-iso startup USB stick. This is needed to resize the, non-mounted, linux parttition. Since I already had Linux installed on the PC that is what I needed. Alternatively you can create a Ubuntu live-USB Stick and run it from USB and open Gparted from Ubuntu (if Gparted is included, otherwise installl Gparted from within that live Ubuntu). In order to run the Gparted from USB stick, I needed to change some setings in the BIOS since the USB stick did not show up as boot option i the BIOS: I have a UEFI Bios and needed to disable Fastboot, enable CSM launch otherwise the option of booting from USB stick would not show under the "save&Exit"Tab. (I do not recall anymore if I had to disable secure boot, you may have to do that as well) .Choose the option to boot from the USB stick. Save and exit the BIOS. Please write down your original Bios settings since you have to change back to these once all resizing has been done.

put the Gparted USB stick in the PC and reboot into the BIOS. Choose the USB stick as 1st boot option, save and exit. The PC wil now start Gparted from the USB. within the Gparted program, expand the linux partition (ext4) to the size you need (I extended it with the newly created unallocated space from the W10 parttition shrinkage). save and exit GPparted and remove the USB Stick reboot into BIOS and put everything back to the original BIOS stettings and reboote.

Upon reboot it worked again, I received my usual screen otpion login with Linux or Windows 10 and both worked.

After all I did not need the recovery W10 stick, didn't need to repair the Linux GRUB2 and didn't need to put back my data from both W10 and linux, but hey, better be safe than sorry.

above worked for me! Please check if this will work for your setup, I cannot guarantee anything.

3

For your edited question:

I'd do like this:

Be prepared to reinstall ubuntu if anything wrong happens.

You don't need 15 GB of swap space. Take 300 MB from sda6 and combine it with unallocated 694 MB and make that partition swap.(1 GB) Combine balance sda6 (15.88GB (less) 300MB that you have taken in the above step) with sda5 (ubuntu partition) 15GB swap is a waste of space. When you boot to ubuntu, if you don't see the swap partition, reinstall ubuntu or check for any other solutions to force ubuntu to detect the modified swap.

If you combine the space you freed from windows c drive, you will mess up with the position of recovery partition, which might make it not possible to load recovery or diagnostic tools.

I have not tried modifying diagnostic or recovery partition. So I don't know about it. This article https://www.partitionwizard.com/partitionmagic/delete-recovery-partition.html says it is ok to delete recovery partition.

But if you take the swap space, you will get a lot of space for ubuntu. Decrease swappiness setting for better performance. It will force ubuntu to use more RAM and less swap.

2

Boot from the usb drive you made bootable to install ubuntu There is a software called gparted in it. If you can't find it, install it from the software centre. Open it and there you can resize partitions. Alternatively, You can download iso file of partition resizing tools like EaseUs , make a USB bootable with the ISO, and boot from it. You can also use Hiren's Boot CD iso. There is a partition manager in Hiren's Boot CD (without booting into mini windows xp mode). If you plan to use mini xp mode, scan and remove viruses from the iso using an antivirus before putting into USB.

If your partitions aren't near to each other, (say, you have a partition used to store movies in between your windows and linux partitions, use the unallocated free space to increase the space of the middle partition. Then shrink the middle partition to get free space on the other end of the middle partition. Then extend the space of ubuntu partition

1
  • Thank you. I have added an image in my question above. As you can see, there is 19.53GB of unallocated space. I want to add it to the sda5 partition (which I believe to be my Ubuntu partition). Could you tell me how to proceed? I have read other cases, but it's not entirely clear to me and I don't want to mess it up (I am backed up though). Sep 19, 2017 at 20:14
0

I came to this question seeking for the same answer and I am now writing from my Ubuntu 18.04 partition with 200gb more in it. In my case, I have on my pc an SSD and a HDD. Win10 OS installed in SSD and using also the HDD. That is my primary OS. I then dualbooted a few months later Ubuntu, only on HDD.

I followed this guide, which basically tells you the following:

  1. On Win10, shrink the volume of the drive (my case, shrink the hdd), in order to have X unallocated memory.
  2. Make a bootable usb with the system you want to increase (my case, Ubuntu 18.04), and launch it with Try Ubuntu. The reason for this is probably because this temporary Ubuntu system is not installed nor using the same part as the installed ubuntu.

2 things here: I used Easybcd on Windows to let me choose between those 2, so it was impossible for me to access bios mode in order to choose to start from a bootable device. After some panic and tries, instead of making a bootable device, I added on Easybcd (Win10) another entry with the iso file (copy paste, not burn it into it)(Ubuntu 18.04, the same one I used to make a bootable device to dualboot) on another usb (or the same, just format it, should work). And select that option on the menu selection when restarting.

  1. Go to GParted on the TryUbuntu system (I will call it like this for the sake of this answer). It should be installed already. Select the drive in which the DesiredToBeBigger(I will call it DTBB) Ubuntu system is installed (in my case, /dev/sdb. If you have a swap partition, go to swap off, and then resize the DTBB Ubuntu system (basically extending the unallocated). Some warnings, but let the operations do the job (apply operations, green tick). It should take some time. For me it was around 1-1:30h.

  2. I turned swap back on. Reboot. There you go.

SOME ASPECTS TO TAKE INTO ACCOUNT:

  1. On Easybcd, I deleted ubuntu's entry (just in case), so when rebooted, I started Win10, Easybcd, and added Ubuntu again (in my case, grub2 option on Easybcd. I forgot and put just grub, and scared the soul out of me when a black screen didn't turn into the beautiful ubuntu's purple. Turned off, on, Win10, add grub2 entry Ubuntu, fixed.
  2. It's ALWAYS recommended to make copies of the important files. I've been fighting with dualbooting problems (legacy bios here), for some time, so I kind of had trust in myself, but I got quite stressed. I definitely recommend to play on the safe side of the field and do the necessary back ups in case something goes wrong.
0

I had the exact same problem and I was looking through the internet to find a valid solution. After all what I did was the following:

I booted windows and used a disk management tool (without paying anything) to move my unallocated space to the right. So in the above image we need to move the unallocated to the right of the linux partition. Then we have to wait a bit for the process to be applied.

Then you open ubuntu and go to Disks you press on the Linux partition and then resize. You will be allowed to resize and get the previous unallocated space.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .