PDA

View Full Version : Install Kali Linux 2.0 (Sana) in UEFI Mode (Dual Boot Windows 8/8.1/10)



nehaljwani
2015-08-26, 08:58
This is a tiny tutorial for dual booting Kali Linux 2.0 (sana) with Windows 8/8.1/10 in UEFI Mode.


https://vimeo.com/137613660

Note: Your Windows installation has to be in UEFI mode. (To ensure, visit: https://vimeo.com/137618855)
Note: Please make sure you watch the video in at least 480p (1080p is also available).

Step 1. Make some space in Windows for installing Kali LInux.
Step 2. Create Bootable Installation Media (Use Win32 DiskImager in Windows or use dd in Linux) I used the disk: http://cdimage.kali.org/kali-2.0/kali-linux-2.0-amd64.iso
Step 3. Boot using this media in LEGACY BIOS/CMS mode. I know that Kali Linux 2.0 claims to support UEFI, but for me, it didn't work. Even the hypervisors Qemu and VMWare segfaulted.
Step 4. Create at least two partitions (I created swap and one for /). DO NOT create any bios_grub partition and DO NOT setup any boot loader. Continue with the installation, but skip setting up boot loader.
Step 5. Create Bootable Installation Media for any Linux Distribution, which is UEFI compatible, and supports live mode. I prefer System Rescue Disk: http://nchc.dl.sourceforge.net/project/systemrescuecd/sysresccd-x86/4.5.4/systemrescuecd-x86-4.5.4.iso . You can also use Ubuntu Installation Media. If you choose the latter, you can follow the tutorial: https://vimeo.com/137620480 and if you choose the former, follow the tutorial: https://vimeo.com/137686117
Step 6. Boot using this media in UEFI mode. Make sure it is UEFI, otherwise it won't work. Once booted, fire up a terminal and type the following to confirm:

[ -d /sys/firmware/efi ] && echo UEFI || echo BIOS
Step 7. Use gdisk to figure out which partition contains your Kali Linux installation. For me, it was /dev/sda4. Might be different for you. Type the following to figure it out.

gdisk -l /dev/sda
Step 8. Mount the Kali Linux partition to /mnt. Also mount (in bind mode) /dev /dev/pts /proc /sys

for i in /dev /dev/pts /proc /sys ; do mount -B $i /mnt/$i ; done
Step 9. Create the directory /mnt/boot/efi

mkdir -p /mnt/boot/efi
Step 10. Mount the EFI partition to the newly created directory. Use gdisk -l /dev/sda to figure that out. For me, it was /dev/sda1

mount /dev/sda1 /mnt/boot/efi
Step 11. Chroot into /mnt.

chroot /mnt "/bin/bash"
Step 12. Add sana repository, using the command: echo "deb http://http.kali.org/kali sana main non-free contrib" >> /etc/apt/sources.list

echo deb http://http.kali.org/kali sana main non-free contrib | tee -a /etc/apt/sources.list
Step 13. Update apt-get.

apt-get update
Step 14. Install grub-efi package.

apt-get install -y grub-efi
Step 15. Setup grub.

grub-mkconfig -o /boot/grub/grub.cfg
grub-install /dev/sda
Step 16. Reboot, boot into Kali, and run the following again:

grub-mkconfig -o /boot/grub/grub.cfg
Tada! Done!

Jerseyweed
2015-08-28, 07:12
Can't get system rescue disk to boot I've changed usb to boot first in bios I've manually selected the drive and I've disabled secure boot but no matter what I do I can't seem to get it to boot under uefi so I am unable to finish the setup can someone please help

nehaljwani
2015-08-28, 18:21
Instead of using system rescue disk, you can use any UEFI compatible linux media which allows you to spawn a terminal and chroot into the installed partition.

l0uch3
2015-10-06, 21:32
Hi, first of all thank you for the guide, it worked great up to this point;
after mounting like you do in the video I try to execute "grub-install /dev/sda" without quotation marks
This does not execute correctly and gives me the following error: "grub-install: error: cannot open 'boot/efi/EFI/Kali/grubx64.efi' : Input/Output error."

How do I fix this? Also if I would attempt to boot back into windows right now, would it work?

nehaljwani
2015-10-07, 09:06
@l0uch3, It seems like your EFI system partition is corrupt. You will need to repair it with dosfsck in linux or chkdsk in windows. Another solution is to create another EFI partition, mount it at /boot/efi and run that command again. You can create the EFI partition after shrinking an existing partition, and use gdisk to create the new one (size = 200MB).

If you have not meddled with the existing EFI partition, then yes, you should be able to boot back into Windows.

l0uch3
2015-10-07, 10:20
@l0uch3, It seems like your EFI system partition is corrupt. You will need to repair it with dosfsck in linux or chkdsk in windows. Another solution is to create another EFI partition, mount it at /boot/efi and run that command again. You can create the EFI partition after shrinking an existing partition, and use gdisk to create the new one (size = 200MB).

If you have not meddled with the existing EFI partition, then yes, you should be able to boot back into Windows.

Thank you for your quick response! I reviewed the steps that I took and figured that indeed nothing had affected my EFI partition, so I was able to boot fine into Windows 8 again, quite a relief.

Your second solution is one I found out about yesterday too, it however has another restriction according to the source I used; this 200MB partition has to be within the first 100Gb of the disk that houses the original EFI partition, this makes it difficult to resize a partitions to make space for the new EFI partition. If this is true, I prefer the first solution;

On a side note, can you explain how my EFI system partition would be corrupt while I can boot into Windows 8 fine?
Going from the first solution; if I run chkdsk on windows (and fix my EFI, if there is any fixing to be done), I simply have to redo the steps of the tutorial from where systemrescue live was used?

l0uch3
2015-10-07, 10:51
@l0uch3, It seems like your EFI system partition is corrupt. You will need to repair it with dosfsck in linux or chkdsk in windows. Another solution is to create another EFI partition, mount it at /boot/efi and run that command again. You can create the EFI partition after shrinking an existing partition, and use gdisk to create the new one (size = 200MB).

If you have not meddled with the existing EFI partition, then yes, you should be able to boot back into Windows.

Okay so, I answered your post before but I'm not sure if it's being moderated or I lost it somehow, here goes again;

Thank you for your quick response!

I booted fine back into windows 8 using UEFI, so I assume the EFI partition is fine; chkdsk came up clean and found nothing to fix, as for dosfsck I assume I have to run "dosfsck -a /dev/sda4" (4 is my EFI partition)? (I haven't tried dosfsck yet) But is there something wrong with the EFI partition in the first place if I can boot into windows 8 fine?

Secondly, I came accross something similar to your second solution however; the one I read had an extra restricition: the newly created EFI 200MB partition should be in FAT32 and reside within the first 100Gb of the disk that contains the original EFI partition. This makes it hard for an amateur like me to free up enough space for the new EFI partition without damaging windows recovery partitions etc.

On top of that, I have a Lenovo Flex2 preinstalled Win 8, meaning I have a ton of other partitions premade and no idea wether or not I can touch them to free up space for the new EFI partition.

nehaljwani
2015-10-07, 16:40
@l0uch3,
1) Well, you go through the UEFI specifications at http://www.uefi.org/specifications. I may have missed by accident, but I couldn't find anywhere a restriction (first 100GB or anything) on the location of the EFI System Partition(s).
2) Since chkdsk hasn't reported anything, it seems that somehow your ESP (EFI System Partition) is locked, so that it can't be accessed directly for writing anything into it. Which is kinda strange, probably some protection from damaging boot files.
3) I can help you with the commands inside Windows, to shrink an existing partition and create a 200MB EFI partition. Please go to run, type dismgmt.msc, and hit enter. Then share the output for the commands:
diskpart
list disk
sel disk 0
list vol
list par

