Move the windows partition to the right of root and home partition

I have a 1TB hdd used to dualboot windows and manjaro.
The windows partition is located near the beginning of the disk.
I want to move this partition to a position after the home partition.
I started by cloning the windows partition (/dev/sda3) to the correct position and now I have two windows partitions (/dev/sda3 and /dev/sda8).

How to make windows boot from the newly created partition (/dev/sda8)?

Changing partition layout this way you may render the system unbootable.


  1. Extracting the partition guid from sda3.
  2. Write a new random guid to sda3
  3. Write the extracted Guid the sda8 partition.

Please rethink the steps - understand what it does - elevate your permissions - commands must be executed in correct context.

See man sgdisk

This may work - or it may not

Please check the output of efibootmgr before making any changes.

I accept no complaints and assume no responsibility if you make any errors - resulting in an unbootable system - not even if it is a typo of mine.

First: extract the guid from sda3

WINPARTGUID=$(lsblk -no uuid /dev/sda3)

Second: write a new random guid to the third partition on sda

sgdisk --partition-guid=3:R /dev/sda

Third: use sgdisk to write the extracted guid to 8th partition

sudo sgdisk --partition-guid=8:$(WINPARTGUID}

Thank you very much! I will not complain at all. I will take my time before and I will report the result. Thank you!


BootCurrent: 0016
Timeout: 0 seconds
BootOrder: 0016,0014,000F,000A,0012,0013,0010,000C,000D,000E,0000,0001,0002,0003,0004,0005,0006,0007,0008,0009,0011,0015
Boot0000  Startup Menu  FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)0000000049535048
Boot0001  System Information    FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)f1000000000049535048
Boot0002  Bios Setup    FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)100f0000000049535048
Boot0003  3rd Party Option ROM Management       FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)f3000000000049535048
Boot0004  System Diagnostics    FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)f2000000000049535048
Boot0005  System Diagnostics    FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)01f20000000049535048
Boot0006  System Diagnostics    FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)02f20000000049535048
Boot0007  System Diagnostics    FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)03f20000000049535048
Boot0008  Boot Menu     FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)f9000000000049535048
Boot0009  HP Recovery   FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)110f0000000049535048
Boot000A* hp DVDRW GUD1N        PciRoot(0x0)/Pci(0x17,0x0)/Sata(1,0,0)4eac0881119f594d850ee21a522c59b20800000049535048
Boot000C* ST1000LM024 HN-M101MBB :      BBS(HD,ST1000LM024 HN-M101MBB : ,0x400)/PciRoot(0x0)/Pci(0x17,0x0)/Sata(0,0,0)01001000000049535048
Boot000D* hp DVDRW GUD1N :      BBS(CDROM,hp DVDRW GUD1N : ,0x400)/PciRoot(0x0)/Pci(0x17,0x0)/Sata(1,0,0)02000800000049535048
Boot000E* Intel Corporation: Realtek PXE B02 D00        BBS(Network,Intel Corporation: Realtek PXE B02 D00,0x0)/PciRoot(0x0)/Pci(0x1c,0x4)/Pci(0x0,0x0)15001000000049535048
Boot000F  USB:          PciRoot(0x0)/Pci(0x14,0x0)4eac0881119f594d850ee21a522c59b20b80000049535048
Boot0010  USB:          BBS(65535,,0x0)/PciRoot(0x0)/Pci(0x14,0x0)ffff0b80000049535048
Boot0011  Network Boot  FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)120f0000000049535048
Boot0012* IPV6 Network - Realtek PCIe GBE Family Controller     PciRoot(0x0)/Pci(0x1c,0x4)/Pci(0x0,0x0)/MAC(705a0f1878f0,0)/IPv6([::]:<->[::]:,0,0)4eac0881119f594d850ee21a522c59b20000000049535048
Boot0013* IPV4 Network - Realtek PCIe GBE Family Controller     PciRoot(0x0)/Pci(0x1c,0x4)/Pci(0x0,0x0)/MAC(705a0f1878f0,0)/IPv4(,0,0)4eac0881119f594d850ee21a522c59b20000000049535048
Boot0014* Windows Boot Manager  HD(1,GPT,8f5e014b-6dd9-4248-80f9-4b49b841879b,0x800,0xb4000)/File(\EFI\Microsoft\Boot\bootmgfw.efi)57494e444f5753000100000088000000780000004200430044004f0042004a004500430054003d007b00390064006500610038003600320063002d0035006300640064002d0034006500370030002d0061006300630031002d006600330032006200330034003400640034003700390035007d000000605f0100000010000000040000007fff04001400000049535048
Boot0015  Gestion tierce de la ROM optionnelle  FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)f3000000000049535048
Boot0016* manjaro       HD(1,GPT,8f5e014b-6dd9-4248-80f9-4b49b841879b,0x800,0xb4000)/File(\EFI\manjaro\grubx64.efi)

I have a little doubt!
WINPARTGUID=$(lsblk -no partuuid /dev/sda3) instead??

compare with your fstab and you will see that uuid is the one used for mouting a partition

lsblk -o path,uuid,partuuid

I don’t know about windows - which is why I suggested to use the output of efibootmgr as reference to ensure you are using the expected data.

I wouldn’t do what you are attempting but - it’s your system - if you are confident … who am I to advise otherwise.

How can we see that

uuid is the one used for mounting a partition

I have posted the output of efibootmgr but I don’t know what to look at ?

The steps are almost as suggested by:

The difference being replacing in step 1

WINPARTGUID=$(lsblk -no uuid /dev/sda3)


WINPARTGUID=$(lsblk -no partuuid /dev/sda3)

And after removing the old windows partition (/dev/sda3) I had to restore grub

This topic was automatically closed 36 hours after the last reply. New replies are no longer allowed.