Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] Macbook Pro Install AMD64
View unanswered posts
View posts from last 24 hours

Goto page 1, 2  Next  
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
slugggerzzz
n00b
n00b


Joined: 07 Mar 2012
Posts: 57
Location: Manchester, UK

PostPosted: Tue Oct 09, 2012 12:35 pm    Post subject: [SOLVED] Macbook Pro Install AMD64 Reply with quote

Hi Guys,

I've had my Macbook pro for a year now, and well i'm fed up. Apple are tossers. I hate the way everything is.

Mountain Lion is slow, and its not the most advances OS in the world as they say.

So I use Gentoo on all my work servers and on my desktops. And well I'm going to stick it on the Macbook too.

I have done some reading and well there are some sticky bits when having online linux installed on the Macbook.

Could anyone shed some light on there experience on this ? or point me to some good documentation ?

Any input will be appreciated.
_________________
Slugggerzzz ...


Last edited by slugggerzzz on Tue Oct 16, 2012 10:00 am; edited 2 times in total
Back to top
View user's profile Send private message
avx
Advocate
Advocate


Joined: 21 Jun 2004
Posts: 2070

PostPosted: Tue Oct 09, 2012 2:35 pm    Post subject: Reply with quote

Which Macbook exactly? Gentoo only or alongside OSX?

http://phorcix.org/proj/g_mbp8/gentoo_mbp8.txt - this is the way I made my first install on a MBP8,1 last year. Since then, I've dropped rEFIt and GRUB(2) and am now having dual-boot Gentoo&OSX using only rEFInd.
_________________
++++++++++[>+++++++>++++++++++>+++>+<<<<-]>++.>+.+++++++..+++.>++.<<+++++++++++++++.>.+++.------.--------.>+.>.
Back to top
View user's profile Send private message
slugggerzzz
n00b
n00b


Joined: 07 Mar 2012
Posts: 57
Location: Manchester, UK

PostPosted: Tue Oct 09, 2012 2:55 pm    Post subject: Reply with quote

its a macbook 8,2. And its a gentoo only install. I have been doing some reading and people do not recommend this.

Thanks for the links i will drive into this tonight.

Is there any need to keep OSX ?
_________________
Slugggerzzz ...
Back to top
View user's profile Send private message
avx
Advocate
Advocate


Joined: 21 Jun 2004
Posts: 2070

PostPosted: Tue Oct 09, 2012 3:13 pm    Post subject: Reply with quote

If you've got no need for OSX, no, it's not needed to stay. You should make your mind up, if you prefer a GPT or MBR installation, based on that, the installation process varies a little.

If this should be your only computer, you should make sure you've got some medium which can really boot without hiccup on this machine. A few LiveCDs/-sticks still got problems related to the EFI. Arch Linux rolled out new .isos this week, which should work without problems.
_________________
++++++++++[>+++++++>++++++++++>+++>+<<<<-]>++.>+.+++++++..+++.>++.<<+++++++++++++++.>.+++.------.--------.>+.>.


Last edited by avx on Wed Oct 10, 2012 2:45 pm; edited 1 time in total
Back to top
View user's profile Send private message
slugggerzzz
n00b
n00b


Joined: 07 Mar 2012
Posts: 57
Location: Manchester, UK

PostPosted: Wed Oct 10, 2012 2:34 pm    Post subject: Reply with quote

Thanks for you input.

I think i will go with GPT, reason being i mainly stick with MSDOS and well may as well learn the difference.

I really wish there was some good standard documentation out there for this.

_

I did my first install which was a failure.

when i boot there looks to be no bootable drive.

and a folder symbol with a question mark flashes on the screen.

Seen this before ?
_________________
Slugggerzzz ...
Back to top
View user's profile Send private message
avx
Advocate
Advocate


Joined: 21 Jun 2004
Posts: 2070

PostPosted: Wed Oct 10, 2012 2:47 pm    Post subject: Reply with quote

Which bootloader did you try?
_________________
++++++++++[>+++++++>++++++++++>+++>+<<<<-]>++.>+.+++++++..+++.>++.<<+++++++++++++++.>.+++.------.--------.>+.>.
Back to top
View user's profile Send private message
slugggerzzz
n00b
n00b