l0uch3
2015-10-07, 17:02
output of the commands


Microsoft Windows [Version 6.3.9600]
(c) 2013 Microsoft Corporation. All rights reserved.

C:\windows\system32>diskpart

Microsoft DiskPart version 6.3.9600

Copyright (C) 1999-2013 Microsoft Corporation.
On computer: EOS

DISKPART> list disk

Disk ### Status Size Free Dyn Gpt
-------- ------------- ------- ------- --- ---
Disk 0 Online 238 GB 0 B *

DISKPART> sel disk 0

Disk 0 is now the selected disk.

DISKPART> list vol

Volume ### Ltr Label Fs Type Size Status Info
---------- --- ----------- ----- ---------- ------- --------- --------
Volume 0 C Windows8_OS NTFS Partition 180 GB Healthy Boot
Volume 1 D LENOVO NTFS Partition 25 GB Healthy
Volume 2 WINRE_DRV NTFS Partition 1000 MB Healthy Hidden
Volume 3 SYSTEM_DRV FAT32 Partition 260 MB Healthy System
Volume 4 PBR_DRV NTFS Partition 14 GB Healthy Hidden

DISKPART> list par

Partition ### Type Size Offset
------------- ---------------- ------- -------
Partition 1 Recovery 1000 MB 1024 KB
Partition 2 System 260 MB 1001 MB
Partition 3 OEM 1000 MB 1261 MB
Partition 4 Reserved 128 MB 2261 MB
Partition 5 Primary 180 GB 2389 MB
Partition 8 Unknown 1907 MB 182 GB
Partition 9 Unknown 14 GB 184 GB
Partition 6 Primary 25 GB 198 GB
Partition 7 Recovery 14 GB 223 GB

DISKPART>

I also have diskmgmt.msc open, awaiting your following instructions (sadly it seems to take very long for my posts to be approved by moderators)

l0uch3
2015-10-07, 17:48
924
http://i.imgur.com/40GRK8c.jpg

Okay, using a tool for windows called "EasyUEFI" I checked the entries that my UEFI boot had:
turns out there is an old kali entry from a previous failed installation (from before I knew that kali install didn't work in UEFI, so I followed the standard install which didn't work but added an entry to UEFI boot anyway).
The file path for this EFI is exactly the same (of course) as the one I failed to access in systemrescue live,
this seems to be the source of my problems. Would deleting the kali entry solve the "Input/Output" issue when attempting to grub-install from systemrescue? Or would it just delete the entry and leave the files...

nehaljwani
2015-10-08, 05:28
So, try this:
1) Delete that Kali entry, make sure secure boot it turned off in BIOS settings, and try to do that grub-install command again.
If that doesn't work:
2) Open an elevated command prompt in Windows and type:
diskpart
sel disk 0
sel par 5
shrink desired = 200 minimum = 200
create par efi
format fs = fat32
exit
Reboot using SystemRescueDisk (in UEFI Mode), mount kali installation to /mnt, mount the extra directories as shown in the post, mount this newly created 200MB partition to /mnt/boot/efi , and then chroot, and try the grub-install command again.

l0uch3
2015-11-10, 21:39
So, try this:
1) Delete that Kali entry, make sure secure boot it turned off in BIOS settings, and try to do that grub-install command again.
If that doesn't work:
2) Open an elevated command prompt in Windows and type:
diskpart
sel disk 0
sel par 5
shrink desired = 200 minimum = 200
create par efi
format fs = fat32
exit
Reboot using SystemRescueDisk (in UEFI Mode), mount kali installation to /mnt, mount the extra directories as shown in the post, mount this newly created 200MB partition to /mnt/boot/efi , and then chroot, and try the grub-install command again.

Sorry for the very late response.

But I confirm that the second option worked, I now have a working dual boot Kali win8 installation.
So for those who face the same issue as me and grub fails to install, here's your answer!

Lanyru
2015-12-22, 02:27
Step 5 doesn't work for me. I downloaded the latest version of System Rescue Disk and when i try to boot from my usb as UEFI the list pops up i choose Grapical Envi and then the screen is black like forever. I tried the exact same only booted from usb in BIOS mode and then i choose Graphical Envi and it goes as showed in the video, but should i really do it from BIOS boot ? or should i choose to do this another way ?

nehaljwani
2015-12-22, 09:35
Step 5 doesn't work for me. I downloaded the latest version of System Rescue Disk and when i try to boot from my usb as UEFI the list pops up i choose Grapical Envi and then the screen is black like forever. I tried the exact same only booted from usb in BIOS mode and then i choose Graphical Envi and it goes as showed in the video, but should i really do it from BIOS boot ? or should i choose to do this another way ?

You have to boot the system rescue disk in UEFI mode. Otherwise the boot entry cannot be added. Also, graphical environment is not necessary. You can also choose the 4th option: "64bit, disable Kernel-Mode-Settings" adn type the commands in the shell directly after that.

Lanyru
2015-12-22, 15:27
You have to boot the system rescue disk in UEFI mode. Otherwise the boot entry cannot be added. Also, graphical environment is not necessary. You can also choose the 4th option: "64bit, disable Kernel-Mode-Settings" adn type the commands in the shell directly after that.

First of all, thanks for your reply :)

I encounter the exact same problem with that option too, the screen just goes black and it does absolutely nothing for like 10 minutes that i've waited...
So i thought i should try this through kali live and i did this:


sudo fdisk -l
mount /dev/sda# /mnt
mount --bind /dev /mnt/dev
mount --bind /proc /mnt/proc
mount --bind /sys /mnt/sys
chroot /mnt
grub-install /dev/sda
grub-mkconfig -o boot/grub/grub.cfg

And it finds a background image, linux image, initrd image, but it wont find windows 8.1 while on the video tutorial i was watching it would find his windows 7 as well there...
so i dont get it really, is it supposed to be so complicated ?
Is there anything else i can try ?

nehaljwani
2015-12-22, 18:58
First of all, thanks for your reply :)

