On Tuesday 09 May 2017, Bjoern Voigt wrote:
Carlos E. R. wrote:
On 2017-05-07 22:38, Wols Lists wrote:
On 07/05/17 20:00, Bjoern Voigt wrote:
Thanks. But it probably does not work. I called "z zap (destroy) GPT data structures and exit", re-created a MSDOS partition table and re-inserted the USB key (so that Linux scans the new partition table). But gdisk still complains about an invalid GPT:
mybox:~ # gdisk /dev/disk/by-id/usb-General_UDisk_1502050001210883950005-0:0 GPT fdisk (gdisk) version 1.0.1
Partition table scan: MBR: MBR only BSD: not present APM: not present GPT: not present
Where is it complaining about an *INVALID* GPT?
Just in the part you deleted from the post:
*************************************************************** Found invalid GPT and valid MBR;
I would say you have both MBR and GPT partition table. In this case MBR wins I would say, by means the operating system uses the MBR.
converting MBR to GPT format
in memory. THIS OPERATION IS POTENTIALLY DESTRUCTIVE! Exit by typing 'q' if you don't want to convert your MBR partitions to GPT format! ***************************************************************
"Found invalid GPT", it says.
I tried the test case from Ruediger Meier both with "wipefs" and with "gdisk". Both commands clean the GPT headers completely. The "Found invalid GPT" message does not appear later. So at least for the test case (no real USB key is used, but an big empty file) both commands work correctly. But "gdisk" (wipefs not tested) did not clean my GPT header on the real 8 GB big USB key.
Why not try wipefs?
I do not know the reason. On reason could be, that the GPT in the USB key is not created by "parted" or "gdisk", but created with imagewriter and the installation media
I guess originally there was a valid GPT table on that device. Then you used a tool which does *not* support GPT. Thus it created a conflicting MBR. Now gdisk and any other tools with GPT support will complain. Using gdisk you would have to repair the GPT table first and then remove it. But again, I think wipefs would clear both MBR and GPT regardless whether they are valid or not. cu, Rudi -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org