You are not logged in.

#1 2024-02-25 21:39:09

lenhuppe
Member
From: New Hampshire USA
Registered: 2018-12-10
Posts: 273
Website

SOLVED sgdisk fails to create partition

During a test run of my recovery system, sgdisk errorred saying in effect:

couild not create partition 2 from ...  
could not change partition 2's type code to 8300

The code is question is here:

for drv in "${disk1}" "${disk2}" ; do
	nvme format -f "${drv}" --ses=1
	parted "${drv}" mklabel gpt
	sgdisk -n 1:2M:+1G -t 1:EF00 "${drv}"
	sgdisk -n 2:0M:-0M -t 2:8300 "${drv}"
	partprobe -s "${drv}"
done

This code has been working for some time now.
When I reverted to an earlier ISO it ran without any issues.

I tried writing the new ISO file to a different USB and got the same.
I tried recreating the new ISO and using a new USB and got the same.
I trued using the LTS kernel instead of ZEN and got the same. 

When I checked the archives I found that gptfdisk was updated on Feb 20th.

Not sure how to procede.

Last edited by lenhuppe (2024-02-27 03:09:16)


Why do we drive on the parkway and then park in the driveway?

Offline

#2 2024-02-27 03:08:43

lenhuppe
Member
From: New Hampshire USA
Registered: 2018-12-10
Posts: 273
Website

Re: SOLVED sgdisk fails to create partition

Solution:

After confirming that the recently updated sgdisk does not work in my script, I switched to using gparted instead.

Last edited by lenhuppe (2024-02-27 10:08:17)


Why do we drive on the parkway and then park in the driveway?

Offline

Board footer

Powered by FluxBB