LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 10-15-2019, 11:56 AM   #1
Drosera_capensis
Member
 
Registered: Jun 2018
Posts: 153

Rep: Reputation: Disabled
Repairing the booting system with Boot-repair


Hello everyone,

I am working on Ubuntu BionicBeaver 18.04.3.
The boot of my computer has stopped to work for an unknown reason, I am now limited to the GNU GRUB window.

I have tried to initialize the kernel, as written here:

https://askubuntu.com/questions/8839...b-command-line

But vmlinuz and initrd are not in the boot repository, nor anywhere in the accessible gpt1 and gpt2 folders.

Therefore, I have tried another method, using the tool Boot-repair following the guidelines of this tutorial:

https://www.howtogeek.com/114884/how...ntu-wont-boot/

Unfortunately, the Boot-repair tool installation is not working.

Code:
ubuntu@ubuntu:~$ sudo apt-get install -y boot-repair
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 boot-repair : Depends: boot-sav but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
Have anyone encounter that problem?
 
Old 10-15-2019, 12:24 PM   #2
colorpurple21859
LQ Veteran
 
Registered: Jan 2008
Location: florida panhandle
Distribution: Slackware Debian, Fedora, others
Posts: 7,345

Rep: Reputation: 1588Reputation: 1588Reputation: 1588Reputation: 1588Reputation: 1588Reputation: 1588Reputation: 1588Reputation: 1588Reputation: 1588Reputation: 1588Reputation: 1588
based on one of your previous threads ti will be something like this if your not at a grub-rescue> prompt
The "grub> ls" should show what to set the "set root=" to
Code:
grub> insmod lvm
grub> ls
grub> set root=(ubuntu--vg)
grub> linux /vmlinuz root=/dev/mapper/─ubuntu--vg-root
grub> initrd /initrd.img
grub> boot
 
Old 10-16-2019, 06:14 AM   #3
Drosera_capensis
Member
 
Registered: Jun 2018
Posts: 153

Original Poster
Rep: Reputation: Disabled
Hello colorpurple21859, thanks for your answer.
I think I have already tried these command, but you can maybe help me to understand what is it going on.

On the GNU GRUB screen, with minimal BASH-like commands:

Quote:
grub> insmod lvm
grub> ls
(hd0) (hd0,gpt2) (hd0,gpt1)
grub> set root=(ubuntu--vg)
grub> linux /vmlinuz root=/dev/mapper/─ubuntu--vg-root
error: no server is specified.
grub> initrd /initrd.img
error: you need to load the kernel first
grub> boot
error: you need to load the kernel first
For information I have searched for the vmlinuz and initrd.img. They do not exist.

I can access to my computer via a booting memory stick, but the commands do not help.

Quote:
ubuntu@ubuntu:~$ insmod lvm
insmod: ERROR: could not load module lvm: No such file or directory
ubuntu@ubuntu:~$ set root=(ubuntu--vg)
bash: syntax error near unexpected token `('
ubuntu@ubuntu:~$ linux /vmlinuz root=/dev/mapper/-ubuntu--vg-root
linux: command not found
ubuntu@ubuntu:~$ initrd /initrd.img
initrd: command not found
ubuntu@ubuntu:~$ boot

Command 'boot' not found, did you mean:

command 'brot' from deb fortunes-de
command 'boog' from deb alliance
command 'hboot' from deb lam-runtime
command 'boom' from deb alliance
command 'boom' from deb doomsday
command 'boom' from deb prboom-plus
command 'booth' from deb booth

Try: sudo apt install <deb name>
 
Old 10-16-2019, 08:13 AM   #4
yancek
LQ Guru
 
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 10,492

Rep: Reputation: 2488Reputation: 2488Reputation: 2488Reputation: 2488Reputation: 2488Reputation: 2488Reputation: 2488Reputation: 2488Reputation: 2488Reputation: 2488Reputation: 2488
The Ubuntu site below explains how to install boot-repair by first adding the repository necessary. The info you posted above does not tell us whether you used that step. At the site below, a 2nd option is explained and you should use that method as it is more current.

https://help.ubuntu.com/community/Boot-Repair

Quote:
But vmlinuz and initrd are not in the boot repository, nor anywhere in the accessible gpt1 and gpt2 folders.
You are using LVM which generally means a separate boot partition on which you would have the vmlinuz and initrd files. Have you mounted those partitions from another OS installed or live and checked to see that those files do or do not exist? If you have and they are not there, you won't be able to boot until that problem is remedied.

If you are using a system on a usb/memory stick, you need to be root (use sudo) to run those commands and also to chroot so that you are running those commands on the system rather that the live usb/memory stick.
 
1 members found this post helpful.
Old 10-16-2019, 09:12 AM   #5
colorpurple21859
LQ Veteran
 
Registered: Jan 2008
Location: florida panhandle
Distribution: Slackware Debian, Fedora, others
Posts: 7,345

Rep: Reputation: 1588Reputation: 1588Reputation: 1588Reputation: 1588Reputation: 1588Reputation: 1588Reputation: 1588Reputation: 1588Reputation: 1588Reputation: 1588Reputation: 1588
What is the output of the following?
Code:
grub>ls (hd0,gpt1)/
grub>ls (hd0,gpt2)/
 
Old 10-16-2019, 12:42 PM   #6
Drosera_capensis
Member
 
Registered: Jun 2018
Posts: 153

Original Poster
Rep: Reputation: Disabled
Thank you for your nice answer Vancek.

I went through all the tutorial, and some error are preventing the software to work.

I have reinstalled Ubuntu as it might be difficult to repair the boot system in this particular case.

Thanks for your help!
 
  


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
LXer: Boot Repair Tool - Repair The Most Boot Related Problems LXer Syndicated Linux News 0 06-21-2017 09:49 PM
Message: A database connection error has been detected, we are attempting to repair the server, if the repair does not resolve the issue, pl deva420patra Linux - Server 4 11-23-2016 07:40 AM
I need a Linux OS other than Ubuntu which has a repair disk or repair software jhmac77 Linux - Newbie 1 03-17-2008 07:04 AM
"Error booting operating system" Repairing GRUB. SUSE 10.2 and XP dual boot Arma12 SUSE / openSUSE 11 01-28-2007 04:26 PM
I have installed fedora core 4 .While repairing XP booting prompt is not coming murali_reddy219 Linux - Software 1 01-08-2007 11:19 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 06:30 AM.

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