I encounter the exact same problem with that option too, the screen just goes black and it does absolutely nothing for like 10 minutes that i've waited...
So i thought i should try this through kali live and i did this:



And it finds a background image, linux image, initrd image, but it wont find windows 8.1 while on the video tutorial i was watching it would find his windows 7 as well there...
so i dont get it really, is it supposed to be so complicated ?
Is there anything else i can try ?

Did you boot Kali Live in UEFI mode? Are you able to boot into Kali now? If yes, then run the grub-mkconfig -o boot/grub/grub.cfg command from inside the installed kali.

Lanyru
2015-12-24, 01:20
Did you boot Kali Live in UEFI mode? Are you able to boot into Kali now? If yes, then run the grub-mkconfig -o boot/grub/grub.cfg command from inside the installed kali.

Turns out i installed linux in BIOS mode instead of UEFI, i just noticed there are 4 boot options on my boot menu. 1] Windows boot manager, 2] UEFI: USB, 3] DVD, 4] USB.
I installed linux in the 4th option USB, and i guess that this is not the right option ? Well, i formated and deleted the linux and swap partitions, but when i try to choose UEFI: USB option to install linux, it boots my already installed windows 8.1 directly. Is there a reason its not working ? cause right after i saw this happen i restarted and tried again to boot from option 4 which was successful and saw the linux installation options.

My laptop is K55DR model a8 APU, i used Rufus to make the amd64 kali linux iso bootable. Legacy mode is enabled for usb, since without it my laptop couldn't detect my usb as a boot device.

-As explained, with option 4, yes i could boot into kali live and open a terminal, but again, linux wouldn't have been installed in UEFI mode.

nehaljwani
2015-12-24, 12:15
Turns out i installed linux in BIOS mode instead of UEFI, i just noticed there are 4 boot options on my boot menu. 1] Windows boot manager, 2] UEFI: USB, 3] DVD, 4] USB.
I installed linux in the 4th option USB, and i guess that this is not the right option ? Well, i formated and deleted the linux and swap partitions, but when i try to choose UEFI: USB option to install linux, it boots my already installed windows 8.1 directly. Is there a reason its not working ? cause right after i saw this happen i restarted and tried again to boot from option 4 which was successful and saw the linux installation options.

My laptop is K55DR model a8 APU, i used Rufus to make the amd64 kali linux iso bootable. Legacy mode is enabled for usb, since without it my laptop couldn't detect my usb as a boot device.

-As explained, with option 4, yes i could boot into kali live and open a terminal, but again, linux wouldn't have been installed in UEFI mode.


As I have shown in the video, you *have* to install Kali Linux in *Legacy Mode*, boot the system rescue disk in *UEFI* mode, and then convert Kali Installation into UEFI mode, by setting up grub properly.

Lanyru
2015-12-24, 14:18
As I have shown in the video, you *have* to install Kali Linux in *Legacy Mode*, boot the system rescue disk in *UEFI* mode, and then convert Kali Installation into UEFI mode, by setting up grub properly.

Yes but, as i said...


...My laptop is K55DR model a8 APU, i used Rufus to make the amd64 kali linux iso bootable. Legacy mode is enabled for usb, since without it my laptop couldn't detect my usb as a boot device.

Meaning, when Legacy mode is off, my usb is NOT one of the options in the boot menu (Boot menu : 1] Windows boot manager, 2] DVD). If that's the problem, how can i fix this ?
Also, when making the usb bootable with Rufus, there are 3 options. 1] MBR - Bios or UEFI-CSM, 2] MBR - UEFI, 3] GPT - UEFI , i used the 1 option since the other 2 would give me an error.

nehaljwani
2015-12-24, 14:40
Meaning, when Legacy mode is off, my usb is NOT one of the options in the boot menu (Boot menu : 1] Windows boot manager, 2] DVD). If that's the problem, how can i fix this ?
Also, when making the usb bootable with Rufus, there are 3 options. 1] MBR - Bios or UEFI-CSM, 2] MBR - UEFI, 3] GPT - UEFI , i used the 1 option since the other 2 would give me an error.

While using Rufus, use MBR-BIOS.
Kali Linux Bootable has to be booted and installed when UEFI is off. Then, you follow https://vimeo.com/137686117 to create a bootable media for System Rescue Disk, and then boot it in UEFI mode.

Lanyru
2015-12-24, 15:20
While using Rufus, use MBR-BIOS.
Kali Linux Bootable has to be booted and installed when UEFI is off. Then, you follow https://vimeo.com/137686117 to create a bootable media for System Rescue Disk, and then boot it in UEFI mode.

Ok so, you're suggesting that i should install linux when Legacy is enabled, then make a sysrescued bootable, disable Legacy mode and it should find my usb as one of boot devices and work ?

nehaljwani
2015-12-24, 15:23
Ok so, you're suggesting that i should install linux when Legacy is enabled, then make a sysrescued bootable, disable Legacy mode and it should find my usb as one of boot devices and work ?

(i) Enable Legacy, install Kali in Legacy Mode. (Skip grub setup as shown in the video)
(ii) Disable Legacy, boot System Rescue Disk. (Do that command line stuff as shown in the video).

Lanyru
2015-12-25, 03:14
(i) Enable Legacy, install Kali in Legacy Mode. (Skip grub setup as shown in the video)
(ii) Disable Legacy, boot System Rescue Disk. (Do that command line stuff as shown in the video).

So, these are my bios options:

http://i.imgur.com/ggXX2YJ.jpg
http://i.imgur.com/sT5holv.jpg
http://i.imgur.com/3eOkojR.jpg

When i disable legacy mode for system rescue disk:

http://i.imgur.com/4G4hg0d.jpg

this happens, and i can't boot my usb anymore.

http://i.imgur.com/5CyyTqk.jpg

Im using the latest version of System Rescue Disk (4.6.1)
While if Legacy mode is Enabled, my system recognises the usb as bootable:

http://i.imgur.com/aUESoJi.jpg

So, i still can't get grub to work like that...

muratnite
2015-12-25, 03:53
Hello guys ı am new in Kali and ı am looking for a backup program like Acronics for Kali CAN ANYONE HELP ME in this Pease

nehaljwani
2015-12-25, 07:55
So, these are my bios options:

http://i.imgur.com/aUESoJi.jpg

So, i still can't get grub to work like that...

'Legacy USB' is umm... a bit different. You are getting confused. In the last image, you have to choose 'UEFI: KingstonDataTraveler 3.0PMAP'

Lanyru
2015-12-25, 14:00
'Legacy USB' is umm... a bit different. You are getting confused. In the last image, you have to choose 'UEFI: KingstonDataTraveler 3.0PMAP'

Yes, but after choosing graphical install or the 4th option that u suggested is when my screen goes black and nothing happens. i've waited for that screen 10 minutes, is it supposed to be like this ?