Joined: 07 Mar 2012
Posts: 57
Location: Manchester, UK

PostPosted: Wed Oct 10, 2012 9:55 pm    Post subject: Reply with quote

i couldn't get refind installed, for i tried UEFI.

And well i couldn't seems to get that installed, end of the document get vague.

I was following this document...

http://en.gentoo-wiki.com/wiki/UEFI

and well went smoothly until i hit the end bit on the EFI shell.

I have left my install as is atm. I have it all set up. just need to either boot into the complied kernel somehow or figure out the end bit.

some guidance on this would be appreciated.
_________________
Slugggerzzz ...
Back to top
View user's profile Send private message
srs5694
Guru
Guru


Joined: 08 Mar 2004
Posts: 432
Location: Woonsocket, RI

PostPosted: Wed Oct 10, 2012 11:53 pm    Post subject: Reply with quote

slugggerzzz wrote:
i couldn't get refind installed, for I tried UEFI.
...
some guidance on this would be appreciated.


You'll need to be much more specific. "I couldn't get refind installed" doesn't say what you tried (the install.sh script or a manual install; from OS X or Linux) or what went wrong. It's also unclear what you mean by "for I tried UEFI"; according to the rules of English grammar, that suggests that you're blaming UEFI for your failure to install rEFInd, but I suspect that's not your intent.
Back to top
View user's profile Send private message
avx
Advocate
Advocate


Joined: 21 Jun 2004
Posts: 2070

PostPosted: Thu Oct 11, 2012 12:10 am    Post subject: Reply with quote

