[Parted-maintainers] Bug#981692: Try to use the gain value and set it to 512 (one sector) instead of default 1MiB. Its a bug in sfdisk BTW.

Eric Valette eric.valette at free.fr
Wed Feb 3 21:31:31 GMT 2021


On 03/02/2021 20:22, Phillip Susi wrote:
> 
> Eric Valette writes:
> 
>> Its and very old SSD that has been partitionned at time where thedefault
>> 1MiB space limit between partition was was no there. Apart that I did
>> partition probably usinf cfisk at that time.
>>
>> What is strange is that in my case sfdisk -V reports no error and the
>> partitions are correctly detected so the EBR are obviously stored...
> 
> It is theretically possible to say, store multipe EBRs in the start of
> the extended partition before the first logical partition, then have no
> space between each logical partition, but parted does not support this.

Well at some point in time it did because I remember merging / and /usr 
using gparted on a PartedMagic iso Image... Or I did chnage 
partitionning after that (windows update for major relaease tend to 
corrupt partitions on several of my dual boot PCs...

> It requires the EBR to be between the previous partition and the next,
> so there must be at least one unused sector between them. 

Well, if you want to change something and thus write sectors why not, 
here I cannot even see my partitions.


> I have seen
> reports over the years of people running into disks built this way but
> never been able to figure out how they got that way.

Using cfdisk probably when there was no such imposed gap beween partitions.

>> I guess that it happens that the default size for sfdisk "grain" value
>> (see man sfdisk) has chnaged from one sector to one MiB. I created the
>> following output. see the gain value below.
> 
> I still get an error:
> 
> img6: /dev/sdb6 : start=   158203904, size=     9762816, type=83
> Start sector 158203904 out of range.
> Failed to add #6 partition: Numerical result out of range

Tried on my side on an empty disk : same result...

Pfff I have no clue how I could even convert this to something correct now.

-- eric



More information about the Parted-maintainers mailing list