nehaljwani
2015-12-25, 15:36
Yes, but after choosing graphical install or the 4th option that u suggested is when my screen goes black and nothing happens. i've waited for that screen 10 minutes, is it supposed to be like this ?
Did you try all options? Nothing is present on the screen? If none of the options work for you, then create a bootable media using Ubuntu Installation media. You can follow: https://vimeo.com/137620480 . The command line stuff remains same.

Lanyru
2015-12-25, 18:16
Did you try all options? Nothing is present on the screen? If none of the options work for you, then create a bootable media using Ubuntu Installation media. You can follow: https://vimeo.com/137620480 . The command line stuff remains same.

None of the options work, what you do in this video is boot to ubuntu without installing, so, do i need to boot to kali live ?
I can't get to boot anything in UEFI, not even kali, they all can only boot in CMS :/
amd64 kali iso boots as it should in CMS but when i choose to boot it is UEFI: usb it goes directly to windows...
I've also downloaded EasyBcd and then i start it in windows 8.1 and i get an error that im in efi mode and that would limit the program.

nehaljwani
2015-12-25, 22:28
None of the options work, what you do in this video is boot to ubuntu without installing, so, do i need to boot to kali live ?
I can't get to boot anything in UEFI, not even kali, they all can only boot in CMS :/
amd64 kali iso boots as it should in CMS but when i choose to boot it is UEFI: usb it goes directly to windows...
I've also downloaded EasyBcd and then i start it in windows 8.1 and i get an error that im in efi mode and that would limit the program.
You can boot into Ubuntu installation media in UEFI mode and opt to not install it. The first option does that for you. Then you can follow the rest of the steps as shown in the video. It is mandatory that you boot it in UEFI mode, other wise the commands won't work. Since Kali Live doesn't boot in UEFI mode, I either use System Rescue Disk, or Ubuntu Installation media.

Lanyru
2015-12-26, 02:57
could you please point me to the link i need to download the ubuntu iso ? i've trying a few days to make dual boot work and i wanna know for sure im doing this step right. This might be my last try afterall...

nehaljwani
2015-12-26, 04:13
could you please point me to the link i need to download the ubuntu iso ? i've trying a few days to make dual boot work and i wanna know for sure im doing this step right. This might be my last try afterall...

http://releases.ubuntu.com/15.10/ubuntu-15.10-desktop-amd64.iso

noobiesmall
2015-12-26, 05:43
Latest Kali iso boots it UEFI fine! Just install it with network mirror and it will download the grub EFI files...

Lanyru
2015-12-26, 17:28
i used sudo -i cause terminal didnt have root access, and apt-get update gives me a few errors.
W: failed to fetch http://http.kali.org/kali/dists/sana/InRelease unable to find expected entry 'cont,/binary-amd64/Packages' in release file (wrong sources.list entry or malformed file)
E: some index files failed to download. they have been ignored or old ones used instead.

But it worked just fine, i have my grub menu now with both Kali GNU/Linux and Windows Boot Manager which i leafpad boot/grub/grub.cfg and renamed those names to the ones i like more :D
Thanks for your help, i really appreciate it.

HaraldGer123
2016-01-09, 15:56
i use ubuntu

I have a problem :(


Step 8. Mount the Kali Linux partition to /mnt. Also mount (in bind mode) /dev /dev/pts /proc /sys
Code:

for i in /dev /dev/pts /proc /sys ; do mount -B $i /mnt/$i ; done



i typed this and get following error :

sudo for i in /dev /dev/pts /proc /sys ; do mount -B $i /mnt/$i /mnt/$i ; done


bash: syntax error near unexpected token ´do'


??:(


edit :

i added a "SUDO" for all operations,

sudo for i in /dev /dev/pts /proc /sys ;sudo do mount -B $i /mnt/$i /mnt/$i ;sudo done


i get :

sudo : for : command not found
sudo do: command not found
sudo done: command not found

??

nehaljwani
2016-01-09, 17:53
You have to do either of these two in Ubuntu:

If you want to use sudo, then type:


for i in /dev /dev/pts /proc /sys ; do sudo mount -B $i /mnt/$i ; done

If you don't want to use sudo, then just type:


sudo su
for i in /dev /dev/pts /proc /sys ; do mount -B $i /mnt/$i ; done

HaraldGer123
2016-01-09, 19:41
i have following problem after i type those mount step in the rescue disc

okay it works running rescue disk

i get following error if i type the mounting step for i....

mount point /mnt//dev/pts does not exist

mount point /mnt// proc does not exist


mount point /mnt//sys does not exist

but my kali i installed, i see the partition

nehaljwani
2016-01-15, 04:54
mount point /mnt//dev/pts does not exist

mount point /mnt// proc does not exist


mount point /mnt//sys does not exist


Share output for the command:
sudo gdisk -l /dev/sda
Did you mount the correct partition to /mnt?

HaraldGer123
2016-01-19, 09:48
General: i followed all steps exactly. Boot UEFI with the rescue bootstick. here iam stucking now. Iam using a SSD with Win10 on it.

I also have a 64 bit OS. downloaded 64bit KALI ISO. and downloaded the rescue from the video in the tutorial.

i cannot go into the graphical user interface. my Screen is black and i have a prompt with:

root@sysresccd /root % _ ( here i can enter commands and followed with the commands i entered )

i entered follow commands in order :


[ -d /sys/firmware/efi ] && echo UEFI || echo BIOS

Output:
UEFI


gdisk -l /dev/sda

Output :

Number Start end size code name
1 2048 534527 260.0MiB EF00 EFI System partition
2 534528 186851327 88.8GiB 0700 Basic Data partition
3 186851327 188622847 864.0MiB 2700
4 188622848 198387711 4.7GiB 8200 (this is my swap )
5 198387712 250068991 24,6 GiB 8300 ( This is my / directory ) (root)


if i continue the guide i did this :


for i in /dev /dev/pts /proc /sys ; do mount -B $i /mnt/$i ; done

output :

mount: mount point /mnt//dev does not exist
mount: mount point /mnt//dev/pts does not exist
mount: mount point /mnt//proc does not exist
mount: mount point /mnt//sys does not exist



Should i continue with this: ?

fdisk -l
mount /dev/sda# /mnt
mount --bind /dev /mnt/dev
mount --bind /proc /mnt/proc
mount --bind /sys /mnt/sys
chroot /mnt
grub-install /dev/sda
grub-mkconfig -o boot/grub/grub.cfg

?

If you can make it happen that it works, i give you a bag with good german beer! :-P


EDIT: i followed with this command

for i in /dev /dev/pts /proc /sys ; do
mkdir -p /mnt/$i
mount -B $i /mnt/$i
done

and then i can enter

for i in /dev /dev/pts /proc /sys ; do mount -B $i /mnt/$i ; done

wihthout a problem


Now i stucking here

Step 11. Chroot into /mnt.
Code:


chroot /mnt "/bin/bash"

my output is:

chroot: failed to run command 'bin/bash' : no such file or directory

If i searching :

find /mn -name bash

He just jumps in the next line like he couldnt find anything

nehaljwani
2016-01-19, 13:06
if i continue the guide i did this :


for i in /dev /dev/pts /proc /sys ; do mount -B $i /mnt/$i ; done

output :

mount: mount point /mnt//dev does not exist
mount: mount point /mnt//dev/pts does not exist
mount: mount point /mnt//proc does not exist
mount: mount point /mnt//sys does not exist


You need to type...


mount /dev/sda5 /mnt
mkdir -p /mnt/boot/efi
mount /dev/sda1 /mnt/boot/efi
...before the for loop

HaraldGer123
2016-01-19, 13:13
thank you!! yes i can chroot.

Okay at the moment i dont have internet connection. Is it possible to turn off the system, and repeat the last steps

Step 12. Add sana repository, using the command: echo "deb http://http.kali.org/kali sana main non-free contrib" >> /etc/apt/sources.list
Code:

echo deb http://http.kali.org/kali sana main non-free contrib | tee -a /etc/apt/sources.list

Step 13. Update apt-get.
Code:

apt-get update

Step 14. Install grub-efi package.
Code:

apt-get install -y grub-efi

Step 15. Setup grub.
Code:

grub-mkconfig -o /boot/grub/grub.cfg
grub-install /dev/sda

Step 16. Reboot, boot into Kali, and run the following again:
Code:

grub-mkconfig -o /boot/grub/grub.cfg



to get it work?

I guess i need internet connection for complete this right? because of apt-get
Or do i need to follow all Steps again from the booting in rescue .

nehaljwani
2016-01-19, 13:24
If you have already done Step12, then you don't need to do it again on reboot. And yes, you need a working internet connection. If, even after having internet connection you get the error: "Unable to resolve http.kali.org", then type: echo "nameserver 8.8.8.8" > /etc/resolv.conf and try again.

HaraldGer123
2016-01-19, 13:35
nehaljwani you are my angel.

I try it at home and then i send you German Beer :-)

HaraldGer123
2016-01-20, 10:39
Hey!

So after all i can boot kali linux, coming to the grub-menü.

in my bootmanager i can select:

UEFI Boot Order
-> OS boot manager
-> Kali (Samsung....)
-> Windows Boot Manager(Samsung....)

i choose Kali on top.
If kali boots, i cannot select Windows 10
Just kali and a advanced mode.

If kali boots now, i get millions of Lines starting from[ 00.xxxx]


Nouveau EI Pbus......

[ 22.xxxxxx] nouveau E [ PFIF0] [ 0000:01:00.0] FB_Flush_timeout
[ 22.xxxxxx] nouveau E [ PFIF0] [ 0000:01:00.0] FB_Flush_timeout
[ 22.xxxxxx] nouveau E [ PFIF0] [ 0000:01:00.0] FB_Flush_timeout
[ 22.xxxxxx] nouveau E [ PFIF0] [ 0000:01:00.0] FB_Flush_timeout
[ 22.xxxxxx] nouveau E [ PFIF0] [ 0000:01:00.0] FB_Flush_timeout
[ 22.xxxxxx] nouveau E [ PFIF0] [ 0000:01:00.0] FB_Flush_timeout
[ 22.xxxxxx] nouveau E [ PFIF0] [ 0000:01:00.0] FB_Flush_timeout
[ 22.xxxxxx] nouveau E [ PFIF0] [ 0000:01:00.0] FB_Flush_timeout
[ 22.xxxxxx] nouveau E [ PFIF0] [ 0000:01:00.0] FB_Flush_timeout
[ 22.xxxxxx] nouveau E [ PFIF0] [ 0000:01:00.0] FB_Flush_timeout


Whats that now? Nouveau = something with graphic card ?
How can it be so complicated to install argggg :-)

i read something with bumblebee or something like that, can anyone give me advice how i should follow now?


my GPU
Intel® Core™ i7-6700HQ Prozessor
Intel(R) HD Graphics 530
NVIDIA GeForce GTX 950M Grafikkarte


i also found this :

Re: [Solved] Nouveau error spam on boot

I think I solved the problem by adding nouveau.modeset=0 to the kernel parameters. The error messages at boot are gone, and I can execute lspci without my laptop crashing.

Re: [Solved] Nouveau error spam on boot

Thank you so much, R13N!!! I've been going crazy trying to figure out why Arch won't boot and hangs on lspci with nouveau errors. Adding nouveau.modeset=0 to the kernel parameters solved my error too.



Should i test this? How do i add it directly to the kernel parameter?

nehaljwani
2016-01-20, 17:48
Should i test this? How do i add it directly to the kernel parameter?
When you select Kali, you will be presented with a grub menu. Press 'e' to edit and and then add nouveau.modeset=0 after 'ro quiet' and then press ctrl+x to boot.

HaraldGer123
2016-01-21, 08:30
It fucking works, i cant believe it !!!! :)))))) yeah this command with nouv set 0 solve the problem.
Can you explain maybe in detail just for interest why this error appeared and why this command solve it? ( Okay sounds like you turn it off because of the "0" ).


I have one thing left
If i update "apt-get update" i get this


The repository 'http://security.kali.org/kali-security kali/updates Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: The repository 'http://http.kali.org/kali kali Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: Failed to fetch http://security.kali.org/kali-security/dists/kali/updates/main/source/Sources 404 Not Found
W: Failed to fetch http://security.kali.org/kali-security/dists/kali/updates/contrib/source/Sources 404 Not Found
W: Failed to fetch http://security.kali.org/kali-security/dists/kali/updates/non-free/source/Sources 404 Not Found
W: Failed to fetch http://security.kali.org/kali-security/dists/kali/updates/main/binary-i386/Packages 404 Not Found
W: Failed to fetch http://security.kali.org/kali-security/dists/kali/updates/main/binary-amd64/Packages 404 Not Found
W: Failed to fetch http://security.kali.org/kali-security/dists/kali/updates/main/binary-armel/Packages 404 Not Found
W: Failed to fetch http://security.kali.org/kali-security/dists/kali/updates/main/binary-armhf/Packages 404 Not Found
W: Failed to fetch http://security.kali.org/kali-security/dists/kali/updates/contrib/binary-i386/Packages 404 Not Found
W: Failed to fetch http://http.kali.org/kali/dists/kali/main/source/Sources 404 Not Found
W: Failed to fetch http://http.kali.org/kali/dists/kali/contrib/source/Sources 404 Not Found
W: Failed to fetch http://http.kali.org/kali/dists/kali/non-free/source/Sources 404 Not Found
W: Failed to fetch http://http.kali.org/kali/dists/kali/main/binary-i386/Packages 404 Not Found
W: Failed to fetch http://http.kali.org/kali/dists/kali/main/binary-amd64/Packages 404 Not Found
W: Failed to fetch http://http.kali.org/kali/dists/kali/main/binary-armel/Packages 404 Not Found
W: Failed to fetch http://http.kali.org/kali/dists/kali/main/binary-armhf/Packages 404 Not Found
W: Failed to fetch http://http.kali.org/kali/dists/kali/contrib/binary-i386/Packages 404 Not Found
E: Some index files failed to download. They have been ignored, or old ones used instead.