Installing rEFInd is no magic, really(though I still didn't get those .bmp overlays to work).

Judging from what I could understand from your post, you're now trying to boot with Apple's bootloader, I'm not sure if that's possible at all.
_________________
++++++++++[>+++++++>++++++++++>+++>+<<<<-]>++.>+.+++++++..+++.>++.<<+++++++++++++++.>.+++.------.--------.>+.>.
Back to top
View user's profile Send private message
slugggerzzz
n00b
n00b


Joined: 07 Mar 2012
Posts: 57
Location: Manchester, UK

PostPosted: Thu Oct 11, 2012 8:51 am    Post subject: Reply with quote

srs5694 if had read the whole post you would of understood what i was saying.

Also that is not a rule in the English grammar, that is purely your interpretation on the small amount of the post you read.

I'm sorry for any mistypes in my post/

I understand I'm new to this.

I am pursuing the rEFInd method.

I am doing the manual install as the install script does not work.

sda1 is mounted at /boot/efi

my rEFInd DIR is as follows:

Code:

livecd refind # pwd
/boot/efi/EFI/refind
livecd refind # ls
AutoGen.c   config.h          global.h  lib.h        refind.conf.sample
AutoGen.h   driver_support.c  icns.c    main.c       refind_x64.efi
Make.tiano  driver_support.h  icns.h    menu.c       screen.c
Makefile    drivers_ia32      icons     menu.h       screen.h
config.c    drivers_x64       lib.c     refind.conf


I run the following command:
Code:
efibootmgr -c -l \\EFI\\refind\\refind_x64.efi -L rEFInd


And get the following output:
Code:

Fatal: Couldn't open either sysfs or procfs directories for accessing EFI variables.
Try 'modprobe efivars' as root.
[quote]

Is this to do with me only being chrooted into the environment[/quote]
and not booting to a kernel with EFI support ?
_________________
Slugggerzzz ...
Back to top
View user's profile Send private message
khayyam
Advocate
Advocate


Joined: 07 Jun 2012
Posts: 2184

PostPosted: Thu Oct 11, 2012 9:24 am    Post subject: Reply with quote

slugggerzzz wrote:
/boot/efi/EFI/refind

slugggerzzz ... I assume that this is {ESP}/EFI/refind and that {ESP} is mounted to /boot/efi ...

slugggerzzz wrote:
Code:
Fatal: Couldn't open either sysfs or procfs directories for accessing EFI variables.

Is this to do with me only being chrooted into the environment and not booting to a kernel with EFI support ?

Yes, basically, you need to be booted via efi to access efi, so the livecd isn't suitable. You could use a different bootable CD that supports efi, as avx suggested, or you you can use the efi spec default location and use Apple's "Boot EFI" to load it.

So, your efi executable would be placed in {ESP}/efi/boot/bootx64.efi (this could be a efi stub kernel, or other bootloader/bootmanager such as rEFInd), you then boot and hold down the 'alt' key and you should be able to select the above. Once booted (EFI) you can then load 'efivars' (module) and run efibootmgr.

best ... khay
Back to top
View user's profile Send private message
slugggerzzz
n00b
n00b


Joined: 07 Mar 2012
Posts: 57
Location: Manchester, UK

PostPosted: Thu Oct 11, 2012 11:46 am    Post subject: Reply with quote

Thanks.

Right i have now got rEFInd working.

I can boot up to the menu.

I have edited the redind.conf file as follows.

Code:

timeout 5
scan_driver_dirs drivers,EFI/tools/drivers
scanfor manual,external

menuentry Gentoo {
    icon \EFI\refind\icons\os_gentoo.icns
    volume 0:
    loader \kernels\bzImage.efi
    options "root=/dev/sda3 ro"


I renamed my kernel to bzImage.efi and copyied it to:
Code:
/boot/efi/kernels


and when i boot and attempt to boot the kernel it returns:
Quote:

Starting bzImage.efi
Error: Unsupported while loading bzImage.efi


Any Ideas ?
_________________
Slugggerzzz ...
Back to top
View user's profile Send private message
slugggerzzz
n00b
n00b


Joined: 07 Mar 2012
Posts: 57
Location: Manchester, UK

PostPosted: Thu Oct 11, 2012 12:25 pm    Post subject: Reply with quote

also i dont need a ramdisk to boot do i ?

just boot to the kernel ?
_________________
Slugggerzzz ...
Back to top
View user's profile Send private message
khayyam
Advocate
Advocate


Joined: 07 Jun 2012
Posts: 2184

PostPosted: Thu Oct 11, 2012 1:02 pm    Post subject: Reply with quote

slugggerzzz wrote:
I have edited the redind.conf file as follows.

Code:
timeout 5
scan_driver_dirs drivers,EFI/tools/drivers
scanfor manual,external

menuentry Gentoo {
    icon \EFI\refind\icons\os_gentoo.icns
    volume 0:
    loader \kernels\bzImage.efi
    options "root=/dev/sda3 ro"

The menuentry is missing the closing curly brace.

slugggerzzz wrote:
Starting bzImage.efi
Error: Unsupported while loading bzImage.efi

hmmm ... is this infact an efi execuatble, are the following enabled?

CONFIG_EFI=y
CONFIG_RELOCATABLE=y
CONFIG_EFI_PARTITION=y
CONFIG_EFI_VARS=m
CONFIG_EFI_STUB=y

... and no, no initramfs.img is required.

best ... khay
Back to top
View user's profile Send private message
slugggerzzz
n00b
n00b


Joined: 07 Mar 2012
Posts: 57
Location: Manchester, UK

PostPosted: Thu Oct 11, 2012 3:30 pm    Post subject: Reply with quote

how would i make my kernel efi executable ?

I have enabled the efi options in the kernel.

what is the correct way to make a kernel efi executable ?

and sorry i missed the end
Code:
}
off my post; its in my config file.
_________________
Slugggerzzz ...
Back to top
View user's profile Send private message
khayyam
Advocate
Advocate


Joined: 07 Jun 2012
Posts: 2184

PostPosted: Thu Oct 11, 2012 4:06 pm    Post subject: Reply with quote

slugggerzzz wrote:
how would i make my kernel efi executable?

slugggerzzz ... as I pointed to above, by enabling the various options in the kernel. In the absence of any obvious reason why it wouldn't load I went for the obvious cause.

best ... khay
Back to top
View user's profile Send private message
avx
Advocate
Advocate


Joined: 21 Jun 2004
Posts: 2070

PostPosted: Thu Oct 11, 2012 5:03 pm    Post subject: Reply with quote

I'm not using any of the menu-entries myself, I just included the kernel options in the built-in kernel-cmdline, renamed the kernel to vmlinuz-$version.efi, placed it in EFI/gentoo/vmlinuz... and rEFInd picked it up without any more configuration on my part. I tried it once with an menu entry, but that didn't show up for some odd reason, so I've gone the path layed out before and never looked back.
_________________
++++++++++[>+++++++>++++++++++>+++>+<<<<-]>++.>+.+++++++..+++.>++.<<+++++++++++++++.>.+++.------.--------.>+.>.
Back to top
View user's profile Send private message
slugggerzzz
n00b
n00b


Joined: 07 Mar 2012
Posts: 57
Location: Manchester, UK

PostPosted: Thu Oct 11, 2012 7:57 pm    Post subject: Reply with quote

could you please post you refind.conf config ?

My kernel will not boot. It is attempting to boot and fails.

I have also tested booting from the refit CD with the same end game.

it attempt the boot and then freezes.
_________________
Slugggerzzz ...
Back to top
View user's profile Send private message
avx
Advocate
Advocate


Joined: 21 Jun 2004
Posts: 2070

PostPosted: Thu Oct 11, 2012 8:47 pm    Post subject: Reply with quote

Well, then there's something wrong with your kernel config. My refind.conf only has things for styling in it, nothing related to booting.

But sure, here you go
Code:
grep -v "#" refind.conf
timeout 5
hideui all
icons_dir icns
selection_big bmps/selection-big.bmp
resolution 1280 800
use_graphics_for osx,linux
scanfor external,biosexternal,internal,hdbios
max_tags 1


/dev/sda1 is the ESP for me, vfat formatted. It's mounted to /mnt/boot and in there is
Code:
ls **/
APPLE  gentoo  refind
finally, /mnt/boot/EFI/gentoo is bind-mounted to /boot so the kernel install scripts work properly.

Edit, if you want to check out my kernel config, here is the one I'm currently using:
http://phorcix.org/proj/g_mbp8/mbp81-config.txt
_________________
++++++++++[>+++++++>++++++++++>+++>+<<<<-]>++.>+.+++++++..+++.>++.<<+++++++++++++++.>.+++.------.--------.>+.>.
Back to top
View user's profile Send private message
slugggerzzz
n00b
n00b


Joined: 07 Mar 2012
Posts: 57
Location: Manchester, UK

PostPosted: Thu Oct 11, 2012 10:40 pm    Post subject: Reply with quote

That is brilliant, a real help.

Right i think I'm almost there.

Please could you take a look at the following picture.

http://tinypic.com/r/2h5iogn/6

This happened when i booted the kernel.

Its a clean error; not sure what i need to do here thought.

If there is anymore config files that would make this easier to solve please let me know and i will post them straight up.
_________________
Slugggerzzz ...
Back to top
View user's profile Send private message
avx
Advocate
Advocate


Joined: 21 Jun 2004
Posts: 2070

PostPosted: Thu Oct 11, 2012 11:28 pm    Post subject: Reply with quote

Clearly the kernel boots, thus rEFInd itself is working so far.

It obviously fails to find a valid /-partition, so either you screwed up passing the correct value to the kernel or you forgot to include (as in not as a module) the support for your filesystem on your root partition.

If you're not using the menu-entry in refind.conf, then AFAIK you must pass arguments to the kernel in the kernel's built-in cmdline, which for me is:
Code:
CONFIG_CMDLINE_BOOL=y
CONFIG_CMDLINE="root=/dev/sda4 quiet loglevel=0"

_________________
++++++++++[>+++++++>++++++++++>+++>+<<<<-]>++.>+.+++++++..+++.>++.<<+++++++++++++++.>.+++.------.--------.>+.>.
Back to top
View user's profile Send private message
srs5694
Guru
Guru


Joined: 08 Mar 2004
Posts: 432
Location: Woonsocket, RI

PostPosted: Thu Oct 11, 2012 11:41 pm    Post subject: Reply with quote

slugggerzzz wrote:
srs5694 if had read the whole post you would of understood what i was saying.


I did read the whole post; it provided insufficient diagnostic information. That's moot, though, with the back-and-forth between then and now....

slugggerzzz wrote:
Please could you take a look at the following picture.

http://tinypic.com/r/2h5iogn/6

This happened when i booted the kernel.

Its a clean error; not sure what i need to do here thought.


About 1/2 of the way down, you'll see this:

Quote:
Code:
VFS: Cannot open root device ("null") or unknown-block(0,0): error -6


In other words, either the "root=/dev/sda3" specification you passed was incorrect or (more likely) you need an initial RAM disk (initrd or initramfs) to boot your system because the main kernel file lacks some critical driver or feature. Note that your output goes on to list /dev/sda1, /dev/sda2, and /dev/sda3 as available devices; however, in my experience that doesn't necessarily mean that the kernel has everything that's needed. Personally, I gave up on non-initrd boots quite some time ago, but I gather there are still people who use them. If you're one of them, I recommend you carefully review your kernel configuration; or you could build an initrd just to see if it helps, and then work out what you need to change from a working system.
Back to top
View user's profile Send private message
khayyam
Advocate
Advocate


Joined: 07 Jun 2012
Posts: 2184

PostPosted: Fri Oct 12, 2012 5:19 am    Post subject: Reply with quote

slugggerzzz wrote:
If there is anymore config files that would make this easier to solve please let me know and i will post them straight up.

slugggerzzz ... generally you would make available your kernel config, disk partition layout ('gdisk -l') and fstab, the output of 'lspci -k' ... basically, information that we can corrolate with the problem.

slugggerzzz wrote:
http://tinypic.com/r/2h5iogn/6
Code:
VFS: Cannot open root device ("null") or unknown-block(0,0): error -6

This looks to me as if CONFIG_SATA_AHCI is missing (see: What does "VFS: Cannot open root device..." mean). I assume the disk was partitioned as GPT (that is, you used 'gdisk' rather than 'fdisk'), but most likely this is a missing driver issue.

slugggerzzz wrote:
Its a clean error; not sure what i need to do here thought.

What would an "unclean error" look like in this instance?

best ... khay
Back to top
View user's profile Send private message
slugggerzzz
n00b
n00b


Joined: 07 Mar 2012
Posts: 57
Location: Manchester, UK

PostPosted: Sun Oct 14, 2012 7:24 pm    Post subject: Reply with quote

Hmm, still cant get my kernel booting.

I used gdisk and GPT.

Kernel config is available at:
http://txtup.net/pR7wG

fstab
Code:

/dev/sda1      /boot/efi   fat32      noauto,noatime   1 2
/dev/sda3      /      ext3      noatime      0 1
/dev/sda2      none      swap      sw      0 0
/dev/cdrom      /mnt/cdrom   auto      noauto,ro   0 0
#/dev/fd0      /mnt/floppy   auto      noauto      0 0


gdisk print
Code:

Number  Start (sector)    End (sector)  Size       Code  Name
   1            2048          206847   100.0 MiB   0700  Linux filesystem
   2          206848         6350847   2.9 GiB     8300  Linux filesystem
   3         6350848       625142414   295.1 GiB   8300  Linux filesystem


lspci -k
Code:

livecd ~ # lspci -k
00:00.0 Host bridge: Intel Corporation 2nd Generation Core Processor Family DRAM Controller (rev 09)
        Subsystem: Apple Inc. Device 00db
00:01.0 PCI bridge: Intel Corporation Xeon E3-1200/2nd Generation Core Processor Family PCI Express Root Port (rev 09)
        Kernel driver in use: pcieport
00:01.1 PCI bridge: Intel Corporation Xeon E3-1200/2nd Generation Core Processor Family PCI Express Root Port (rev 09)
        Kernel driver in use: pcieport
00:02.0 VGA compatible controller: Intel Corporation 2nd Generation Core Processor Family Integrated Graphics Controller (rev 09)
        Subsystem: Apple Inc. Device 00db
00:16.0 Communication controller: Intel Corporation 6 Series/C200 Series Chipset Family MEI Controller #1 (rev 04)
        Subsystem: Intel Corporation Device 7270
00:1a.0 USB controller: Intel Corporation 6 Series/C200 Series Chipset Family USB Universal Host Controller #5 (rev 05)
        Subsystem: Intel Corporation Device 7270
        Kernel driver in use: uhci_hcd
        Kernel modules: uhci-hcd
00:1a.7 USB controller: Intel Corporation 6 Series/C200 Series Chipset Family USB Enhanced Host Controller #2 (rev 05)
        Subsystem: Intel Corporation Device 7270
        Kernel driver in use: ehci_hcd
        Kernel modules: ehci-hcd
00:1b.0 Audio device: Intel Corporation 6 Series/C200 Series Chipset Family High Definition Audio Controller (rev 05)
        Subsystem: Intel Corporation Device 7270
        Kernel driver in use: snd_hda_intel
        Kernel modules: snd-hda-intel
00:1c.0 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 1 (rev b5)
        Kernel driver in use: pcieport
00:1c.1 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 2 (rev b5)
        Kernel driver in use: pcieport
00:1c.2 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 3 (rev b5)
        Kernel driver in use: pcieport
00:1d.0 USB controller: Intel Corporation 6 Series/C200 Series Chipset Family USB Universal Host Controller #1 (rev 05)
        Subsystem: Intel Corporation Device 7270
        Kernel driver in use: uhci_hcd
        Kernel modules: uhci-hcd
00:1d.7 USB controller: Intel Corporation 6 Series/C200 Series Chipset Family USB Enhanced Host Controller #1 (rev 05)
        Subsystem: Intel Corporation Device 7270
        Kernel driver in use: ehci_hcd
        Kernel modules: ehci-hcd
00:1f.0 ISA bridge: Intel Corporation HM65 Express Chipset Family LPC Controller (rev 05)
        Subsystem: Intel Corporation Device 7270
00:1f.2 IDE interface: Intel Corporation 6 Series/C200 Series Chipset Family 4 port SATA IDE Controller (rev 05)
        Subsystem: Intel Corporation Device 7270
        Kernel driver in use: ata_piix
        Kernel modules: ata_generic, pata_acpi, ata_piix
00:1f.3 SMBus: Intel Corporation 6 Series/C200 Series Chipset Family SMBus Controller (rev 05)
        Subsystem: Intel Corporation Device 7270
02:00.0 Ethernet controller: Broadcom Corporation NetXtreme BCM57765 Gigabit Ethernet PCIe (rev 10)
        Subsystem: Broadcom Corporation NetXtreme BCM57765 Gigabit Ethernet PCIe
        Kernel driver in use: tg3
        Kernel modules: tg3
02:00.1 SD Host controller: Broadcom Corporation NetXtreme BCM57765 Memory Card Reader (rev 10)
        Subsystem: Broadcom Corporation Device 0000
        Kernel driver in use: sdhci-pci
        Kernel modules: sdhci-pci
03:00.0 Network controller: Broadcom Corporation BCM4331 802.11a/b/g/n (rev 02)
        Subsystem: Apple Inc. AirPort Extreme
04:00.0 FireWire (IEEE 1394): LSI Corporation FW643 [TrueFire] PCIe 1394b Controller (rev 08)
        Subsystem: LSI Corporation Device 5900


I hope this will help solve my problem.
_________________
Slugggerzzz ...
Back to top
View user's profile Send private message
khayyam
Advocate
Advocate


Joined: 07 Jun 2012
Posts: 2184

PostPosted: Mon Oct 15, 2012 12:25 pm    Post subject: Reply with quote

slugggerzzz wrote:
Code:
Number  Start (sector)    End (sector)  Size       Code  Name
   1            2048          206847   100.0 MiB   0700  Linux filesystem
   2          206848         6350847   2.9 GiB     8300  Linux filesystem
   3         6350848       625142414   295.1 GiB   8300  Linux filesystem

slugggerzzz ... you didn't create an ESP (EFI System Partition) type code "EF00", so /dev/sda1 (with your efi executable) will not be recognised as such.

best ... khay
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
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