LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   The dreaded GNU Grub Boot Prompt after trying to install Elementary OS (https://www.linuxquestions.org/questions/linux-newbie-8/the-dreaded-gnu-grub-boot-prompt-after-trying-to-install-elementary-os-4175478565/)

Caskla 09-25-2013 06:42 PM

The dreaded GNU Grub Boot Prompt after trying to install Elementary OS
 
Okay, so today I tried to install Elementary OS. I got through the installation and when I was prompted to reboot and select Elementary OS (I dual booted it with Windows 8), I got what is apparently known asthe dreaded grub boot prompt.

I see that there are steps there to help get through it, but I don't quite understand how to apply them to my PC.
When I 'ls', I get "(hd0) (hd0,msdos1) (hd1) (hd2) (hd2,gpt5) (hd2,gpt4) (hd2,gpt3) (hd2,gpt2) (hd2,gpt1)." When I boot into Windows, I have the partitions C:/ and L:/ and I am not sure which one is which. Any help is appreciated. Thanks in advance.

Ztcoracat 09-25-2013 07:33 PM

Hi:

Sorry to hear your having trouble with your Elementary OS.

I (think) that you can now use the next command (ls and the (hd0) and all the rest; to look at each partition to determine which one is the Linux root, boot, and swap. Look for the dev/sda1 that is your "/boot partition"
If this partition contains /boot, the output will show the full name of vmlinuz and initramfs.

Code:

4. With this information you can now probe each partition of the drive and locate your vmlinuz and initramfs files:

ls (hd0,1)/

At the prompt on your screen; does it say: error: file not found grub rescue?

Also is this a Desktop computer or a laptop? What make and model?

I have asked another member to help here because I don't know about your Windows C:/ or L:/ and I don't want to tell
you the wrong thing.


https://help.ubuntu.com/community/Grub2/Troubleshooting
https://wiki.ubuntu.com/Initramfs

Ztcoracat 09-26-2013 03:35 PM

After consulting with another member here It would be better for you to use a Linux LIVE-CD to determine what each drive contains.

With Windows 8 that particular partition is on a UEFI partition all of it's own.

http://www.ehow.com/how_8248552_hidd...n-windows.html
https://www.linuxquestions.org/quest...st-4175478139/

Caskla 09-26-2013 09:29 PM

Thank you for your help, Ztcoracat.

First of all, I apologize for being unable to reply quicker.

To answer your questions, this a desktop that I built. No, it did not say "error: file not found grub rescue."

I am unfarmiliar with Linux LIVE-CDs. How would I go about using one to determine what each drive contains? Also, since this new partition that I created only contains Elementary OS files that the installer installed, would it be easier to just start the process over? You know, wipe the partition then reinstalling? I guess a better question is, is this issue caused by an error in the installation that is most likely a one time thing, or is this caused by an incompatibility issue, or something else? Because I wouldn't mind retrying if you think it might fix this issue.

Ztcoracat 09-26-2013 10:07 PM

You are very Welcome. It's my pleasure to assist you.

If Elementary OS is the only operating system on your new computer than yes, it would be considerably easier to just re-inatall Elementary. Depending on the size of the HDD you could create your own partitions or just allow the installer do it for you if you want the OS to take up the entire disk.

Otherwise you would have to prepare for a dual boot (Windows and Linux) on the same HDD:-

Quote:

How would I go about using one to determine what each drive contains?
If you have Windows 8 installed on your computer than it would be better to use a LIVE Linux CD to determine all of the partitions on your machine. To do so you would go and get any Linux distro's live .iso image and burn it to a CD/DVD and set your computer in the BIOS to boot to the CDROM drive first.Save the changes in your BIOS and than Exit.If you already have Elementary OS on a CD/DVD you can use that-:)

Quote:

or is this caused by an incompatibility issue
If it is a compatibility issue than all you would need to do is disable the secure boot in your BIOS-
That is if Windows 8 is installed on your computer--

Once the Linux CD loads you can use the terminal to run this command and post the output of it-
Code:

fdisk -l

Caskla 09-26-2013 10:44 PM

I don't believe I was specific enough about how I went about installing Elementary OS in my original post.
I extracted the elementaryos-stable-amd64.20130810.iso onto a USB drive and booted into that. I then went through the installation process, and I was then prompted to restart my computer and select Elementary OS. When I booted back up, instead of getting a screen where I could select my OS, I got the grub boot prompt.

I would be happy to boot into the Elementary OS USB drive tomorrow and run the fdisk command, but right now, I need to go. Again, thank you for your time.

EDDY1 09-26-2013 10:47 PM

Quote:

To answer your questions, this a desktop that I built. No, it did not say "error: file not found grub rescue."
Although it doesn't say "error: file not found grub rescue.", you are brought to grub prompt.
What does your hardware consist of?
How many hdd's do you have?
Do you know if you installed to the msdos disk or did you install to the gpt partitioned disk?

Caskla 09-29-2013 07:00 PM

Quote:

What does your hardware consist of?
http://pcpartpicker.com/p/11t4n
Quote:

How many hdd's do you have?
I have one HDD.
Quote:

Do you know if you installed to the msdos disk or did you install to the gpt partitioned disk?
I am not sure which one I installed it to. I think I installed it to the gpt partition. I know I didn't install it to my main disk that I am running Windows on.

Also, I attempted to run the
Quote:

fdisk -l
command, but all I got was this
Quote:

Usage:
fdisk [options] <disk> change partition table
fdisk [options] -l <disk> list partition table(s)
fdisk -s <partition> give partition size(s) in blocks

Options:
-b <size> sector size (512, 1024, 2048 or 4096)
-c[=<mode>] compatible mode: 'dos' or 'nondos' (default)
-h print this help text
-u[=<unit>] display units: 'cylinders' or 'sectors' (default)
-v print program version
-C <number> specify the number of cylinders
-H <number> specify the number of heads
-S <number> specify the number of sectors per track
.

I'd like to mention something that I noticed while watching an installation video. In the video, one of the options for installation was "Install elementary OS alongside Windows 8," and I didn't have that option. I was thinking that that might relate to my issue in some way, but I'm not sure.

EDDY1 09-29-2013 07:33 PM

Did you build this system or did they buid?
Is windows bootable?
Try using a live-cd

Ztcoracat 09-29-2013 09:18 PM

The commond 'fdisk -l has to be ran as 'root' That's the small letter l, BTW-
Code:

sudo fdisk -l
When you run that command you should get something like this:

Code:

  Device Boot      Start        End      Blocks  Id  System
/dev/sda1              63    7438094    3719016  12  Compaq diagnostics
/dev/sda2  *    7438095  293543077  143052491+  7  HPFS/NTFS/exFAT
/dev/sda3      332607486  976771071  322081793    5  Extended
/dev/sda5      332607488  334559231      975872  82  Linux swap / Solaris
/dev/sda6      334561280  976771071  321104896  83  Linux
7501:~$

Here's are the partitions on my computer; as an example. Here you can see my dual boot Win's XP and Black Opal/ Ubuntu 12.04--

Quote:

I was thinking that that might relate to my issue in some way
If you didn't have the option to install Elementary OS alongside Win's 8 like in the video; than the only way that you could of been able to install Elementary OS was to create a /journaling file system (Ext 4) and than create another partition for the swap-

Do you recall making 2 partitions?

Quote:

I know I didn't install it to my main disk that I am running Windows on.
If you only have that one 1 TB Western Digital HDD in that desktop tower than there is no other place that Elementary could of been installed.

Caskla 09-29-2013 09:42 PM

Quote:

If you only have that one HDD in that desktop tower than there is no other place that Elementary could of been installed.
I apologize, I meant I didn't install it to my main partition.
Quote:

Do you recall making 2 partitions?
I do have another partition that I created for this purpose, but I did not create it through the installer. I only used to installer to install the OS on the empty partition.

This is what comes up when I typed in the command:
Quote:

WARNING: GPT (GUID Partition Table) detected on '/dev/sda'! The util fdisk doesn't support GPT. Use GNU Parted.


Disk /dev/sda: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders, total 1953525168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk identifier: 0x00000000

Device Boot Start End Blocks Id System
/dev/sda1 1 1953525167 976762583+ ee GPT
Partition 1 does not start on physical sector boundary.

Disk /dev/sdb: 4004 MB, 4004511744 bytes
255 heads, 63 sectors/track, 486 cylinders, total 7821312 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Device Boot Start End Blocks Id System
/dev/sdb1 * 128 7821311 3910592 b W95 FAT32
Quote:

Did you build this system or did they buid?
I built the system.
Quote:

Is windows bootable?
I am not sure how to answer that question. Yes, I can boot into windows. No, I am not booting into windows from a disk or USB drive.

EDDY1 09-29-2013 10:02 PM

To read gpt partitioning you have to use gdisk
What os are you using on live-usb?
Quote:

sudo gdisk

Ztcoracat 09-29-2013 10:21 PM

Quote:

/dev/sda1 1 1953525167 976762583+ ee GPT
Partition 1 does not start on physical sector boundary.

This is a partition that was created but it doesn't have any mount points-
Unless I am mistaken-

Quote:

/dev/sdb1 * 128 7821311 3910592 b W95 FAT32
This is your Windows partiton. Thank goodness!
There should be at least another /W95/Fat32 partition and I am having trouble understanding why you don't have another Windows partition-
Because you should:- (bizarre)

Quote:

I am not booting into windows from a disk or USB drive.
The fact that you can boot into Windows is a very good sign. Your Windows OS is permanetly installed on your drive-

Because of the WARNING about fidisk you will have to use GNU parted.
https://www.gnu.org/software/parted/
https://www.gnu.org/software/parted/manual/

If you don't want to do that (use GNU Parted) than you will have to format the usb that has Elementary OS on it.
Than you should be able to install Elementary alongside of your Winows OS.

Quote:

I do have another partition that I created for this purpose
In that case than use that to install Elementary to- As long as you made a /journaling file system (ext4) Unless you want your Elementary to have more room) Than you would create a partition larger than what you have already mad. It's 1024 x (times) the size of the partiton you want to get the calculation in Mib's-

Don't forget to create another partiton for the swap. I would dedicate 1 to 2 GB for the swap partiton.
The swap holds temporary memory packages.
A server can boot w/o a swap partition as long as there's enough RAM. (if your running a server)

Ztcoracat 09-29-2013 10:23 PM

Quote:

Originally Posted by EDDY1 (Post 5037042)
To read gpt partitioning you have to use gdisk
What os are you using on live-usb?

I think that Elementary is the OS on his live-usb:-:)

