Results 1 to 24 of 24

Thread: How to install Kali with EFI and dualboot on Macbook Pro

  1. #1
    Join Date
    2013-Sep
    Posts
    7

    How to install Kali with EFI and dualboot on Macbook Pro

    I see a lot of people having trouble installing Kali with OSX on their Macbooks. These are the steps I took to do it, hopefully this will help some people out. If people have success with this method, I hope someone will make a better guide, maybe with some pictures to help others with the process...

    1) Download and install rEFInd (http://www.rodsbooks.com/refind/getting.html)

    2) Download the Kali ISO and burn it to a DVD.

    3) Install SuperGrubDisk2 to Fat32 formatted USB drive (http://www.supergrubdisk.org/super-grub2-disk/) using DD in OSX. In the terminal on an administrator account, use "sudo dd if="DRAG SGD ISO HERE" of=/dev/diskN bs=1m". /dev/diskN is the disk number of your USB drive. Your internal hdd is usually /dev/disk0. My USB was /dev/disk1.

    4) Using the disk utility in OSX, create a msdos (fat) partition for your Kali filesystem.

    5) Reboot your laptop, and boot Kali (recovery mode) from the disk.

    6) Start the Kali installer, proceed as normal to disk partitioning.

    7) Choose the manual partitioning option.

    8) /dev/sda1 will be a preexisting EFI System Partiton and the installer should automatically select this to be used as the EFI System Partition for the install. The next partition(s) will be your OSX filesystem and likely an OSX recovery partition. Select the partition you created in step 3, and make it an ext4 filesystem mounted as "/". This will be your Kali filesystem. Make note of the partition number, you will need it later. Create a swap partition if you please.

    9) Install the Kali filesystem.

    10) Install grub to your Kali filesystem partition (/dev/sdaN). N being the disk number you made note of in step 7.

    11) Finish installation and reboot

    12) Boot into the SuperGrubDisk2 USB you created in step 2. Select the option to use a grub.conf file and select the grub.conf file on your Kali partition. Next highlight Kali (recovery mode) and press "e" to edit the grub.conf file before booting. At the end of the kernel boot line add the option "nouveau.modeset=0" and press F10 to boot into Kali.

    13) Open a terminal and use the following:

    a) "mkdir /boot/efi"
    b) "mount /dev/sda1 /boot/efi"
    c) "apt-get install grub-efi-amd64"
    d) "grub-install"
    e) "update-grub"

    14) Install the Nvidia driver for your discrete graphics card using the instructions provided in the Kali documentation (http://docs.kali.org/general-use/ins...-on-kali-linux)

    15) Reboot and enjoy
    Last edited by Beasleyboy; 2014-02-28 at 10:25.

  2. #2
    Join Date
    2014-Feb
    Posts
    3
    Thanks for putting this together. I went through the steps, but I'm still unsuccessful in booting into Kali from the rEFInd boot menu.

    I'm assuming you are using the 2.0 beta version of SuperGrubDisk2 as the 1.X version does not have an option to boot using F10. Adding the nouveau.modeset=0 line to the conf file didn't appear to do anything for me as I'm still getting the no boot disk error after installing grub from the terminal. Also, you forgot the hyphen in 13)e) "update-grub".

    Edit: I think I may have missed a space in the "mount /dev/sda1 /boot/efi" command so I'll see if this helps.

    Thanks!

  3. #3
    Join Date
    2014-Feb
    Posts
    9
    Can someone please offer some clarification to this. I'm admittedly not great with Linux command line bit have worked very carefully thought the above steps and am dead ending at:
    12) Boot into the SuperGrubDisk2 USB you created in step 2. Select the option to use a grub.conf file and select the grub.conf file on your Kali partition. Next highlight Kali (recovery mode) and press "e" to edit the grub.conf file before booting. At the end of the kernel boot line add the option "nouveau.modeset=0" and press F10 to boot into Kali.

    When I press 'e' I get a single line pointing to a .cfg file on my Kali partition. Do I just add nouveau.modeset=0 after the .cfg? The editor won't boot with that... Also, as mentioned by the above poster, there is no f10 boot option. There is a ctrl-x to boot... My supergrubdisk2 says v1.98...

    Anyhow, if I proceed without the added option, the Kali boot hangs. If I return to refind and select Kali, it still says no bootable disk.

    Thanks

  4. #4
    Join Date
    2013-Sep
    Posts
    7
    Quote Originally Posted by bgibson72 View Post
    Thanks for putting this together. I went through the steps, but I'm still unsuccessful in booting into Kali from the rEFInd boot menu.

    I'm assuming you are using the 2.0 beta version of SuperGrubDisk2 as the 1.X version does not have an option to boot using F10. Adding the nouveau.modeset=0 line to the conf file didn't appear to do anything for me as I'm still getting the no boot disk error after installing grub from the terminal. Also, you forgot the hyphen in 13)e) "update-grub".

    Edit: I think I may have missed a space in the "mount /dev/sda1 /boot/efi" command so I'll see if this helps.

    Thanks!
    Are you still having problems? Let me know if you were able to get it to work

    Quote Originally Posted by Mad Medik View Post
    Can someone please offer some clarification to this. I'm admittedly not great with Linux command line bit have worked very carefully thought the above steps and am dead ending at:
    12) Boot into the SuperGrubDisk2 USB you created in step 2. Select the option to use a grub.conf file and select the grub.conf file on your Kali partition. Next highlight Kali (recovery mode) and press "e" to edit the grub.conf file before booting. At the end of the kernel boot line add the option "nouveau.modeset=0" and press F10 to boot into Kali.

    When I press 'e' I get a single line pointing to a .cfg file on my Kali partition. Do I just add nouveau.modeset=0 after the .cfg? The editor won't boot with that... Also, as mentioned by the above poster, there is no f10 boot option. There is a ctrl-x to boot... My supergrubdisk2 says v1.98...

    Anyhow, if I proceed without the added option, the Kali boot hangs. If I return to refind and select Kali, it still says no bootable disk.

    Thanks
    You need the supergrubdisk2 beta version 2.00 and above. They added EFI support
    Last edited by Beasleyboy; 2014-02-26 at 14:51. Reason: Clarification

  5. #5
    Join Date
    2014-Feb
    Posts
    9
    Thanks for the reply. I will take a look at that.

  6. #6
    Join Date
    2014-Feb
    Posts
    3
    Quote Originally Posted by Beasleyboy View Post
    Are you still having problems? Let me know if you were able to get it to work



    You need the supergrubdisk2 beta version 2.00 and above. They added EFI support
    Yep, still having problems although I think the main issue MIGHT be that I am actually trying to install Kali to an external USB HDD connceted to my Macbook Pro. I only have the 128GB SSD, so dual boot isn't an option for me.

    I finally was able to get all the way to step 13 until I try the 'grub-install' command. I get the following output:

    Fatal: Couldn't open either sysfs or procfs directories for accessing EFI variables.
    Try 'modprobe efivars' as root.
    Fatal: Couldn't open either sysfs or procfs directories for accessing EFI variables.
    Try 'modprobe efivars' as root.
    Installation finished. No error reported.


    modprobe efivars only gets the following:
    ERROR: could not insert 'efivars': No such device

    I'm close to just giving up, although it is killing me that I had Kali on an external drive before...I just forgot how I went about doing it. I don't know if something was changed in either Kali from 1.0.4 to 1.0.6 or if it's an issue with Mac OS X 10.9.1-10.9.2.

    If you can help from here, that's great but I'm losing faith that this is even possible...

  7. #7
    Join Date
    2014-Feb
    Posts
    3
    Quote Originally Posted by Beasleyboy View Post
    Are you still having problems? Let me know if you were able to get it to work



    You need the supergrubdisk2 beta version 2.00 and above. They added EFI support
    I was having issues, but it was my fault because I was trying to install Kali to an external HDD, not the internal drive. I have the 128GB SSD, so dual boot is not an option for me...maybe when the price of SSDs drop, I will.

    At any rate, I had to modified the directions that you gave to get mine to work. Everything worked beautifully up until step 13. I had to specify the install device such as:

    grub-install --removeable /dev/sda1

    I'm not sure if the "--removeable" option is necessary, but it seemed to work. Then I used the command "update-grub /dev/sda1" and rebooted and it seems to have worked!

    Thanks a ton for your instruction, Beasleyboy!

  8. #8
    Join Date
    2014-Mar
    Posts
    2
    Thanks a lot for the instructions, Beasleyboy!

    I'm pretty new to all of this and I wanted to put out there one of the difficulties that I ran into and how I managed to fix it. I'm not totally clear what the problem was, so if anyone has an idea, please share!

    The first time I followed these instructions, it went basically without a problem. I could boot into Kali just fine from rEFInd. All was great. Then, not really knowing linux well, I ended up removing some packages that I shouldn't have and my installation started acting funny. I figured it would just be easier to reinstall and run through these instructions again.

    Not so easy the second time. Under OS X I mounted the EFI partition and removed the debian folder that was added, making the Kali EFI boot entry in the rEFInd menu disappear. Then I reformatted and installed Kali a second time. So far so good.

    My problem came when supergrubdisk2 wouldn't find anything at all. I couldn't boot Kali. I tried reinstalling grub from the liveUSB -- nope. I tried reinstalling Kali 3 different times, but nothing would make supergrubdisk2 find the Kali install.

    My solution was to find a way to run step 13 from the Kali LiveUSB, skipping the need for supergrubdisk.

    Here's what I did. It threw some errors, but it somehow worked.

    Instead of booting to supergrubdisk2, I booted to the liveUSB, then did the following:

    mount /dev/sdaN /mnt # N being the number of your Kali partition
    mount --bind /dev /mnt/dev
    mount --bind /dev/pts /mnt/dev/pts
    mount --bind /proc /mnt/proc
    mount --bind /sys /mnt/sys
    chroot /mnt

    Then follow with step 13 from above. There will be a few errors when you do grub-install, but when I restarted it worked.

    I have a vague idea of what's happening here, but perhaps someone with more knowledge would be able to explain the wisdom of this approach and/or the problem I was having!

  9. #9
    Join Date
    2013-Sep
    Posts
    7
    Quote Originally Posted by bgibson72 View Post
    I was having issues, but it was my fault because I was trying to install Kali to an external HDD, not the internal drive. I have the 128GB SSD, so dual boot is not an option for me...maybe when the price of SSDs drop, I will.

    At any rate, I had to modified the directions that you gave to get mine to work. Everything worked beautifully up until step 13. I had to specify the install device such as:

    grub-install --removeable /dev/sda1

    I'm not sure if the "--removeable" option is necessary, but it seemed to work. Then I used the command "update-grub /dev/sda1" and rebooted and it seems to have worked!

    Thanks a ton for your instruction, Beasleyboy!
    Awesome! I'm glad you got it to work, the external HD sounds like a very interesting approach...I'll have to play around with it.

  10. #10
    Join Date
    2014-Mar
    Posts
    1
    Hi, first off thanks, but when I run sudo apt-get install grub-efi-amd64 I get the package is not available but it is referenced. And then a few packages that replace it are listed. This must be a very recent change or something is wrong. I am connected to wifi, did sudo apt get update but still the same. Wondering if you could help. Thanks.

  11. #11
    Join Date
    2014-Mar
    Posts
    1
    Hi,

    I have problem with step 13.

    a) "mkdir /boot/efi"
    b) "mount /dev/sda1 /boot/efi"
    c) "apt-get install grub-efi-amd64"
    d) "grub-install"
    e) "update-grub"

    I tried to use "grub-install /dev/sda", is that correct? Either way it wont work.

  12. #12
    Join Date
    2013-Aug
    Location
    England
    Posts
    27
    Sorry I know this thread was last edited a few months back but I'm in the market for a new laptop to run kali on. I currently use a old IBM thinkpad T60 which is great to learn on and use as a test bed for new software etc but it lags and even crashes when running more intensive programs like brute forcing. I've been looking into the macbook pro line of machines but I don't wan to dual boot, I'd rather install kali as the main OS (of course I would take a disc image first!). My concern is that kali will not play ball. It works perfectly on the IBM when installing and using all the the ports and track pad etc. I've heard that thunderbolt doesn't work with linux but if I was to install kali as the main OS and then install the nvidia driver, would I have any other issues such as the back lit key board? Any suggestions would be grand Thanks very much in advance!

  13. #13
    Join Date
    2014-May
    Posts
    1
    IM bummed out!....Iv'e had way better success putting kali on the raspberry, but no luck on the mack...IVE BEEN ON IT FOR DAYS AND DAYS...(sigh)....Im ready to smash my laptop......TO PIECES......Theres gotta be away....plus ....im new at this , but very determined.....im also trying to install kali on an external hard drive...so far ive got snow leo, lion, and mavericks...WORKS REALLY GOOD!...USB.....BUT I WANT THE KALI ...I'm in the process of putting ubuntu on the external also...Its a 2TB external...I got it for 20bucks....ill be here, and thanks!

  14. #14
    Join Date
    2013-Oct
    Posts
    4
    Quote Originally Posted by klavo1 View Post
    IM bummed out!....Iv'e had way better success putting kali on the raspberry, but no luck on the mack...IVE BEEN ON IT FOR DAYS AND DAYS...(sigh)....Im ready to smash my laptop......TO PIECES......Theres gotta be away....plus ....im new at this , but very determined.....im also trying to install kali on an external hard drive...so far ive got snow leo, lion, and mavericks...WORKS REALLY GOOD!...USB.....BUT I WANT THE KALI ...I'm in the process of putting ubuntu on the external also...Its a 2TB external...I got it for 20bucks....ill be here, and thanks!
    https://forums.kali.org/showthread.p...-encrypted-USB

  15. #15
    For the record, there is a ticket in the bug tracker for adding EFI support (https://bugs.kali.org/view.php?id=680) which lets you track the progress of EFI being added into the master ISO.

    Some progress report. I uploaded live-build 3.0.5-1kali4 (to kali-proposed-updates) that knows how to enable EFI boot support by using syslinux 6. But syslinux 6 is only available in kali-dev for now because it likely breaks the build of debian-installer...

    That means that daily builds of kali-dev will have EFI support tomorrow:
    http://archive.kali.org/kali-daily-images/

    Feel free to test them and report back. If you're using the EFI support, your boot menu will be labeled "EFI Boot Menu", if you see only "Boot Menu" then you're using the BIOS boot method.
    This is a Kali-Linux support forum - not general IT/infosec help.

    Useful Commands: OS, Networking, Hardware, Wi-Fi
    Troubleshooting: Kali-Linux Installation, Repository, Wi-Fi Cards (Official Docs)
    Hardware: Recommended 802.11 Wireless Cards

    Documentation: http://docs.kali.org/ (Offline PDF version)
    Bugs Reporting & Tool Requests: https://bugs.kali.org/
    Kali Tool List, Versions & Man Pages: https://tools.kali.org/

  16. #16
    Join Date
    2014-Jul
    Posts
    3
    This works flawlessly ...except installing the NVIDIA driver. The default instructions call for the nvidia-current driver which is NOT efi compatible. From my experience installing ubuntu on my rMBP, you must use the 304 legacy drivers in order to use EFI. I'm probably simply overlooking the package, but I cannot find the legacy 304 driver in the Kali repo. So I downloaded and installed http://www.nvidia.com/Download/drive...px/77034/en-us (the latest x64 legacy driver I could find). After installing I still cannot start a functional xserver, but does however drop me to terminal instead of outright freezing. I tried this from an ubuntu install, but still fails to work.

    { edit /etc/X11/xorg.conf and add to the Device section:


    Option "UseDPLib" "off"

    edit /etc/default/grub and add “i915.lvds_channel_mode=2 i915.modeset=0 i915.lvds_use_ssc=0″ to GRUB_CMDLINE_LINUX_DEFAULT inside the double-quotes between the words “quiet splash“. Then run:


    sudo update-grub }

    To disable the intel graphics. Not working.

    Does anyone actually have a working Kali with EFI and NVIDIA drivers? If so, I'm curious to see what sorcery you performed. Maybe the key lies in a legacy nvidia 304 driver for Kali I cannot find.

    Thanks

  17. #17
    Since the release of 1.0.8, Kali now has EFI support out of the box!
    For more information: http://www.kali.org/news/kali-1-0-8-...-boot-support/
    This is a Kali-Linux support forum - not general IT/infosec help.

    Useful Commands: OS, Networking, Hardware, Wi-Fi
    Troubleshooting: Kali-Linux Installation, Repository, Wi-Fi Cards (Official Docs)
    Hardware: Recommended 802.11 Wireless Cards

    Documentation: http://docs.kali.org/ (Offline PDF version)
    Bugs Reporting & Tool Requests: https://bugs.kali.org/
    Kali Tool List, Versions & Man Pages: https://tools.kali.org/

  18. #18
    Join Date
    2014-Jul
    Posts
    3
    Unfortunately 1.0.8 fails to install altogether. Refind cannot/will not boot it in EFI mode. Booting it directly (from ISO burned to a disc) results in legacy BIOS mode which fails to install. I was suspicious at first because it wanted to make a GRUB partition on my drive (in my case being /dev/sda4) and upon reaching that point of the installation to install the bootloader, it totally failed installing on /dev/sda4.

    Maybe there is a specific argument that needs to be made for refind to boot it? Really had high hopes for an EFI release.

  19. #19
    Both on my MPB and MPA - Im now dual booting with OSX because of 1.0.8.

    I'll try and write up a tutorial for it before blackhat.



    Edit:
    Guide: http://docs.kali.org/installation/ka...n-mac-hardware
    Last edited by g0tmi1k; 2014-09-16 at 10:21.
    This is a Kali-Linux support forum - not general IT/infosec help.

    Useful Commands: OS, Networking, Hardware, Wi-Fi
    Troubleshooting: Kali-Linux Installation, Repository, Wi-Fi Cards (Official Docs)
    Hardware: Recommended 802.11 Wireless Cards

    Documentation: http://docs.kali.org/ (Offline PDF version)
    Bugs Reporting & Tool Requests: https://bugs.kali.org/
    Kali Tool List, Versions & Man Pages: https://tools.kali.org/

  20. #20
    Join Date
    2014-Jul
    Posts
    3
    Sweet! Anxious to see it. Are you using the nvidia driver as well?

  21. #21
    Join Date
    2014-Jul
    Posts
    1
    Quote Originally Posted by g0tmi1k View Post
    Both on my MPB and MPA - Im now dual booting with OSX because of 1.0.8.
    Not using refind.
    I'll try and write up a tutorial for it before blackhat.
    Can't wait until you release the tutorial, I'm trying hard to get kali on my MBP7.1 without refit.
    Long time ago, i found a solution to boot Ubuntu only with efi, but this does not work on kali :-(

  22. #22
    Join Date
    2014-Jul
    Location
    The Great Lonestar State of Texas!
    Posts
    18
    As all of us MacBook owners know, getting a dual-boot or standalone install is a real PITA -- especially if your 'SuperDrive' has the common issue of 'premature eject-ulation'!

    If you are having difficulties using the SuperGrub method, then I encourage you to check out the following threads completely -- read all of the posts (they are not very long):

    1. https://forums.kali.org/showthread.p...amp-Kali-Linux

    2. https://forums.kali.org/showthread.p...I-Install+Kali

    Good Luck!

    RoadRunnerTX

  23. #23
    Join Date
    2014-Nov
    Posts
    6
    i wonder know if this method can apply MBA ?(2012 year's)

  24. #24
    Join Date
    2015-Apr
    Posts
    2
    I know the last post is a while ago but this is exactly the thread i was looking for!

    I'm trying to boot Kali on a Macbook from an SD card. All went well until step 12...
    Im adding the nouveau.modeset=0 command but i still get the error:
    "nouveau [ DRM ] MM: using CRYPT for buffer copies
    I tried everything and i'm searching since week to resolve the error.. no luck.. Maybe you guys (and girls) can help me...

    My Environment:
    - Macbook: 15", mid 2009, MacBook5,3 , with 250 GB SSD (Samsung 840 EVO), 8 GB RAM
    - rEFInd 0.8.7 installed
    - Kali Linux 1.1.0a amd64
    - SuperGrub2 v2.00s2

    Screenshots:
    Selecting "Everything" in the SuperGrub2 Menu and then the grub.cfg entry from Kali (recovery mode)


    Adding nouveau.modeset=0 to the end of the document (also tried different positions)


    All resulting in this error


    I appreciate any help i can get!!
    thx

Similar Threads

  1. Impossible install Kali linux Dualboot in my pc?
    By miguelbohorquez in forum Installing Archive
    Replies: 1
    Last Post: 2019-09-22, 15:57
  2. Replies: 0
    Last Post: 2016-08-21, 23:05
  3. Kali dualboot install on MacBook Pro 2010
    By Leder in forum Installing Archive
    Replies: 0
    Last Post: 2016-02-03, 21:08
  4. Replies: 0
    Last Post: 2014-06-15, 09:32

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •