Public bug reported:

Trying to restore a GPT partition table using a dump sfdisk previously
created from a larger disk to a smaller one (but has enough room for the
partitions) fails.  I'm using the --force option to try to make this
work.  It doesn't.  The first line of the output (with added blank lines
for readability) is

GPT PMBR size mismatch (494403583 != 234441647) will be corrected by
write.

this ought to be reassuring, but then I get

Last LBA specified by script is out of range.

Last LBA specified by script is out of range.

Last LBA specified by script is out of range.

Failed to apply script headers, disk label not created.

Leaving.

And there was then a crippled disk label that I had to erase (wipefs) before I 
could try again.  What actually worked for me was editing the output from 
--dump to remove the line with "last-lba".  Then it worked without even the 
warnings.
 
I would suggest some fixes: (1) don't say it will be corrected if you're not 
going to finish, (2) don't write a label -- corrupted or not -- if you say 
"label not created", and (3) make the --force option override all of that and 
make it work.

ProblemType: Bug
DistroRelease: Ubuntu 20.04
Package: fdisk 2.34-0.1ubuntu9.1
ProcVersionSignature: Ubuntu 5.4.0-62.70-generic 5.4.78
Uname: Linux 5.4.0-62-generic x86_64
ApportVersion: 2.20.11-0ubuntu27.14
Architecture: amd64
CasperMD5CheckResult: skip
Date: Tue Feb 23 10:45:04 2021
InstallationDate: Installed on 2020-07-12 (225 days ago)
InstallationMedia: Xubuntu 20.04 LTS "Focal Fossa" - Release amd64 (20200423)
SourcePackage: util-linux
UpgradeStatus: No upgrade log present (probably fresh install)

** Affects: util-linux (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: amd64 apport-bug focal

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to util-linux in Ubuntu.
https://bugs.launchpad.net/bugs/1916645

Title:
  sfdisk --force says it can correct a size mismatch, but then fails.

Status in util-linux package in Ubuntu:
  New

Bug description:
  Trying to restore a GPT partition table using a dump sfdisk previously
  created from a larger disk to a smaller one (but has enough room for
  the partitions) fails.  I'm using the --force option to try to make
  this work.  It doesn't.  The first line of the output (with added
  blank lines for readability) is

  GPT PMBR size mismatch (494403583 != 234441647) will be corrected by
  write.

  this ought to be reassuring, but then I get

  Last LBA specified by script is out of range.

  Last LBA specified by script is out of range.

  Last LBA specified by script is out of range.

  Failed to apply script headers, disk label not created.

  Leaving.

  And there was then a crippled disk label that I had to erase (wipefs) before 
I could try again.  What actually worked for me was editing the output from 
--dump to remove the line with "last-lba".  Then it worked without even the 
warnings.
   
  I would suggest some fixes: (1) don't say it will be corrected if you're not 
going to finish, (2) don't write a label -- corrupted or not -- if you say 
"label not created", and (3) make the --force option override all of that and 
make it work.

  ProblemType: Bug
  DistroRelease: Ubuntu 20.04
  Package: fdisk 2.34-0.1ubuntu9.1
  ProcVersionSignature: Ubuntu 5.4.0-62.70-generic 5.4.78
  Uname: Linux 5.4.0-62-generic x86_64
  ApportVersion: 2.20.11-0ubuntu27.14
  Architecture: amd64
  CasperMD5CheckResult: skip
  Date: Tue Feb 23 10:45:04 2021
  InstallationDate: Installed on 2020-07-12 (225 days ago)
  InstallationMedia: Xubuntu 20.04 LTS "Focal Fossa" - Release amd64 (20200423)
  SourcePackage: util-linux
  UpgradeStatus: No upgrade log present (probably fresh install)

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/util-linux/+bug/1916645/+subscriptions

-- 
Mailing list: https://launchpad.net/~touch-packages
Post to     : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp

Reply via email to