EDDY1 09-29-2013 10:31 PM

Quote:

/dev/sda1 1 1953525167 976762583+ ee GPT
Partition 1 does not start on physical sector boundary.
Windows is bootable & on gpt partition
Quote:

/dev/sdb1 * 128 7821311 3910592 b W95 FAT32
This is a 4Gig usb.
Elementary is capable of installing to GPT & UEFI so it should have gdisk on it.

Ztcoracat 09-29-2013 10:44 PM

Quote:

Originally Posted by EDDY1 (Post 5037051)
Windows is bootable & on gpt partition

This is a 4Gig usb.
Elementary is capable of installing to GPT & UEFI so it should have gdisk on it.

Thank You Eddy1-:)

Since Elementary is capable of this all our friend; Caskla now needs is to use gdisk? Right?
I didn't know that gdisk comes with Elementary.

I used a Live Elementary CD yesterday and I was able to use g-parted to look at my friends Lenovo's partitons-
Don't know if that helps-

EDDY1 09-29-2013 11:07 PM

Quote:

Originally Posted by Ztcoracat (Post 5037058)
Thank You Eddy1-:)

Since Elementary is capable of this all our friend; Caskla now needs is to use gdisk? Right?
I didn't know that gdisk comes with Elementary.

I used a Live Elementary CD yesterday and I was able to use g-parted to look at my friends Lenovo's partitons-
Don't know if that helps-

Try the usb on your machine & run the command if it's installed it will read your gpt partitions, if there are no GPT partitions it will notify you of that, then you'll know if it's included in live-cd.

Ztcoracat 09-29-2013 11:15 PM

The Live CD is no longer with me.
My friend took it to install it on his Lenovo-

Ztcoracat 09-29-2013 11:17 PM

Caskla:

The Elementary .iso image is on your usb isn't it?

Caskla 09-30-2013 03:35 PM

Quote:

Try the usb on your machine & run the command if it's installed it will read your gpt partitions
Although this wasn't directed at me, I tried it anyway because I figured the results would be the same.
Quote:

elementary@elementary:~$ sudo gdisk
sudo: gdisk: command not found
elementary@elementary:~$ gdisk
The program 'gdisk' is currently not installed. You can install it by typing:
sudo apt-get install gdisk
elementary@elementary:~$ sudo apt-get install gdisk
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following NEW packages will be installed:
gdisk
0 upgraded, 1 newly installed, 0 to remove and 143 not upgraded.
Need to get 300 kB of archives.
After this operation, 642 kB of additional disk space will be used.
Get:1 http://archive.ubuntu.com/ubuntu/ precise/universe gdisk amd64 0.8.1-1build1 [300 kB]
Fetched 300 kB in 1s (281 kB/s)
Selecting previously unselected package gdisk.
(Reading database ... 120078 files and directories currently installed.)
Unpacking gdisk (from .../gdisk_0.8.1-1build1_amd64.deb) ...
Processing triggers for man-db ...
Setting up gdisk (0.8.1-1build1) ...
elementary@elementary:~$ sudo gdisk
GPT fdisk (gdisk) version 0.8.1

