BTS

Message4546

Author jkirk
Recipients jkirk
Date 2013-03-23.12:04:28
Content
Hi!

When using grml2usb I usually create two partitions on my USB-Key.
sdX1 is used for DATA und sdX2 should go for grml. (I use the first
primary partion for DATA because Windows only shows the first
partition on removable devices - at least on XP)...

This then looks like this

# sfdisk -l /dev/sdb -uB

Disk /dev/sdb: 1022 cylinders, 126 heads, 62 sectors/track
Units = blocks of 1024 bytes, counting from 0

   Device Boot   Start       End    #blocks   Id  System
/dev/sdb1           31   3124799    3124769    7  HPFS/NTFS/exFAT
/dev/sdb2   *  3124800   3991931     867132   83  Linux
/dev/sdb3            0         -          0    0  Empty
/dev/sdb4            0         -          0    0  Empty


When running grml2usb it complains "bootflag is NOT enabled":

# grml2usb ./grml96-full_2013.02-rc1.iso /dev/sdb2 --syslinux-mbr --bootloader-only --verbose
Debug: 2013-03-23 12:19:52,273 Executing grml2usb version 0.13.5
Debug: 2013-03-23 12:19:52,276 Using ISO ./grml96-full_2013.02-rc1.iso
Debug: 2013-03-23 12:19:52,276 mount ['-o', 'loop,ro', '-t', 'iso9660'] ./grml96-full_2013.02-rc1.iso /tmp/grml2usb4QBTjk
Debug: 2013-03-23 12:19:52,280 register_mountpoint(/tmp/grml2usb4QBTjk)
Debug: 2013-03-23 12:19:52,282 bootflag is NOT enabled
Debug: 2013-03-23 12:19:52,283 Fatal: Device /dev/sdb does not have the bootflag set. Please enable it to be able to boot.
Debug: 2013-03-23 12:19:52,283 umount [] /tmp/grml2usb4QBTjk
Debug: 2013-03-23 12:19:52,287 unregister_mountpoint(/tmp/grml2usb4QBTjk)
Traceback (most recent call last):
  File "/usr/sbin/grml2usb", line 1780, in <module>
    main()
  File "/usr/sbin/grml2usb", line 1757, in main
    install(iso, device)
  File "/usr/sbin/grml2usb", line 1485, in install
    install_grml(iso_mountpoint, device)
  File "/usr/sbin/grml2usb", line 1511, in install_grml
    check_boot_flag(device)
  File "/usr/sbin/grml2usb", line 328, in check_boot_flag
    "Please enable it to be able to boot." % boot_dev)
__main__.VerifyException: Device /dev/sdb does not have the bootflag set. Please enable it to be able to boot.

I then set the boot flag on the first partion rerun grml2usb and then
reset the boot flag back to the second partiton again.

Additional information: 
* I obviously had a "first run" without --bootloader-only.
* The same behaviour is also shown without --syslinux-mbr but in that
case the boot flag is not needed at all. The system boots even without
the bootflag and also if set on the wrong partition.

So we have three issues here:

* syslinux-mbr needs the boot flag
* (default) mbr does not need the boot flag
* the boot flag detection on other than the primary partition seems to
be broken.

and a question:

* is it possible to let grml2usb set the bootflag (if needed).

Regards,
 - Darsha
History
Date User Action Args
2013-03-23 12:04:28jkirksetrecipients: + jkirk
2013-03-23 12:04:28jkirklinkissue1248 messages
2013-03-23 12:04:28jkirkcreate