Failure to dd diskboot.img to pen drive
pmeyer at themeyerfarm.com
Thu Nov 15 21:43:39 UTC 2007
Rick Stevens wrote:
> On Thu, 2007-11-15 at 18:08 -0200, Clodoaldo wrote:
>> I want to install F8 from a 1GB pen drive but dd does not work,
>> although I can mount it. dd shows it worked:
>> # dd if=/home/cpn/Desktop/Downloads/diskboot.img of=/dev/sdb1
>> 24576+0 records in
>> 24576+0 records out
>> 12582912 bytes (13 MB) copied, 0.307408 s, 40.9 MB/s
>> But there is nothing in the directory:
>> [root at dkt ~]# ll /media/KINGSTON/
>> total 0
>> fdisk -l shows strange messages:
>> # fdisk -l
>> Disk /dev/sda: 81.9 GB, 81964302336 bytes
>> 16 heads, 63 sectors/track, 158816 cylinders
>> Units = cylinders of 1008 * 512 = 516096 bytes
>> Device Boot Start End Blocks Id System
>> /dev/sda1 * 1 203 102280+ 83 Linux
>> /dev/sda2 204 158816 79940952 8e Linux LVM
>> Disk /dev/sdb: 1027 MB, 1027604480 bytes
>> 32 heads, 62 sectors/track, 1011 cylinders
>> Units = cylinders of 1984 * 512 = 1015808 bytes
>> This doesn't look like a partition table
>> Probably you selected the wrong device.
>> Device Boot Start End Blocks Id System
>> /dev/sdb1 ? 966294 1813487 840415161 69 Unknown
>> Partition 1 has different physical/logical beginnings (non-Linux?):
>> phys=(612, 109, 33) logical=(966293, 30, 10)
>> Partition 1 has different physical/logical endings:
>> phys=(255, 97, 46) logical=(1813486, 20, 39)
>> Partition 1 does not end on cylinder boundary.
>> /dev/sdb2 ? 976282 1834012 850868148+ ff BBT
>> Partition 2 has different physical/logical beginnings (non-Linux?):
>> phys=(367, 115, 35) logical=(976281, 15, 17)
>> Partition 2 has different physical/logical endings:
>> phys=(80, 13, 10) logical=(1834011, 14, 55)
>> Partition 2 does not end on cylinder boundary.
>> /dev/sdb3 ? 891259 1782449 884061367 6c Unknown
>> Partition 3 has different physical/logical beginnings (non-Linux?):
>> phys=(355, 116, 37) logical=(891258, 2, 52)
>> Partition 3 has different physical/logical endings:
>> phys=(112, 97, 32) logical=(1782448, 31, 27)
>> Partition 3 does not end on cylinder boundary.
>> /dev/sdb4 ? 1 1790834 1776506368 0 Empty
>> Partition 4 has different physical/logical beginnings (non-Linux?):
>> phys=(10, 114, 13) logical=(0, 0, 1)
>> Partition 4 has different physical/logical endings:
>> phys=(0, 0, 0) logical=(1790833, 1, 2)
>> Partition 4 does not end on cylinder boundary.
>> Partition table entries are not in disk order
>> When I try to enter fdisk the device can't be opened:
>> # fdisk sdb
>> Unable to open sdb
>> # ll /dev/sdb1
>> -rw-r--r-- 1 root root 12582912 2007-11-15 17:56 /dev/sdb1
>> Any workaround?
> Redo the dd, but do NOT specify a partition, e.g.:
> dd if=/home/cpn/Desktop/Downloads/diskboot.img of=/dev/sdb
> For it to be bootable, the image must be written to the raw device
> (/dev/sdb), not to a partition on the drive (/dev/sdb1).
Good advice, and the OP has only a 1GB pen drive, but for those with a
4GB or larger pen drive, you have better options.
First slam the broken MBR shipped on most pen drives:
unmount any mounted partitions from the device
# cat /usr/lib/syslinux/mbr.bin >/dev/sdb
($ rpm -qf /usr/lib/syslinux/mbr.bin
Second, use fdisk to create two partitions on the tumb drive. The first
one can be 12 or 13 MB depending on manufacturer. Make it 13MB to be safe.
Now you can dd the bootdisk.img to the first partition and it will be
Thirdly, format the second partition as FAT32
# mkfs -t vfat -F 32 /dev/sdb2 -n images
copy the Fedora DVD image to the second partition.
Now you have a pen drive that can do the entire install, not just the boot.
The USB driver is slow to load. When you are prompted for the DVD
image, select HARDRIVE/sdb2 (assuming one drive in the system). If the
pen drive is not shown in the list of hard drives, go back and try it
again. It can take anaconda 10 seconds to mount the pen drive.
Windows, even the mighty Vista, cannot mount two partitions from a thumb
drive. Go Microsoft! You rock!
Thus making the available space on the second partition unavailable from
Windows. Does not bother me, since I have no MS products at all, but it
does affect some folks.
More information about the fedora-list