Type device filename, or press <Enter> to exit:
Quote:

The Elementary .iso image is on your usb isn't it?
Yes, it is.

Ztcoracat 09-30-2013 04:14 PM

Looking at the output gdisk in now installed. ;)

You should be able to install Elementary OS now (onto the partiton that you made) from your usb memory stick.

Caskla 09-30-2013 04:24 PM

So I should go through the installation process again?

Ztcoracat 09-30-2013 04:51 PM

Quote:

So I should go through the installation process again?
When you start up your computer do you have the GNU Grub Menu to choose either Elementary OS or Windows OS?
If you don't than I don't think Elementary Os has been installed.

We should see what Mr. Eddy has to say about the /dev/sda1 partition that you have.


/dev/sda5 EXT 4 4068 MB-
You should be able to install to that partition.

Caskla 09-30-2013 07:00 PM

As you know, I'd like to install it to the partition that I made, but according to the installer, /dev/sda1 is only 300 MB. /dev/sda5 seems to be the partition that I made. Here is an album of photos of the installer and my options: http://imgur.com/a/Vulvh

EDDY1 09-30-2013 10:23 PM

sudo gdisk /dev/sda

EDDY1 09-30-2013 11:10 PM

Quote:

Originally Posted by Caskla (Post 5037595)
As you know, I'd like to install it to the partition that I made, but according to the installer, /dev/sda1 is only 300 MB. /dev/sda5 seems to be the partition that I made. Here is an album of photos of the installer and my options: http://imgur.com/a/Vulvh

You are correct as sda5 has almost 4 Gigs of data written to it & it's ext4, but you also have an unknown partition sda3 that may be grub efi. Right now I'm going to to check the REFIT site for answers

Ztcoracat 10-01-2013 12:14 AM

Code:

dev/sda2 is the efi partition
Code:

dev/sda3 134 MB unknown
Not sure if that is Grub or not--

Code:

dev/sda4 is 894.8 GB which is way more than what you need for your Windows partition.
You could shrink your Windows partition and that way you will have more free space to make 2 partitions for Elementary.
That's what I would do if this was what I had to work with. I'd reduce it to about 1/2 the size it is now.

Code:

dev/sda5 ext4 4068 MB
That's a good partition but not big enough for Elementary to have room to expand over time.

EDDY1 10-01-2013 12:37 AM

