View previous topic :: View next topic |
Installed Gentoo on EFI yet? |
Yes/x86* Macintosh |
|
3% |
[ 2 ] |
Yes/x86_64 PC |
|
60% |
[ 38 ] |
Yes/i386 PC/Tablet |
|
0% |
[ 0 ] |
Yes/ARM, ia64, other |
|
1% |
[ 1 ] |
Yes, multiple architectures. |
|
4% |
[ 3 ] |
No, MBR forever/EFI is devil spawn |
|
4% |
[ 3 ] |
No, no EFI capable machines |
|
25% |
[ 16 ] |
I've never installed Gentoo... |
|
0% |
[ 0 ] |
|
Total Votes : 63 |
|
Author |
Message |
Sakaki Guru
Joined: 21 May 2014 Posts: 409
|
Posted: Fri Dec 19, 2014 12:40 pm Post subject: |
|
|
I have Gentoo dual-booting under EFI (with Windows 8.1) on my Panasonic CF-AX3 Ultrabook. Secure boot is used, and the Gentoo root/swap/home is on LVM over LUKS. No separate boot loader is required.
Shameless plug: the full instructions are available in the EFI Gentoo End to End Install article, on the Gentoo wiki. There's also an accompanying overlay here on GitHub. _________________ Regards,
sakaki |
|
Back to top |
|
|
ct85711 Veteran
Joined: 27 Sep 2005 Posts: 1791
|
Posted: Fri Dec 19, 2014 5:18 pm Post subject: |
|
|
I've tried rEFInd, but didn't like that too much due to listing so many old kernels (I like keeping the old kernels for troubleshooting) at the selection screen. Also it may be also due to be using grub for so long that, having rEFInd boot into grub just to then boot into windows or gentoo is a waste. |
|
Back to top |
|
|
eccerr0r Watchman
Joined: 01 Jul 2004 Posts: 9679 Location: almost Mile High in the USA
|
Posted: Fri Dec 19, 2014 5:30 pm Post subject: |
|
|
No Macintosh users, or people who have installed EFI on Macintosh also did it for other architectures? _________________ Intel Core i7 2700K/Radeon R7 250/24GB DDR3/256GB SSD
What am I supposed watching? |
|
Back to top |
|
|
avx Advocate
Joined: 21 Jun 2004 Posts: 2152
|
Posted: Fri Dec 19, 2014 6:42 pm Post subject: |
|
|
eccerr0r wrote: | No Macintosh users, or people who have installed EFI on Macintosh also did it for other architectures? |
What's your definition of Macintosh? If normal Apple laptop's count, then I've done it on two MBPs (13&15 from 2011). _________________ ++++++++++[>+++++++>++++++++++>+++>+<<<<-]>++.>+.+++++++..+++.>++.<<+++++++++++++++.>.+++.------.--------.>+.>. |
|
Back to top |
|
|
eccerr0r Watchman
Joined: 01 Jul 2004 Posts: 9679 Location: almost Mile High in the USA
|
Posted: Fri Dec 19, 2014 8:11 pm Post subject: |
|
|
Ah... basically if it's am Apple computer that has EFI on it, it counts...
I guess MacBookPro the "Mac" originally meant "Macintosh"... _________________ Intel Core i7 2700K/Radeon R7 250/24GB DDR3/256GB SSD
What am I supposed watching? |
|
Back to top |
|
|
avx Advocate
Joined: 21 Jun 2004 Posts: 2152
|
Posted: Fri Dec 19, 2014 9:42 pm Post subject: |
|
|
ok then and yes as I said, done on two machines, both times with rEFInd (as rEFIt sucks), no problems. _________________ ++++++++++[>+++++++>++++++++++>+++>+<<<<-]>++.>+.+++++++..+++.>++.<<+++++++++++++++.>.+++.------.--------.>+.>. |
|
Back to top |
|
|
apieum n00b
Joined: 18 Dec 2014 Posts: 9
|
Posted: Sat Dec 20, 2014 6:35 pm Post subject: |
|
|
Sakaki wrote: |
Shameless plug: the full instructions are available in the EFI Gentoo End to End Install article, on the Gentoo wiki. There's also an accompanying overlay here on GitHub. |
Great ! Thank you. |
|
Back to top |
|
|
james.h.bates n00b
Joined: 11 Jul 2013 Posts: 12
|
Posted: Mon Dec 22, 2014 6:17 am Post subject: |
|
|
eccerr0r wrote: | No Macintosh users, or people who have installed EFI on Macintosh also did it for other architectures? |
Sure there are. Have been using it on all my mac hardware (a MBP 6,1 17", a MBA 11" and a mac mini) for about a year now. I use elilo since I use OS X's "bless" to set it as the default bootloader. This way I don't need need to boot OSX and rebless every time I do a kernel upgrade (which is what would be necessary if I used EFI stub). grub 2 is a configuration nightmare, whereas elilo is a breeze. You basically just write the kernel command-line as is into elilo.conf and voila. elilo exe, conf and kernels must reside on a HFS+ partition though (so mac firmware can boot it), so basically my /boot is HFS+.
Bootcamp/BIOS emulation/GPT-MBR Hybrid is frankly a pain on macs, so I don't use it at all. Just pure EFI & GPT disks. |
|
Back to top |
|
|
khayyam Watchman
Joined: 07 Jun 2012 Posts: 6227 Location: Room 101
|
Posted: Mon Dec 22, 2014 1:16 pm Post subject: |
|
|
james.h.bates wrote: | I use elilo since I use OS X's "bless" to set it as the default bootloader. This way I don't need need to boot OSX and rebless every time I do a kernel upgrade (which is what would be necessary if I used EFI stub). |
james ... actually, "blessing" is only necessary for HFS+ filesystems, you can use efi stub on vfat (ESP) as the EFI standard requires that the firmware supports loading efi executables from the ESP and that this filesystem is vfat. The standard also states a default loader of {ESP}/efi/boot/boot{ia32,x64}.efi (dependent on architecture) so this can be used without having to change anything in NVRAM/efivars (though the Apple EFI firmware doesn't automatically boot from this, the "alt" key needs to be pressed, as for some reason the Apple doesn't use the ESP at all for booting OSX, the efi executable on the OSX install, if it exists, is given precedence). Suffice to say, booting without OSX and/or a HFS+ partition is in fact possible.
james.h.bates wrote: | [...] conf and kernels must reside on a HFS+ partition though (so mac firmware can boot it), so basically my /boot is HFS+. |
No, in fact you could probably setup elilo and your kernels on the ESP. If you look at your partition scheme you will see a 200mb partition (code "EF00") which is the ESP (EFI System Partition) this is part of the EFI specification, and Apple's EFI firmware will boot from it if you provide an entry in NVRAM/efivars (ie, with efibootmgr).
best ... khay |
|
Back to top |
|
|
Progman3K l33t
Joined: 03 Jan 2004 Posts: 773
|
Posted: Wed Dec 24, 2014 4:21 am Post subject: |
|
|
I too feel that there is an option missing from the poll:
Have you failed at installing Gentoo on a (U)EFI system?
I would vote for that option, twice.
Admittedly, I am still confused about the whole process. Whatever guide I follow, it never seems to work out.
Also, I think there's a chicken-and-egg problem too; what Gentoo media can you use to perform the installation? There is a step that requires the efivars to be available to the install process during the installation, but it does not appear that there exists any Gentoo install media that can boot in (U)EFI mode, so ...
At one point while grasping at straws I was able to install Debian onto a UEFI system. I noticed that it created a folder called
/boot/EFI/debian
that contained a file called grubx64.efi
Running the file command on it reports
PE32+ executable (EFI application) x86-64 (stripped to external PDB), for MS Windows
This is apparently good enough for the UEFI BIOS because it permits starting it.
However, there is no celebration there either; the Debian installation locks up while booting itself, apparently while initializing the kernel.
If on the other hand, I follow whatever guide there is for installing Gentoo on such a system, running file on the kernel that is produced reports
Linux kernel x86 boot executable bzImage, version 3.16.5-gentoo (root@livecd) #7 SMP Tue Dec 23 21:23:50 EST 2014, RO-rootFS, swap_dev 0x5, Normal VGA
Yes, this kernel has the CONFIG_EFI_STUB option enabled, along with the other appropriate EFI options, but in my experience, even when I've been able to register it as a boot option in the UEFI BIOS, booting from it only immediately returns to the UEFI BIOS menu and nothing else.
Mind you, this is on a machine that is KNOWN TO WORK because it CAN boot the Debian kernel, albeit that process ends up hanging but that's probably another story.
So I'm essentially stuck and demoralised.
I suppose the poll option I would also select is that UEFI is the work of the devil (MS), invented to give users like me headaches in the hopes we will abandon Linux, which I won't.
Thanks for reading.
Last edited by Progman3K on Wed Dec 24, 2014 7:07 pm; edited 1 time in total |
|
Back to top |
|
|
The Doctor Moderator
Joined: 27 Jul 2010 Posts: 2678
|
Posted: Wed Dec 24, 2014 5:00 am Post subject: |
|
|
Without going into too many details, use the system rescue CD as an install media. Don't use a /boot partition. Instead, have a FAT32 partition (which you can mount anywhere, including /boot) that has a /EFI/Boot directory. If you are not dual booting, you can copy your kernel to /EFI/Boot/bootx64.efi. You need to use the built in command line, and everything should just work. If you want to mess with the name or dual boot with something else you will need to play around with the EFI vars.
I hope this is enlightening. Yes, it really can be this simple as long as you remember one or two kernel options.\
EDIT: Corrected paths so that they are actually, well, correct. _________________ First things first, but not necessarily in that order.
Apologies if I take a while to respond. I'm currently working on the dematerialization circuit for my blue box.
Last edited by The Doctor on Wed Dec 24, 2014 7:38 am; edited 1 time in total |
|
Back to top |
|
|
Jazz-KP n00b
Joined: 04 Jul 2008 Posts: 38
|
Posted: Wed Dec 24, 2014 5:35 am Post subject: |
|
|
Been running a UEFI install for a year now. I'd say installation was kind of a PITA and I think I ended up accidentally overwriting something Windows related on my EFI partition. Can't set console resolution (primary graphics is nvidia), but other than that it is running okay. |
|
Back to top |
|
|
Perfect Gentleman Veteran
Joined: 18 May 2014 Posts: 1249
|
Posted: Wed Dec 24, 2014 6:24 am Post subject: |
|
|
EFISTUB with kernel on USB-flash |
|
Back to top |
|
|
asturm Developer
Joined: 05 Apr 2007 Posts: 8936
|
Posted: Wed Dec 24, 2014 9:36 am Post subject: |
|
|
Yes, via efibootmgr in x86_64, twice. |
|
Back to top |
|
|
eccerr0r Watchman
Joined: 01 Jul 2004 Posts: 9679 Location: almost Mile High in the USA
|
Posted: Wed Dec 24, 2014 9:59 am Post subject: |
|
|
Progman3K:
Are you saying that the kernel is completely dead when you try to start it from the boot loader? I think I may have the same problem you have, and can commiserate.
The initial thought that I assume is that if you failed at installing at UEFI you'd either work around by using CSM, or never installed :) (I'd fall in the latter case as this machine still doesn't have Linux on it, but since I had my ia64 box boot just fine with EFI, it'd be a lie.)
In my case I have EFI_STUB set, but the UEFI firmware as well as grub2 would simply hang when trying to load the kernel image. No debug output available. Honestly UEFI booting should not be this hard, just have a file in the ESP and it *should* boot...
except it just doesn't work...
I never even got to the point to be able to run efibootmgr as I've never gotten a command line yet. _________________ Intel Core i7 2700K/Radeon R7 250/24GB DDR3/256GB SSD
What am I supposed watching? |
|
Back to top |
|
|
steveL Watchman
Joined: 13 Sep 2006 Posts: 5153 Location: The Peanut Gallery
|
Posted: Wed Dec 24, 2014 5:11 pm Post subject: |
|
|
Isn't there even one manufacturer that still supplies a BIOS?
Seems to me it'd be a good niche, since many of us would go for it; so long as we could boot to a kernel which groks a larger-disk. |
|
Back to top |
|
|
asturm Developer
Joined: 05 Apr 2007 Posts: 8936
|
Posted: Wed Dec 24, 2014 5:14 pm Post subject: |
|
|
Why back to BIOS when you could have coreboot? |
|
Back to top |
|
|
eccerr0r Watchman
Joined: 01 Jul 2004 Posts: 9679 Location: almost Mile High in the USA
|
Posted: Wed Dec 24, 2014 5:26 pm Post subject: |
|
|
No coreboot because new machines won't come with them, and coreboot will tend to be behind on figuring out how to configure new chipsets/cpus to work properly.
And likely no more BIOS/MBR boot support either because then upper software stacks would have to support more than one boot mechanism, and M$ would have none of that. _________________ Intel Core i7 2700K/Radeon R7 250/24GB DDR3/256GB SSD
What am I supposed watching? |
|
Back to top |
|
|
Progman3K l33t
Joined: 03 Jan 2004 Posts: 773
|
Posted: Wed Dec 24, 2014 6:56 pm Post subject: |
|
|
The Doctor wrote: | Without going into too many details, use the system rescue CD as an install media. |
OK, I downloaded the latest SystemRecueCD and booted it in UEFI mode by selecting it in UEFI-mode from the bootable-media list in the BIOS.
Grub starts in black and white mode and offers a menu.
No matter what options I select, whether I select any of the predefined ones in the DVD's boot-menu or whether I amend them, I always get
Quote: | Booting a command list
error: no suitable video mode found.
Booting in blind mode |
Even if I edit the boot parameters and put either video=nouveaufb:1920x1080-32,mtrr,ywrap or video=vesafb:1920x1080-32,mtrr,ywrap or nomodeset
Then either it locks up or the screen becomes a mess of snow-like lines of semi-text/graphics. In the latter case, it appears to proceed to load the userland but it is unusable because I can't make out anything in the display-snow. |
|
Back to top |
|
|
Progman3K l33t
Joined: 03 Jan 2004 Posts: 773
|
Posted: Wed Dec 24, 2014 6:58 pm Post subject: |
|
|
eccerr0r wrote: | Progman3K:
Are you saying that the kernel is completely dead when you try to start it from the boot loader? I think I may have the same problem you have, and can commiserate.
The initial thought that I assume is that if you failed at installing at UEFI you'd either work around by using CSM, or never installed (I'd fall in the latter case as this machine still doesn't have Linux on it, but since I had my ia64 box boot just fine with EFI, it'd be a lie.)
In my case I have EFI_STUB set, but the UEFI firmware as well as grub2 would simply hang when trying to load the kernel image. No debug output available. Honestly UEFI booting should not be this hard, just have a file in the ESP and it *should* boot...
except it just doesn't work...
I never even got to the point to be able to run efibootmgr as I've never gotten a command line yet. |
What you're describing is pretty much the experience I am having also.
And I'm not trying to dual-boot, I am only trying to get Gentoo installed. |
|
Back to top |
|
|
eccerr0r Watchman
Joined: 01 Jul 2004 Posts: 9679 Location: almost Mile High in the USA
|
Posted: Wed Dec 24, 2014 8:50 pm Post subject: |
|
|
Progman3K, Looks like you got further than me now :)
I wish I could have at least gotten "Decompressing Kernel" amongst other pre-init, but I don't even get that.
I am sort of focusing on dual-boot but rather first get a "livecd" view of the system first... If I can't get a "livecd" view then there's no chance of me installing it flat on the machine.
Currently the only known "livecd" that has a chance of working work is Fedlet's as I don't think any other distribution supplies a UEFI 32 bootable environment... And Fedlet's does not work as I think the tablet does not like my usb DVD drive... |
|
Back to top |
|
|
Progman3K l33t
Joined: 03 Jan 2004 Posts: 773
|
Posted: Thu Dec 25, 2014 12:59 am Post subject: |
|
|
eccerr0r wrote: | Progman3K, Looks like you got further than me now
I wish I could have at least gotten "Decompressing Kernel" amongst other pre-init, but I don't even get that.
I am sort of focusing on dual-boot but rather first get a "livecd" view of the system first... If I can't get a "livecd" view then there's no chance of me installing it flat on the machine.
Currently the only known "livecd" that has a chance of working work is Fedlet's as I don't think any other distribution supplies a UEFI 32 bootable environment... And Fedlet's does not work as I think the tablet does not like my usb DVD drive... |
eccerr0r, my head is currently spinning because by some magic, I have managed to boot and make it all the way to the login prompt!
The road was twisted:
After trying with a different PC for weeks, I gave up. The closest I had come with that one was booting it with the SystemRescueCD, booting its included kernel, but pointing the root at my Gentoo install on the hard disk. This meant that EVERY time I booted that machine, I had to access its UEFI boot menu, boot the RescueCD in UEFI mode, intercept grub, tell it to load the root filesystem from the hard-disk and adjust the kernel parameters for systemd. This did work but had limitations.
Eventually I needed a Windows machine for software development, I was writing a DirectX application and it became obvious that virtualbox's video-drivers could not handle the accelerated-video demands of the software; it would bluescreen constantly. So the machine I had originally purchased to run Linux was pressed into service running Windows 8.
I decided to get ANOTHER new machine to replace my old linux workhorse, which locks up frequently now. The cause is not clear but I suspect some hardware component(s) is/are failing.
As you well know, there is no way to obtain a machine with the older-style BIOS anymore.
So I tried installing a few linux distributions on this new machine, to see if ANY of them could work. This would validate the hardware's suitability to run linux/Gentoo. It was a quick way to determine this.
I tried Ubuntu, which was a failure because once its live-cd booted and went to graphical mode, the whole screen was fuzzy. It was like if the video was decimated... The text was illegible and this made doing anything with it impossible. Specifying a lesser resolution (like 800x600) would make the display legible, but all of Ubuntu's screens are designed for much larger resolutions than this, so controling any program was impossible because buttons would be off-screen somewhere and you could not click them. Also, Ubuntu's Live-CD apparently doesn't not come with efibootmgr, so even if I would get a terminal running, the commands to control things seemed not to be there. I lost patience.
I tried Debian. The Debian graphical install had a strange problem; there was a permanent black bar running across the display, where nothing would draw... Ignoring this, I went ahead with its install, which succeeded.
This gave me a correctly-dimensioned and formatted FAT32 boot-partition, ext2 root-partition and swap-partition.
But it was not to be, because even though Debian's Grub bootloader functioned and started the newly installed distro, it would lock-up while starting the kernel.
In hindsight, this may have been because of a problem with the EFI frambuffer driver-Nouveau framebuffer driver handoff.
The final piece may have come about this way (as I wrote above, I am still not absolutely sure how I solved the problem), by booting the Gentoo Live-CD and chrooting, I copied my newly-built gentoo-sources kernel on top of the existing Debian one. This coupled with booting through the Debian Grub bootloader and specifying nomodeset FINALLY caused the 3.16.5 kernel I built to get loaded and run.
Since the newer kernel was apparently properly-configured for EFI, I wound up at the login prompt and then because the efivars were finally acessible, I was able to use efibootmgr to finally register the new kernel directly with the UEFI firmware/BIOS.
I then rebooted and without going through Grub or anything, it loaded the new kernel and userspace!
As you can probably tell, my story is a bit disjointed and I am not altogether certain of what actually was the key to success.
Thank you for reading thus far, but I ask you to read on a bit more because I have a newb question:
If I now modify my kernel, do I have to re-register it with the UEFI firmware/BIOS or can I simply overwrite the image I put in /dev/sda1/EFI/boot/bootx64.efi ?
I'm afraid I still don't really understand the mechanism.
Thanks for your help, fellows. You have no idea how close I was to losing it, and for a guy my age/maturity, that's saying a lot. |
|
Back to top |
|
|
The Doctor Moderator
Joined: 27 Jul 2010 Posts: 2678
|
Posted: Thu Dec 25, 2014 1:19 am Post subject: |
|
|
You can just overwrite the kernel.
Although, if you intend to dual boot keep in mind that windows will expect to be bootx64.efi _________________ First things first, but not necessarily in that order.
Apologies if I take a while to respond. I'm currently working on the dematerialization circuit for my blue box. |
|
Back to top |
|
|
eccerr0r Watchman
Joined: 01 Jul 2004 Posts: 9679 Location: almost Mile High in the USA
|
Posted: Thu Dec 25, 2014 1:32 am Post subject: |
|
|
Yes it's supposed to be real easy, just execute that file linux.efi in the UEFI environment, and boom, instant linux as long as secure boot is off.
Except for me I get a hang. No screen switch, no fuzzy characters, no blacked out screen (other than it printing nothing)... dead. _________________ Intel Core i7 2700K/Radeon R7 250/24GB DDR3/256GB SSD
What am I supposed watching? |
|
Back to top |
|
|
Progman3K l33t
Joined: 03 Jan 2004 Posts: 773
|
Posted: Thu Dec 25, 2014 2:17 am Post subject: |
|
|
eccerr0r wrote: | Except for me I get a hang. No screen switch, no fuzzy characters, no blacked out screen (other than it printing nothing)... dead. |
I hope I'm not asking a dumb question but can you modify the kernel boot parameters? Are you certain quiet is not among them? If it is, you'll see nothing leading up to the hang. |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|