I face a big problem here…
I created a USB Live stick with ImageWriter program to install opensuse 12.1 KDE to my PC…
All good I did the installation but now I cannot make my USB stick the way it was before the usage of imagewriter!!
When I plug it on the PC it always shows me 2 partitions, the first has the installation files. No matter what I tried I cannot delete the first partition because it is read-only!!
I also tried from windoze but there the installation partition seems non existant! And I can format the USB normally but at opensuse 12.1 I see again the ghost read-only partition with the 12.1 installation! YaST partitioner was not helpful at all…
How long does this procedure take?? Cause since you posted it and I after 2 minutes gave the command(as root) it is still working the light on the usb stick still flashes and the konsole still waits for the job to finish!!
The command I gave:
dd if=/dev/urandom of=/dev/sdg
Am 18.11.2011 12:46, schrieb djdoo:
> How long does this procedure take?? Cause since you posted it and I
> after 2 minutes gave the command(as root) it is still working the
> light on the usb stick still flashes and the konsole still waits for
> the job to finish!! The command I gave: dd if=/dev/urandom
> of=/dev/sdg
>
Would it not be easier and faster just to use a partitioner of your
choice to have the wanted effect (I use cfdisk for these things).
That is what I do (I also make some live usb’s which I have to use later
again for something else).
su -
cfdisk /dev/sdg
# now create a new partition table and new partition
# for example a fat32
mkdosfs -n USBSTICK -v /dev/sdg1
sync
this is done by me in 30 seconds or so.
–
PC: oS 11.4 (dual boot 12.1) 64 bit | Intel Core i7-2600@3.40GHz | KDE
4.6.0 | GeForce GT 420 | 16GB Ram
Eee PC 1201n: oS 11.4 64 bit | Intel Atom 330@1.60GHz | KDE 4.7.3 |
nVidia ION | 3GB Ram
Can this partitioner remove a read-only ghost partition??
Furthermore I have another question: Why the partition where the installation files are on a USB flash must be read-only?? Is this a CD simulation situation or what??
Am 18.11.2011 13:16, schrieb djdoo:
>
> Still the little led is blinking… What is it doing all that
> time??
>
Depends on the size of your usb, the command you started writes random
numbers to the usb until the usb is full.
It is a goo way to ensure that data is destroyed in a way that nobody
can recover it, but it takes long.
–
PC: oS 11.4 (dual boot 12.1) 64 bit | Intel Core i7-2600@3.40GHz | KDE
4.6.0 | GeForce GT 420 | 16GB Ram
Eee PC 1201n: oS 11.4 64 bit | Intel Atom 330@1.60GHz | KDE 4.7.3 |
nVidia ION | 3GB Ram
Am 18.11.2011 13:36, schrieb djdoo:
> Can this partitioner remove a read-only ghost partition??
What is a ghost partition?
> Furthermore I have another question: Why the partition where the
> installation files are on a USB flash must be read-only?? Is this a
> CD simulation situation or what??
>
Seems so since it simulates a live cd. But to get an authoritative
answer you should ask the developers who made the hybrid images for the
live cd’s, we are just other users.
–
PC: oS 11.4 (dual boot 12.1) 64 bit | Intel Core i7-2600@3.40GHz | KDE
4.6.0 | GeForce GT 420 | 16GB Ram
Eee PC 1201n: oS 11.4 64 bit | Intel Atom 330@1.60GHz | KDE 4.7.3 |
nVidia ION | 3GB Ram
Why write random bits? That would result in an unpredictable partition table. And why overwrite the entire disk?
If the object is to clear the partition table then surely dd if=/dev/zero of=/dev/devicename bs=512 count=1
would be cleaner and quicker.
The gui way is to use partitionmanager (needs to be installed). Select your usb stick and go to Device > New Partition Table. It’s much faster than the dd method.
Well guys thank you for all your help my stick is clean now but it took about 7 hours to finish!!
This is not at all practical… I mean if we have to wait 7 hours for the read-only installation partition to be destroyed and the usb stick to be as it was before better burn a CD instead…
Or find a quicker procedure, and it is a big mistake that the guides to make a usb stick installation procedure do not write how to take your usb stick to its previous state!
Can partitionmanager delete read-only partitions??
Am 19.11.2011 10:26, schrieb djdoo:
> Can partitionmanager delete read-only partitions??
>
Why do you ask that again and again, I told you at the very beginning
that I use cfdisk for exactly your situation, so the answer is obviosly
definitely YES, otherwise I could not use it myself.
You can of course use another graphical partitioner (for which I cannot
tell you practical experience with cleaning the usb live medias but they
should just work as well).
–
PC: oS 11.4 (dual boot 12.1) 64 bit | Intel Core i7-2600@3.40GHz | KDE
4.6.0 | GeForce GT 420 | 16GB Ram
Eee PC 1201n: oS 11.4 64 bit | Intel Atom 330@1.60GHz | KDE 4.7.3 |
nVidia ION | 3GB Ram
Sorry but you’re (partially) wrong there. I have two USB sticks, both different sizes and from different manufacturers, which had the Opensuse 12.1 KDE x86_64 image written onto them with Suse Studio Imagewriter.
In both cases no matter which partitioner I tried (YAST Partitioner, cfdisk, fdisk) the partition table was not properly deleted/re-initialised. I tried the expert option in the YAST partitioner that creates a new partition table, I tried umpteen times to delete all partitions and create a new partition table in cfdisk and fdisk. But no luck - I even kept getting errors from the YAST partitioner and no matter what computer I inserted the USB stick into Dolphin kept showing the ‘ghost’ partitions, by which I mean ‘Opensuse live KDE’ (whatever it’s called) partition plus another one that none of the partitioning programs saw.
The only thing that helped was letting dd run for half a minute or so writing zeroes to the first few MB’s of the USB stick. IMHO this is a serious bug, even if it doesn’t occur in all cases, since it forces ordinary users to run an incredibly dangerous dd command to get back usage of their USB stick after using it to install Opensuse. Try explaining to someone who’s not experienced with Linux how they should carefully find out which /dev/sdX device their USB stick is, otherwise the command could destroy everything on their computer!
I can only report what I excperience and that is that cfdisk never and absolutely never failed me to make a live usb clean with whatever method I created it (and I do that often).
So if that failed for you describe the absolutely exact steps you used with cfdisk, which keys you pressed and which exact command you invoked so probably someone cab shed a light on it why it fails for you.
> The only thing that helped was letting dd run for half a minute or so
> writing zeroes to the first few MB’s of the USB stick. IMHO this is a
> serious bug, even if it doesn’t occur in all cases, since it forces
> ordinary users to run an incredibly dangerous dd command to get back
> usage of their USB stick after using it to install Opensuse. Try
> explaining to someone who’s not experienced with Linux how they should
> carefully find out which /dev/sdX device their USB stick is, otherwise
> the command could destroy everything on their computer!
You should be sure to open a bug in bugzilla on this, then, so the
developers know about this issue.
> How long does this procedure take?? Cause since you posted it and I
> after 2 minutes gave the command(as root) it is still working the light
> on the usb stick still flashes and the konsole still waits for the job
> to finish!!
No wonder.
> The command I gave:
> dd if=/dev/urandom of=/dev/sdg
Writing 8 GiB of random data (unnecesary) can take a long time depending on
the machine. A huge random stream has to be generated. Seven hours, as you
have seen. If you want to wipe a full disk simply do:
dd if=/dev/zero of=/dev/sdg
The extra security of writing random data is paranoic.
Just overwriting the partition table with dd (512 bytes) would be enough.
Or removing the partition with fdisk. Or creating a new table.
And if that doesn’t work, delete the few megabytes of the disk with dd. I
don’t understand why that would be necessary, it would be interesting to
learn the reason.
–
Cheers / Saludos,
Carlos E. R.
(from 11.4 x86_64 “Celadon” at Telcontar)