4068 is used space on the partition, but partition is 104.9Gigs, so os is most likely installed but no bootloader. At this point the OP needs somebody like evo, tobisdg or other members who are more experienced with this type of setup.
Quote:

dev/sda5 ext4 4068 MB

Ztcoracat 10-01-2013 01:13 AM

Quote:

Originally Posted by EDDY1 (Post 5037730)
4068 is used space on the partition, but partition is 104.9Gigs, so os is most likely installed but no bootloader. At this point the OP needs somebody like evo, tobisdg or other members who are more experienced with this type of setup.

I wrote to Mr. Evo and asked him for his help-;)

Ztcoracat 10-03-2013 11:05 PM

10/04/13 Update
 
I have asked our Moderator to join this thread- ;)

BTW approx. 30 GB's is recommended for Windows 8-

However; it depends on how many other programs you must install on the boot disk partition:-
http://www.softwareok.com/?seite=faq-Windows-8&faq=5

EDDY1 10-04-2013 12:14 AM

Quote:

Originally Posted by Ztcoracat (Post 5039750)
I have asked our Moderator to join this thread- ;)

BTW approx. 30 GB's is recommended for Windows 8-

However; it depends on how many other programs you must install on the boot disk partition:-
http://www.softwareok.com/?seite=faq-Windows-8&faq=5

Windows will eat up 30Gigs in 1 update. You need atleas 70 Gigs for windows to breath.

Ztcoracat 10-04-2013 02:04 AM

Wow! 70 Gig's- That's just crazy:-

Caskla 10-04-2013 02:45 PM

Currently, I have 833gb on my Windows 8 partition, so there's no reason to worry. I plan on keeping that size, and having the extra 100gb on my HDD for Elementary OS.
Anyway, thank you, Ztcoracat, for asking for help.

Ztcoracat 10-04-2013 08:51 PM

Quote:

Originally Posted by Caskla (Post 5040176)
Currently, I have 833gb on my Windows 8 partition, so there's no reason to worry. I plan on keeping that size, and having the extra 100gb on my HDD for Elementary OS.
Anyway, thank you, Ztcoracat, for asking for help.

You are Welcome -;)

colorpurple21859 10-05-2013 11:13 AM

If you haven't reinstalled yet at the grub prompt what is the output of the following
Code:

set
ls /boot
ls /boot/grub
ls /boot/grub/i386-pc

I believe you may be missing the /boot/grub/grub.cfg file

Ztcoracat 10-05-2013 08:41 PM

I too colorpurple21859; was suspicious of /boot/grub/grub.cfg file missing.
How do we get that file that is needed?

This thread that our Guru: business_kidd SOLVED may be helpful in your case Caskla. To say the least to learn from.

Code:

Disabling secure boot disables gpt (i.e. hard disk) booting.
Disabling GPT disables windows 8.
Enabling secure boot locks you onto the hd, which, as explained, checks and fixes itself to be m$ only every time it wakes up in windows 8.

http://www.linuxquestions.org/questi...80#post4952280

Trying to help the best I can.

:~$@ Claska run those commands that colorpurple21859 needs when you have time.

:~$@ colorpurple21859: thank you for joining our thread!

colorpurple21859 10-05-2013 08:47 PM

that is what ls /boot is for to see what the kernel and initrd files are, then can manual boot with the linux and intrd commands. once booted either can run grub-update or grub-mkconfig to create a grub.cfg, or can create one manually with a text editor.

Ztcoracat 10-05-2013 09:14 PM

Quote:

Originally Posted by colorpurple21859 (Post 5040741)
that is what ls /boot is for to see what the kernel and initrd files are, then can manual boot with the linux and intrd commands. once booted either can run grub-update or grub-mkconfig to create a grub.cfg, or can create one manually with a text editor.

Thank you for teaching me that.
So...like you said once booted you will know wether to run grub-update or use grub-mkconfig to create the grub.cfg file.
I'm thinking that running "grub-update" and running "grub-mkconfig" performs differnt things.
Obviously 'grub-mkconfig' will give you the ability to make and configure the needed file-
Is that right?