I guess my source.list or something like that is wrong. I copied from a thread the "original" repositories but this error comes all the time.

EDIT: I asking myself where i can change the grub entries so that he displays the name in the grub menu i want. Iam a bit scared to write in the grub.cfg after all this. Is there a easy possibility?

nehaljwani
2016-01-21, 09:02
Make sure the sources.list file contains only this:


deb http://http.kali.org/kali sana main non-free contrib
deb http://security.kali.org/kali-security sana/updates main contrib non-free
# For source package access, uncomment the following line
# deb-src http://http.kali.org/kali sana main non-free contrib
# deb-src http://security.kali.org/kali-security sana/updates main contrib non-free

Edit the /etc/default/grub file and add 'nouveau.modeset=0' to the GRUB_CMDLINE_LINUX line and then run update-grub2. Then reboot.

HaraldGer123
2016-01-21, 13:25
Works like a charm.
Is it possible to change or rename the Entries which are displayed in the Grub-Menu @ booting? Or is this a bit complicated? otherwise i would drop it.

nehaljwani
2016-01-21, 15:57
Is it possible to change or rename the Entries which are displayed in the Grub-Menu @ booting? Or is this a bit complicated?
You can edit the file /boot/grub/grub.cfg after it has been generated.

HaraldGer123
2016-01-22, 07:28
Thank you very much !! I know it sounds strange, but is it also possible to change the background picture of the kali menu? I dont like it because you barely can read the options.

EDIT:

My Grub cfg looks like this :




#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### BEGIN /etc/grub.d/00_header ###
if [ -s $prefix/grubenv ]; then
set have_grubenv=true
load_env
fi
if [ "${next_entry}" ] ; then
set default="${next_entry}"
set next_entry=
save_env next_entry
set boot_once=true
else
set default="0"
fi

if [ x"${feature_menuentry_id}" = xy ]; then
menuentry_id_option="--id"
else
menuentry_id_option=""
fi

export menuentry_id_option

if [ "${prev_saved_entry}" ]; then
set saved_entry="${prev_saved_entry}"
save_env saved_entry
set prev_saved_entry=
save_env prev_saved_entry
set boot_once=true
fi

function savedefault {
if [ -z "${boot_once}" ]; then
saved_entry="${chosen}"
save_env saved_entry
fi
}
function load_video {
if [ x$feature_all_video_module = xy ]; then
insmod all_video
else
insmod efi_gop
insmod efi_uga
insmod ieee1275_fb
insmod vbe
insmod vga
insmod video_bochs
insmod video_cirrus
fi
}

if [ x$feature_default_font_path = xy ] ; then
font=unicode
else
insmod part_gpt
insmod ext2
set root='hd0,gpt5'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt5 --hint-efi=hd0,gpt5 --hint-baremetal=ahci0,gpt5 ebf56086-a05f-4eea-afb5-96378220f62e
else
search --no-floppy --fs-uuid --set=root ebf56086-a05f-4eea-afb5-96378220f62e
fi
font="/usr/share/grub/unicode.pf2"
fi

if loadfont $font ; then
set gfxmode=auto
load_video
insmod gfxterm
set locale_dir=$prefix/locale
set lang=en_US
insmod gettext
fi
terminal_output gfxterm
if [ "${recordfail}" = 1 ] ; then
set timeout=30
else
if [ x$feature_timeout_style = xy ] ; then
set timeout_style=menu
set timeout=5
# Fallback normal timeout code in case the timeout_style feature is
# unavailable.
else
set timeout=5
fi
fi
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/05_debian_theme ###
insmod part_gpt
insmod ext2
set root='hd0,gpt5'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt5 --hint-efi=hd0,gpt5 --hint-baremetal=ahci0,gpt5 ebf56086-a05f-4eea-afb5-96378220f62e
else
search --no-floppy --fs-uuid --set=root ebf56086-a05f-4eea-afb5-96378220f62e
fi
insmod png
if background_image /usr/share/images/desktop-base/kali-grub.png; then
set color_normal=white/black
set color_highlight=black/white
else
set menu_color_normal=cyan/blue
set menu_color_highlight=white/blue
fi
### END /etc/grub.d/05_debian_theme ###

### BEGIN /etc/grub.d/10_linux ###
function gfxmode {
set gfxpayload="${1}"
}
set linux_gfx_mode=
export linux_gfx_mode
menuentry 'Kali GNU/Linux' --class kali --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-ebf56086-a05f-4eea-afb5-96378220f62e' {
load_video
insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
insmod part_gpt
insmod ext2
set root='hd0,gpt5'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt5 --hint-efi=hd0,gpt5 --hint-baremetal=ahci0,gpt5 ebf56086-a05f-4eea-afb5-96378220f62e
else
search --no-floppy --fs-uuid --set=root ebf56086-a05f-4eea-afb5-96378220f62e
fi
echo 'Loading Linux 4.3.0-kali1-amd64 ...'
linux /boot/vmlinuz-4.3.0-kali1-amd64 root=UUID=ebf56086-a05f-4eea-afb5-96378220f62e ro nouveau.modeset=0 quiet
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-4.3.0-kali1-amd64
}
submenu 'Advanced options for Kali GNU/Linux' $menuentry_id_option 'gnulinux-advanced-ebf56086-a05f-4eea-afb5-96378220f62e' {
menuentry 'Kali GNU/Linux, with Linux 4.3.0-kali1-amd64' --class kali --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.3.0-kali1-amd64-advanced-ebf56086-a05f-4eea-afb5-96378220f62e' {
load_video
insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
insmod part_gpt
insmod ext2
set root='hd0,gpt5'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt5 --hint-efi=hd0,gpt5 --hint-baremetal=ahci0,gpt5 ebf56086-a05f-4eea-afb5-96378220f62e
else
search --no-floppy --fs-uuid --set=root ebf56086-a05f-4eea-afb5-96378220f62e
fi
echo 'Loading Linux 4.3.0-kali1-amd64 ...'
linux /boot/vmlinuz-4.3.0-kali1-amd64 root=UUID=ebf56086-a05f-4eea-afb5-96378220f62e ro nouveau.modeset=0 quiet
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-4.3.0-kali1-amd64
}
menuentry 'Kali GNU/Linux, with Linux 4.3.0-kali1-amd64 (recovery mode)' --class kali --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.3.0-kali1-amd64-recovery-ebf56086-a05f-4eea-afb5-96378220f62e' {
load_video
insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
insmod part_gpt
insmod ext2
set root='hd0,gpt5'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt5 --hint-efi=hd0,gpt5 --hint-baremetal=ahci0,gpt5 ebf56086-a05f-4eea-afb5-96378220f62e
else
search --no-floppy --fs-uuid --set=root ebf56086-a05f-4eea-afb5-96378220f62e
fi
echo 'Loading Linux 4.3.0-kali1-amd64 ...'
linux /boot/vmlinuz-4.3.0-kali1-amd64 root=UUID=ebf56086-a05f-4eea-afb5-96378220f62e ro single nouveau.modeset=0
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-4.3.0-kali1-amd64
}
menuentry 'Kali GNU/Linux, with Linux 4.0.0-kali1-amd64' --class kali --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.0.0-kali1-amd64-advanced-ebf56086-a05f-4eea-afb5-96378220f62e' {
load_video
insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
insmod part_gpt
insmod ext2
set root='hd0,gpt5'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt5 --hint-efi=hd0,gpt5 --hint-baremetal=ahci0,gpt5 ebf56086-a05f-4eea-afb5-96378220f62e
else
search --no-floppy --fs-uuid --set=root ebf56086-a05f-4eea-afb5-96378220f62e
fi
echo 'Loading Linux 4.0.0-kali1-amd64 ...'
linux /boot/vmlinuz-4.0.0-kali1-amd64 root=UUID=ebf56086-a05f-4eea-afb5-96378220f62e ro nouveau.modeset=0 quiet
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-4.0.0-kali1-amd64
}
menuentry 'Kali GNU/Linux, with Linux 4.0.0-kali1-amd64 (recovery mode)' --class kali --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.0.0-kali1-amd64-recovery-ebf56086-a05f-4eea-afb5-96378220f62e' {
load_video
insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
insmod part_gpt
insmod ext2
set root='hd0,gpt5'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt5 --hint-efi=hd0,gpt5 --hint-baremetal=ahci0,gpt5 ebf56086-a05f-4eea-afb5-96378220f62e
else
search --no-floppy --fs-uuid --set=root ebf56086-a05f-4eea-afb5-96378220f62e
fi
echo 'Loading Linux 4.0.0-kali1-amd64 ...'
linux /boot/vmlinuz-4.0.0-kali1-amd64 root=UUID=ebf56086-a05f-4eea-afb5-96378220f62e ro single nouveau.modeset=0
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-4.0.0-kali1-amd64
}
}

### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_linux_xen ###

### END /etc/grub.d/20_linux_xen ###

### BEGIN /etc/grub.d/30_os-prober ###
menuentry 'Windows Boot Manager (on /dev/sda1)' --class windows --class os $menuentry_id_option 'osprober-efi-786F-D745' {
insmod part_gpt
insmod fat
set root='hd0,gpt1'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt1 --hint-efi=hd0,gpt1 --hint-baremetal=ahci0,gpt1 786F-D745
else
search --no-floppy --fs-uuid --set=root 786F-D745
fi
chainloader /efi/Microsoft/Boot/bootmgfw.efi
}
### END /etc/grub.d/30_os-prober ###

### BEGIN /etc/grub.d/30_uefi-firmware ###
menuentry 'System setup' $menuentry_id_option 'uefi-firmware' {
fwsetup
}
### END /etc/grub.d/30_uefi-firmware ###

### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries. Simply type the
# menu entries you want to add after this comment. Be careful not to change
# the 'exec tail' line above.
### END /etc/grub.d/40_custom ###

### BEGIN /etc/grub.d/41_custom ###
if [ -f ${config_directory}/custom.cfg ]; then
source ${config_directory}/custom.cfg
elif [ -z "${config_directory}" -a -f $prefix/custom.cfg ]; then
source $prefix/custom.cfg;
fi
### END /etc/grub.d/41_custom ###



Are these the options i have to edit?

menuentry 'Kali GNU/Linux, with Linux 4.0.0-kali1-amd64 (recovery mode)'
menuentry 'Kali GNU/Linux, with Linux 4.0.0-kali1-amd64'
menuentry 'Kali GNU/Linux, with Linux 4.3.0-kali1-amd64 (recovery mode)
submenu 'Advanced options for Kali GNU/Linux'
menuentry 'Kali GNU/Linux'
menuentry 'Windows Boot Manager (on /dev/sda1)*

I guess thats right, but why are there so many "kali gnu linux with linux" entries?

for example these
menuentry 'Kali GNU/Linux, with Linux 4.3.0-kali1-amd64 (recovery mode)
menuentry 'Kali GNU/Linux, with Linux 4.0.0-kali1-amd64 (recovery mode)'

pi1
2016-01-27, 16:34
thank you for your help

nehaljwani
2016-01-27, 22:08
Thank you very much !! I know it sounds strange, but is it also possible to change the background picture of the kali menu? I dont like it because you barely can read the options.


Please go through http://www.blackmoreops.com/2015/11/27/change-grub-background-in-kali-linux and https://help.ubuntu.com/community/Grub2/Displays

iqbalhapid
2016-02-04, 16:50
hey bro, thanks it work at the first after reboot on kali. but when i turn on my laptop (after shutdown on windows) the grub just disappear (not showing) and automatically starting windows . can you tell me why? thx. sory for my bad english

nehaljwani
2016-02-04, 18:54
hey bro, thanks it work at the first after reboot on kali. but when i turn on my laptop (after shutdown on windows) the grub just disappear (not showing) and automatically starting windows . can you tell me why? thx. sory for my bad english

What is your computer make / model? There might be a function key which you need to press to get to the boot options. There you will might see Kali as a boot option. Somehow the reboot cleared the UEFI NVRAM variables, or changed the boot order.

Hesus
2016-03-27, 08:53
Big thanks for creating this guide, with it i finally got the dual boot working.

Towlieee
2016-04-26, 11:05
I'm making the assumption that this will also work with windows 7 in UEFI mode? Want to try it out, spent a lot of time before trying to get grub to load kali along side win 7 in UEFI in the past, never got it to boot kali unfortunately.

node
2016-04-30, 07:15
In Kali rolling 2016.1, is there an option to install without loading the Grub2?

Also I have Wins and Kali rolling 2016.1 dual booting fine; will like to know how to get uBuntu 15.10 to show up as a selection from the Kali boot screen for a triple boot system.

I installed ubuntu without installing grub2 bootloader.

node
2016-05-13, 17:20
In Kali rolling 2016.1, is there an option to install without loading the Grub2?

Also I have Wins and Kali rolling 2016.1 dual booting fine; will like to know how to get uBuntu 15.10 to show up as a selection from the Kali boot screen for a triple boot system.

I installed ubuntu without installing grub2 bootloader.

Solved case closed Mod

mulot
2016-05-21, 03:31
I'm very confused since I already installed Kali 2016 before seeing this post and I already installed GRUB bootloader while in Legacy mode. Now in legacy, only Kali is detected in grub, no Windows 10 but in UEFI, it immediately booted to Win10, no Kali or GRUB. What should I do?

