Steve's blog
   


Steve About
Steve's blog,
The Words of the Sledge
steve@einval.com

Subscribe
Subscribe to the RSS feed.

Links

  • Home
  • Debian
  • PlanetDebian
  • Search PlanetDebian
  • Friends

  • Matthew Garrett
  • Jonathan McDowell
  • Jo McIntyre
  • Martin Michlmayr
  • Andrew Mobbs
  • Mike Pitt
  • Daniel Silverstone
  • Andy Simpkins
  • Neil Williams

  •        

    Friday, 24 August 2012

    Even more progress on EFI Debian CDs

    Continuing on from my second EFI progress report...

    My second alpha release of a Wheezy netinst CD for amd64 EFI seemed to work OK for me and a few others, but it wasn't 100% good, with (at least) two issues:

    • It didn't work as a hybrid (CD or USB) image, just working from CD for EFI
    • It didn't work for BIOS booting due to a silly bug

    In the couple of days since then, I've fixed both of these issues. Yay! Hybrid boot was easier than I expected - I've just added a tiny FAT partition to the image containing the grub EFI bootloader and that seems to work fine. I also found that I made a mistake in the ordering of the El Torito boot records in the last image. BIOS boot seems to be limited to just the first image available on the machines I've tested with, wherease EFI will happily work as a secondary image. I've swapped them around in my code, and things look much better now. So, time for another CD alpha release for testing.

    Grab the image from http://cdimage.debian.org/cdimage/unofficial/efi-development/upload3/ if you'd like to help test it. Please do, and let me know via debian-boot/debian-cd how you get on.

    As previously, the "bits" subdirectory contains all the tweaked d-i packages I've played with, in both source and binary form. My debian-cd changes are still in my branch but are just about ready for merging I think. I've posted my full set of d-i patches to the debian-boot list for review now, and hopefully we'll be able to get those changes merged in after the Wheezy d-i beta 2 build is done. Full speed ahead for EFI in beta 3!

    03:16 :: # :: /debian/CDs :: 16 comments

    Comments

    Re: Even more progress on EFI Debian CDs
    Anonymous wrote on Fri, 24 Aug 2012 06:23

    You should take a look at mjg59's post on creating hybrid EFI CDs that also boot on Apple systems. He discovered numerous issues with EFI boot on various EFI BIOSes, and worked around them; no sense duplicating those issues.


    Reply
    Re: Even more progress on EFI Debian CDs
    Anonymous wrote on Fri, 24 Aug 2012 06:23

    http://mjg59.dreamwidth.org/4957.html


    Reply
      Re: Re: Even more progress on EFI Debian CDs
      Steve wrote on Wed, 29 Aug 2012 15:22

      Thanks for the pointer; Matthew and I have already been talking about this.

      If I'm brutally honest, I'd have to say that I couldn't care less about supporting Macs. But there are a number of people who want to use them, so I'll carry on working on this... :-)


      Reply
    Re: Even more progress on EFI Debian CDs
    Andy Cater wrote on Sat, 25 Aug 2012 18:01

    Thinkpad x21e - UEFI set to boot first but dual boot enabled.

    New image copied to USB stick: booted well. No EFI partition found. Then realised that Windows 7 is on NTFS formatted disk: if I want to retain it and dual boot, I'm probably better using stock install of Wheezy beta 7.

    Kudos for working EFI boot and partition checking and for sorting the USB stick boot. All best, AndyC


    Reply
    Re: Even more progress on EFI Debian CDs
    Andy Cater wrote on Sat, 25 Aug 2012 21:38

    Don't know quite what they've done to this Thinkpad - 1.6G partition at the beginning with Lenovo tools, Windows, recovery partition.

    Booting with UEFI and legacy - finds Windows.

    UEFI only finds no operating system - so it's not booting from EFI.

    Second partition is bootable: installing Debian on a logical partition means that the bootable partition moves and the machine won't boot. Moving the bootable partition back to partition 2 reboots Windows fine.

    Debian install finds no other operating system - so doesn't find the Windows that is bootable. Installing Grub to the MBR results in a system which finds no operating system and won't boot Can't install Debian here yet using EFI or standard Wheezy :(


    Reply
      Re: Re: Even more progress on EFI Debian CDs
      Steve wrote on Wed, 29 Aug 2012 15:25

      Of course your system isn't booting via EFI, Windows 7 is BIOS only AFAIK, that's one of the reasons why Microsoft have not mandated (EFI and Secure Boot) only for the latest "Designed for Windows" logo.

      In terms of getting Debian installed, you might be better to simply reinstall Windows (assuming you want/need it) instead of fighting their preinstalled crap.


      Reply
    Re: Even more progress on EFI Debian CDs
    Mattias Mattsson wrote on Sun, 26 Aug 2012 11:53

    Have you looked at http://mjg59.dreamwidth.org/11285.html ?


    Reply
      Re: Re: Even more progress on EFI Debian CDs
      Steve wrote on Wed, 29 Aug 2012 15:33

      Yup, adding similar features is next on my list.


      Reply
    Re: Even more progress on EFI Debian CDs
    Elessar wrote on Mon, 27 Aug 2012 10:59

    Thank you for your work. I am an UEFI user with some knowledge about UEFI booting, but I would be completely lost when it comes to debian-cd, so I am glad that you can do the work! I was on holidays, but now that I have come back I shall be able to test your images.


    Reply
      Re: Re: Even more progress on EFI Debian CDs
      Steve wrote on Wed, 29 Aug 2012 15:33

      Great, let us know how you get on!


      Reply
    Re: Even more progress on EFI Debian CDs
    Henk Koster wrote on Mon, 27 Aug 2012 15:01

    Installs great in VMware Fusion 5.0.0 VM with efi firmware enabled.


    Reply
      Re: Re: Even more progress on EFI Debian CDs
      Steve wrote on Wed, 29 Aug 2012 15:34

      Lovely, thanks for the success report!


      Reply
    Possibility of grub-less EFI stub booting?
    xlz wrote on Thu, 30 Aug 2012 16:25

    "It seems that EFI has most of the features of GRUB and 90% of what is truly needed to direct boot a Linux kernel. "[1] Even the kernel is moving stuff that belonged to grub into itself.[2] So one might suggest why not boot with EFI stub to completely get rid of the grub duplication? Heck, I don't even need GPT for my poor hard drive with no more than three partitions.

    Actually I'm doing such thing and it works perfectly, manually converting a BIOS installed Debian into EFI based with the method in [3]. Here is my dirty homebrew script[4] for this, ugly but you get the idea. I wonder it won't take too much effort to make it work with existing initramfs-tools infrastructure, but I know nothing now.

    Matthew Garrett does have valid objections in [1]. He seems to be over-concerned about the incompetence and inconsistency of UEFI firmware as he has been personally burnt out by that, I guess. My point is that the grub-less EFI stub booting should be at least one viable option for cetain niche of users who prefer lightweight and speed and can work with somewhat inconsistent UEFI boot manager UI, while adding support for it probably won't destabilize the system or other existing tools.

    By the way, debian-wheezy-amd64-efi-test3.iso works great on my T520, with a manually partitioned disk (msdos, 200M /boot/efi, /, swap). Thank you for your nice work.

    [1]: http://lwn.net/Articles/505823/ [2]: http://lwn.net/Articles/507827/ [3]: http://tanguy.ortolo.eu/blog/article51/ Actually I got here from your comment on that blog. [4]: http://pastebin.com/xGqrw35D


    Reply
      Re: Possibility of grub-less EFI stub booting?
      Steve wrote on Fri, 31 Aug 2012 14:43

      It could be a nice move to simplify the boot-stack to not need grub, but as a general-purpose option for now I think EFI->grub->kernel is a better choice for most people, and definitely as a default for an installer. Ditto GPT: while many people may not *need* it, frankly I think it's a better option than DOS-style partitioning anyway, with fewer limitations. It doesn't hurt to use it by default for EFI systems.

      I'd be happy to help review patches for going the grub-less route if you're interested in working on that.

      Thanks for confirming the test CD works for you, as well! :-)


      Reply
    Re: Even more progress on EFI Debian CDs
    Andy Cater wrote on Sat, 01 Sep 2012 21:44

    Decided to do without Windows and Lenovo recovery partitions.

    Burnt your latest image to CD: attached external drive to Thinkpad x121e and changed boot to UEFI only.

    Booted - installed perfectly. Needed firmware-brcm80211 from non-free - also installed firmware-atheros afterwards.

    If you don't install X Windows, then you need to reboot and add nomodeset in the grub stanza temporarily by command line edit in order to see the console as a one-off.

    I then added KDE and it all works perfectly :)


    Reply
      Re: Re: Even more progress on EFI Debian CDs
      Steve wrote on Sun, 02 Sep 2012 18:37

      Hi Andy,

      Great, thanks for the feedback!


      Reply

    Your Comment

     
    Name:
    URL/Email: [http://... or mailto:you@wherever] (optional)
    Title: (optional)
    Comment:
    Anti-spam:Select the tenth of the following words and enter it in the "Human" box
    hulking hacksaw humours hicks hitched hungrier hungrily has heftiest hymned
    Human:
    Save my Name and URL/Email for next time