colorpurple21859 10-05-2013 09:29 PM

It has been a while since I ran grub-mkconfig. If I can't get grub-update to work then I usually create one with a text editor.

Ztcoracat 10-05-2013 09:58 PM

Quote:

Originally Posted by colorpurple21859 (Post 5040754)
It has been a while since I ran grub-mkconfig. If I can't get grub-update to work then I usually create one with a text editor.

I would have to look on my system to see the arguments contained in the grub.cfg-
Thanks-;)

Caskla 10-08-2013 07:10 PM

Sorry it took me so long, guys. I lead a busy life. So, I ran the commands, and here are the results:
Quote:

grub> set
?=0
color_highlight=black/white
color_normal=white/black
pager=
prefix=(hd2,gpt2)/EFI/ubuntu
root=hd2,gpt2
grub> ls /boot

error: file not found
grub> ls /boot/grub

error: file not found
grub> ls /boot/grub/i386-pc

error: file not found
grub>

Ztcoracat 10-08-2013 07:55 PM

Evidently, you do not have the grub file. (error: file not found)

Lets's see what colorpurple21859 advises on this.
I would need his take on this to assist you or anyone else for that matter:-

In the meantime it probably wouldn't hurt to look up:
Invoking grub-mkconfig and or how to create /boot/grub/custom.cfg?

colorpurple21859 10-08-2013 08:11 PM

what does
Code:

ls
give and what is your partition/disk setup? There is no /boot on this partition.

colorpurple21859 10-08-2013 08:35 PM

you can find where your /boot partition is located by changing the partition numbers according to the output of
Code:

ls
then try variations of this
Code:

ls (hd2,gpt1)/boot
, we already know it is not on (hd2,gpt2). once we find where /boot is then you can boot with something along the line of
Code:

linux (hd?,gpt?)/boot/<name of kernel> root=/dev/??
initrd (hd?,gpt?)/boot/<name of initrd>
boot

linux (hd?,gpt?)/boot/<name of kernel> root=/dev/??
initrd (hd?,gpt?)/boot/<name of initrd>
boot

Then run updates and then reinstall grub to MBR

colorpurple21859 10-09-2013 12:52 AM

also what is the ouput of
Code:

ls (hd2,gpt2)/
ls (hd2,gpt2)/EFI
ls (hd2,gpt2)/EFI/ubuntu


Caskla 10-10-2013 07:49 PM

1 Attachment(s)
Here is the input. It seems that (hd2,gpt5) is my boot partition. Would have continued with the instructions, but I was unsure of what to type after the root=/dev/ part.
I figure the initrd.img-3.2.0-51-generic is the initrd.

Ztcoracat 10-10-2013 08:56 PM

Yes it (hd2,gpt5) does indeed look like your boot partition.
And the initial ram disk image (3.2.0-51 generic seems like it could be the initrd-

I (think) now like colorpurple21859 said you would type something like:
Code:

linux (hd2,gpt5) /boot/(your kernel 3.2.0-51)
After the kernel in the above in code I'm not sure if root=/dev would come next or if the name of initrd is what should be typed next.

I'm learning and waiting for colorpurple21859's counsel at this point. Never seen this output before.

andrewthomas 10-10-2013 09:07 PM

Set to the correct value, which might be something like this:
Code:

set prefix=(hd2,gpt5)/EFI/ubuntu
    set root=(hd2,gpt2)
    insmod normal
    normal

not sure if you have to insert the gpt module

colorpurple21859 10-10-2013 09:50 PM

See if this will pull up a boot menu.
Code:

configfile (hd2,gpt5)/boot/grub/grub.cfg
If it does and allow you to boot, then copy the /boot/grub/grub.cfg to /boot/efi/ubuntu and see if that will give you a boot menu.

colorpurple21859 10-10-2013 09:53 PM

Code:

ls (hd2,gpt5)/boot
will allow you to see what kernels are in you boot menu so you can boot directly as posted before if the configfile command doesn't work.


All times are GMT -5. The time now is 05:34 AM.