LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-05-2017, 07:34 AM   #1
Safeway44
Member
 
Registered: Apr 2017
Location: Land of the Lost
Distribution: Kali
Posts: 32

Rep: Reputation: Disabled
Windows not loading after grub install


From the Grub menu Windows 8 does not load after I select it I get an error
File:\Boot\BCD
Status: 0xc000000e

When I change the BIOS to UEFI from legacy Windows works
but then Kali is not accessible.I had to install Kali under Legacy because under UEFI the CD didn't do its thing, other than the computer brand's logo on the screen glaring.

During install Grub was placed in MBR. As this is a UEFI system is MBR even required? I don't have a spare USB lying around so if the solution can be utilizing the CD that work be ideal.CD is tested and working.

Kali iso is a recent download and it's meant to be UEFI friendly. Kali is loading fine. Thanks

Last edited by Safeway44; 04-05-2017 at 07:38 AM.
 
Old 04-05-2017, 10:08 AM   #2
hazel
LQ Guru
 
Registered: Mar 2016
Location: Harrow, UK
Distribution: LFS, AntiX, Slackware
Posts: 7,570
Blog Entries: 19

Rep: Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451
As far as I know, modern versions of Windows will not boot from a GPT disk with a bios. You have to use uefi. And, as you probably know, it is dangerous to keep switching modes because sooner or later you are going to use the wrong one. However, it is possible to convert a bios install to uefi. Basically you have to reinstall grub in uefi mode so that it goes onto your efi system partition. You can do that, using your installation disc.
Here's something I found on a Ubuntu site:
Code:
sudo mount /dev/sda1 /mnt # Mount the root filesystem in /mnt
sudo mkdir /mnt/boot/efi # Create a directory to mount the ESP in
sudo mount /dev/sda3 /mnt/boot/efi # Mount the ESP
sudo grub-install --root-directory=/mnt /dev/sda # Run the grub install
Basically you boot from the CD, mount your normal root partition, mount the efi system partition on the root partition's /boot/efi directory and then install grub there.

Last edited by hazel; 04-05-2017 at 11:57 AM.
 
1 members found this post helpful.
Old 04-05-2017, 03:13 PM   #3
trumpforprez
Member
 
Registered: Nov 2016
Location: UK
Distribution: Debian Jessie
Posts: 154

Rep: Reputation: Disabled
Quote:
Originally Posted by Safeway44 View Post
Kali iso is a recent download and it's meant to be UEFI friendly. Kali is loading fine. Thanks
What is Kali? Can you tell us more about what it is?

Once a new OS is installed, it is sometimes necessary to run
Code:
update-grub
from the terminal.
So boot your linux distro, run 'update grub' and see if this makes a difference.

Making changes on BIOS to UEFI is not related to your problem.
All linux distros should now be 'UEFI-friendly'.
 
Old 04-05-2017, 04:07 PM   #4
yancek
LQ Guru
 
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 10,499

Rep: Reputation: 2489Reputation: 2489Reputation: 2489Reputation: 2489Reputation: 2489Reputation: 2489Reputation: 2489Reputation: 2489Reputation: 2489Reputation: 2489Reputation: 2489
Quote:
What is Kali?
It's an operating system designed specifically and only for penetration testing/computer forensics and is basically meant for experts. Obviously, it can be used by people wishing to learn/study computer forensics and is absolutely not recommended as a standard Desktop distribution as explained at their site below.

http://docs.kali.org/introduction/sh...use-kali-linux

Mixing MBR and UEFI as mentioned above is the problem and the simplest solution to the problem the OP has would be to install Kali on a flash drive and select that drive on boot when he wants to try to learn penetration testing.

Quote:
As this is a UEFI system is MBR even required? I
If you are using UEFI, you should not have any boot code in the MBR and mixing the two is going to lead to boot problems. If you can boot either by making a change in the BIOS, that's the best you can do if you can't get Kali to install uefi. I'd suggest taking a close look at the Kali documentation on installing UEFI.
 
Old 04-05-2017, 04:27 PM   #5
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
sounds like you did a different boot method for each one, I'd suggest installing Linux by the same means windows boots. kiss is involved here, get their greatest hits album on apple cares today. but that gpt thing well then....
 
