I print the partition table:
Disk /dev/sdd1: 512 MB, 512443392 bytes
16 heads, 62 sectors/track, 1008 cylinders
Units = cylinders of 992 * 512 = 507904 bytes
Device Boot Start End Blocks Id System
This suggests there is no partition at present. So I add a partition
(primary, number 1, cylinders 1-1088. Now I print this and have:
Disk /dev/sdd1: 512 MB, 512443392 bytes
16 heads, 62 sectors/track, 1008 cylinders
Units = cylinders of 992 * 512 = 507904 bytes
Device Boot Start End Blocks Id System
/dev/sdd1p1 1 1008 499937 83 Linux
And I change the type to 4 and print again:
Disk /dev/sdd1: 512 MB, 512443392 bytes
16 heads, 62 sectors/track, 1008 cylinders
Units = cylinders of 992 * 512 = 507904 bytes
Device Boot Start End Blocks Id System
/dev/sdd1p1 1 1008 499937 4 FAT16 <32M
And write and quit (w command):
The partition table has been altered!
Calling ioctl() to re-read partition table.
WARNING: Re-reading the partition table failed with error 22:
Invalid argument.
The kernel still uses the old table.
The new table will be used at the next reboot.
WARNING: If you have created or modified any DOS 6.x
partitions, please see the fdisk manual page for additional
information.
Syncing disks.
Well, I tried:
# sfdisk /dev/sdd1
Checking that no-one is using this disk right now ...
BLKRRPART: Invalid argument
OK
Warning: start=62 - this looks like a partition rather than
the entire disk. Using fdisk on it is probably meaningless.
[Use the --force option if you really want this]
When I use sfdisk with --force option,
...
Disk /dev/sdd1: 1008 cylinders, 16 heads, 62 sectors/track
Old situation:
Units = cylinders of 507904 bytes, blocks of 1024 bytes,
counting from 0
Device Boot Start End #cyls #blocks Id System
/dev/sdd1p1 0 - 0 0 0 Empty
/dev/sdd1p2 0 - 0 0 0 Empty
/dev/sdd1p3 0 - 0 0 0 Empty
/dev/sdd1p4 0 - 0 0 0 Empty
/dev/sdd1p1 :
Next I try:
# mkfs.vfat -F 32 /dev/sdd1
mkfs.vfat 2.11 (12 Mar 2005)
But my files still there. Fsck didn't help.
My guess is that I need a low level format, but I have no idea how to
do that for a usb-key. Is it usually done with a proprietary low-level
format utility?