Solved with this thread, https://forums.kali.org/showthread.php?28918-Acer-Aspire-v11-Dual-Booting-Kali-Linux-in-UEFI-Mode
Thanks, OP.

sri1497vatsa
2016-07-07, 18:48
I had the same problem.. so had to get into Kali Linux through some other way and rEFInd proved great.. I have compiled the steps in my blog.. anyone interested can look it up here metechex.blogspot.in
It's working pretty fine .. cheers

Hesus
2016-09-10, 21:54
Hi,

I am stuck on step 15 i created the grub config file but when i try to command grub-install /dev/sda it give me the following

installing for x86_64-efi platform .
could not prepare Boot variable: Permission denied
Installation finished . No error reported .

anyway to lift the permission needed for the boot variable to be added?

nehaljwani
2016-09-11, 02:38
Hi,

I am stuck on step 15 i created the grub config file but when i try to command grub-install /dev/sda it give me the following

installing for x86_64-efi platform .
could not prepare Boot variable: Permission denied
Installation finished . No error reported .

anyway to lift the permission needed for the boot variable to be added?

It happens on certain machines that the EFI boot variables can't be fiddled around with inside chroot. The workaround for this is to exit out of the chroot and then create the boot entry manually:


efibootmgr -c -d /dev/sda -p X -l /EFI/kali/grubx64.efi -L "Kali Linux"

Make sure that you replace 'X' in the above command with the partition number of the EFI partition, which you had mounted at /mnt/boot/efi.

Hesus
2016-09-11, 07:56
Thanks for the quick respond.

This was the answer i needed. Kali is working in dual boot like a charm.

Aziks
2016-09-18, 17:24
I get this:


root@sysresccd:/# apt-get update
Hit:1 http://ftp.free.fr/pub/kali sana InRelease
Reading package lists... Done
W: Target Packages (main/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Packages (main/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Packages (non-free/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Packages (non-free/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Translations (non-free/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Translations (non-free/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Packages (contrib/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Packages (contrib/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Translations (contrib/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Translations (contrib/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Packages (main/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Packages (main/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Packages (non-free/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Packages (non-free/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Translations (non-free/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Translations (non-free/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Packages (contrib/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Packages (contrib/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Translations (contrib/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Translations (contrib/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Packages (main/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Packages (main/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Packages (non-free/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Packages (non-free/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Translations (non-free/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Translations (non-free/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Packages (contrib/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Packages (contrib/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Translations (contrib/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Translations (contrib/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:7
W: Target Packages (main/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Packages (main/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Packages (non-free/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Packages (non-free/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Translations (non-free/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Translations (non-free/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Packages (contrib/binary-amd64/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Packages (contrib/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Translations (contrib/i18n/Translation-en_US) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
W: Target Translations (contrib/i18n/Translation-en) is configured multiple times in /etc/apt/sources.list:6 and /etc/apt/sources.list:8
root@sysresccd:/# apt-get install -y grub-efi
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
efibootmgr grub-common grub-efi-amd64 grub-efi-amd64-bin grub2-common
libefivar0 libpng12-0 os-prober
Suggested packages:
multiboot-doc grub-emu xorriso
The following NEW packages will be installed:
efibootmgr grub-common grub-efi grub-efi-amd64 grub-efi-amd64-bin
grub2-common libefivar0 libpng12-0 os-prober
0 upgraded, 9 newly installed, 0 to remove and 0 not upgraded.
Need to get 4,215 kB of archives.
After this operation, 19.6 MB of additional disk space will be used.
Err:1 http://http.kali.org/kali sana/main amd64 libefivar0 amd64 0.15-3
404 Not Found
Err:2 http://http.kali.org/kali sana/main amd64 libpng12-0 amd64 1.2.50-2+b2
404 Not Found
Err:3 http://http.kali.org/kali sana/main amd64 efibootmgr amd64 0.11.0-3
404 Not Found
Err:4 http://http.kali.org/kali sana/main amd64 grub-common amd64 2.02~beta2-22
404 Not Found
Err:5 http://http.kali.org/kali sana/main amd64 grub2-common amd64 2.02~beta2-22
404 Not Found
Err:6 http://http.kali.org/kali sana/main amd64 grub-efi-amd64-bin amd64 2.02~beta2-22
404 Not Found
Err:7 http://http.kali.org/kali sana/main amd64 grub-efi-amd64 amd64 2.02~beta2-22
404 Not Found
Err:8 http://http.kali.org/kali sana/main amd64 grub-efi amd64 2.02~beta2-22
404 Not Found
Err:9 http://http.kali.org/kali sana/main amd64 os-prober amd64 1.65
404 Not Found
E: Failed to fetch http://http.kali.org/kali/pool/main/e/efivar/libefivar0_0.15-3_amd64.deb 404 Not Found
E: Failed to fetch http://http.kali.org/kali/pool/main/libp/libpng/libpng12-0_1.2.50-2+b2_amd64.deb 404 Not Found
E: Failed to fetch http://http.kali.org/kali/pool/main/e/efibootmgr/efibootmgr_0.11.0-3_amd64.deb 404 Not Found
E: Failed to fetch http://http.kali.org/kali/pool/main/g/grub2/grub-common_2.02~beta2-22_amd64.deb 404 Not Found
E: Failed to fetch http://http.kali.org/kali/pool/main/g/grub2/grub2-common_2.02~beta2-22_amd64.deb 404 Not Found
E: Failed to fetch http://http.kali.org/kali/pool/main/g/grub2/grub-efi-amd64-bin_2.02~beta2-22_amd64.deb 404 Not Found
E: Failed to fetch http://http.kali.org/kali/pool/main/g/grub2/grub-efi-amd64_2.02~beta2-22_amd64.deb 404 Not Found
E: Failed to fetch http://http.kali.org/kali/pool/main/g/grub2/grub-efi_2.02~beta2-22_amd64.deb 404 Not Found
E: Failed to fetch http://http.kali.org/kali/pool/main/o/os-prober/os-prober_1.65_amd64.deb 404 Not Found
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?

Someone can help me ?

newbie013
2016-10-01, 13:31
It happens on certain machines that the EFI boot variables can't be fiddled around with inside chroot. The workaround for this is to exit out of the chroot and then create the boot entry manually:


efibootmgr -c -d /dev/sda -p X -l /EFI/kali/grubx64.efi -L "Kali Linux"

Make sure that you replace 'X' in the above command with the partition number of the EFI partition, which you had mounted at /mnt/boot/efi.


Hi
the same in vaio, but my solution: boot from live kali rolling , and mount partition efi around 105 mb, copy "grubx64.efi" from /EFI/kali/grubx64.efi to /EFI/Boot/grubx64.efi and unmount, reboot

before to this my disk contain three OS x64 UEFI:grub bootloader with EFI for win 8.1, Debian and older version kali
and latest version systemrescuecd 4.8.2 not contain bootx64.efi , used 4.5.4
thanks .... :) :) .this saving much time and without install refind