Old 04-05-2017, 04:52 PM   #6
Rickkkk
Senior Member
 
Registered: Dec 2014
Location: Montreal, Quebec and Dartmouth, Nova Scotia CANADA
Distribution: Arch, AntiX, ArtiX
Posts: 1,364

Rep: Reputation: 511Reputation: 511Reputation: 511Reputation: 511Reputation: 511Reputation: 511
Quote:
Originally Posted by BW-userx View Post
sounds like you did a different boot method for each one ...
Agreed.

Quote:
, I'd suggest installing Linux by the same means windows boots ...
Also agreed. Several previous posts suggest solutions. ...

Quote:
... kiss is involved here, get their greatest hits album on apple cares today. ...
... smirk ... that's worth a Deuce ...

Cheers ...

Last edited by Rickkkk; 04-06-2017 at 10:15 PM.
 
Old 04-06-2017, 07:50 PM   #7
Safeway44
Member
 
Registered: Apr 2017
Location: Land of the Lost
Distribution: Kali
Posts: 32

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by hazel View Post
Basically you have to reinstall grub in uefi mode so that it goes onto your efi system partition. You can do that, using your installation disc.

Quote:
Originally Posted by hazel View Post
Basically you boot from the CD,
Should I be in legacy or UEFI when I do this? The CD won't do anything when its in UEFI with the iso in it.

Quote:
Originally Posted by hazel View Post
mount your normal root partition,
Am I in terminal when I do this? What screen should I be seeing on my screen to execute this? Do I use Gparted?
 
Old 04-06-2017, 07:52 PM   #8
Safeway44
Member
 
Registered: Apr 2017
Location: Land of the Lost
Distribution: Kali
Posts: 32

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by yancek View Post
If you are using UEFI, you should not have any boot code in the MBR and mixing the two is going to lead to boot problems.
I recall placing Grub in MBR when prompted during install, I should have said no. How do I remove it from MBR?
 
Old 04-06-2017, 07:54 PM   #9
Safeway44
Member
 
Registered: Apr 2017
Location: Land of the Lost
Distribution: Kali
Posts: 32

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by BW-userx View Post
kiss is involved here, get their greatest hits album on apple cares today.
No thanks, I just want to Gpart all night and everyday
 
Old 04-06-2017, 10:17 PM   #10
Rickkkk
Senior Member
 
Registered: Dec 2014
Location: Montreal, Quebec and Dartmouth, Nova Scotia CANADA
Distribution: Arch, AntiX, ArtiX
Posts: 1,364

Rep: Reputation: 511Reputation: 511Reputation: 511Reputation: 511Reputation: 511Reputation: 511
Quote:
Originally Posted by Safeway44 View Post
No thanks, I just want to Gpart all night and everyday
... I think we're hitting Rock Bottom ...

... OK I'll stop.
 
Old 04-07-2017, 02:02 AM   #11
hazel
LQ Guru
 
Registered: Mar 2016
Location: Harrow, UK
Distribution: LFS, AntiX, Slackware
Posts: 7,570
Blog Entries: 19

Rep: Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451
Quote:
Originally Posted by Safeway44 View Post
Should I be in legacy or UEFI when I do this? The CD won't do anything when its in UEFI with the iso in it.
At this stage, you'll have to boot the CD in bios mode. The point is to change that for the future.
Quote:
Am I in terminal when I do this?
Yes. These are console commands.
Quote:
What screen should I be seeing on my screen to execute this?
I have no idea. I've never used Kali. And if you know so little about Linux as to ask these questions, you should not be using Kali either. It's really not a good distro for learning.
Quote:
Do I use Gparted?
Definitely not! gparted is a partitioning tool. There's probably nothing wrong with your partitioning scheme. You just need to install grub where the uefi expects to find bootloader code, i.e. in the efi system partition.
 
1 members found this post helpful.
Old 04-15-2017, 07:22 AM   #12
Safeway44
Member
 
Registered: Apr 2017
Location: Land of the Lost
Distribution: Kali
Posts: 32

Original Poster
Rep: Reputation: Disabled
I started with root@(none)
Quote:
Originally Posted by hazel View Post
sudo mount /dev/sda1 /mnt # Mount the root filesystem in /mnt
Quote:
Originally Posted by hazel View Post
sudo mkdir /mnt/boot/efi # Create a directory to mount the ESP in
I typed it in and got: "already exists"

Quote:
Originally Posted by hazel View Post
sudo mount /dev/sda3 /mnt/boot/efi # Mount the ESP
I typed it in and got:
"sudo: unable to resolve host(none): connection refused" Which connection is that?

Quote:
Originally Posted by hazel View Post
sudo grub-install --root-directory=/mnt /dev/sda # Run the grub install
Do I need to be online (connected) to install? Can it be done through Grub prompt too?

Quote:
Originally Posted by hazel View Post
Basically you boot from the CD, mount your normal root partition, mount the efi system partition on the root partition's /boot/efi directory and then install grub there.
 
Old 04-15-2017, 07:54 AM   #13
hazel
LQ Guru
 
Registered: Mar 2016
Location: Harrow, UK
Distribution: LFS, AntiX, Slackware
Posts: 7,570
Blog Entries: 19

Rep: Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451
Are you logging in remotely? That "connection refused" thing usually occurs when people use ssh.

Make sure you are using the right device name for the partition. It probably isn't sda3 on your system. That extract I gave you was just an example. Running fdisk -l will give you a list of the partitions on your own hard drive together with their types. The one that is down as an efi system partition is the one you need to mount.

You can check if the efi system partition actually has mounted by subsequently using the mount command without any arguments.

Last edited by hazel; 04-15-2017 at 08:01 AM.
 
Old 04-16-2017, 01:58 AM   #14
Safeway44
Member
 
Registered: Apr 2017
Location: Land of the Lost
Distribution: Kali
Posts: 32

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by hazel View Post
Are you logging in remotely? That "connection refused" thing usually occurs when people use ssh.
No I am not logging in remotely. Accessing a computer that's sitting on my desk in front of me.


Quote:
Originally Posted by hazel View Post
The one that is down as an efi system partition is the one you need to mount.
I ran fdisk and was able to see a list of partitions and one labelled EFI.

However when I tried fdisk l on a virtualbox version of Kali I didn't, instead I got: Welcome to fdisk (util-linux 2.29.1)
Changes will remain in memory only, until you decide to write them to disk. Be careful before using the write command.

fdisk: cannot open 1: no such file or directory


Quote:
Originally Posted by hazel View Post
You can check if the efi system partition actually has mounted by subsequently using the mount command without any arguments.
Is this what you mean by no arguments?:
sudo mount
 
Old 04-16-2017, 02:47 AM   #15
hazel
LQ Guru
 
Registered: Mar 2016
Location: Harrow, UK
Distribution: LFS, AntiX, Slackware
Posts: 7,570
Blog Entries: 19

Rep: Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451Reputation: 4451
Quote:
Originally Posted by Safeway44 View Post
No I am not logging in remotely. Accessing a computer that's sitting on my desk in front of me.


I ran fdisk and was able to see a list of partitions and one labelled EFI.

However when I tried fdisk l on a virtualbox version of Kali I didn't, instead I got: Welcome to fdisk (util-linux 2.29.1)
Changes will remain in memory only, until you decide to write them to disk. Be careful before using the write command.

fdisk: cannot open 1: no such file or directory
That should be "-l" for "list", not a 1
Quote:
Is this what you mean by no arguments?:
sudo mount
Exactly, except that you don't need sudo when you use mount this way. Listing mounted partitions is a job anyone is allowed to do. The term "arguments" always refers to strings that follow a command. They provide extra information for the program.

You know, someone who is so much a beginner as you are shouldn't be using Kali at all.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Windows 8 not loading from GRUB KingDookies Linux - Newbie 44 12-20-2012 03:33 PM
Loading Windows with GRUB scouture Linux - Software 3 03-09-2005 06:07 PM
SuSE 9.1 and Windows Xp refuse to live in harmony: error loading windows through GRUB sanctumtacete Linux - Newbie 3 10-19-2004 07:47 AM
GRUB loading windows teamstatic84 Linux - General 5 12-29-2003 08:46 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 12:57 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration