LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 12-30-2009, 10:59 AM   #1
BashTin
Member
 
Registered: May 2003
Location: West Midlands, United Kingdom.
Distribution: Slackware 14.1, Centos 7
Posts: 278

Rep: Reputation: 32
HELP!!! Toasted My MBR - LILO


Come on save me..... again!

Ok lets not get into how or why because tinkering is what Linux is about afterall!

So I have to restore my MBR. Well I booted up off the Slacky install CD and did something along the lines of

Code:
mkdir mymount
mkdir mymount/root
mkdir mymount/boot
mount /dev/sda6 mymount/root
mount /dev/sda7 mymount/boot
/mymount/root/bin/chroot /mymount/root /sbin/lilo
But then lilo complains about cannot find /boot/vmlinuz. I figure this is because the boot and root are on separate partions so lilo cannot locate the config files due to the chroot command. I did try from lilo directly - 'lilo -C ../etc/lilo.conf' but then it complains about cannot find /boot/map.

Someone save me and let me know what dummy should do :-)

Thanks in advance, BashTin.
 
Old 12-30-2009, 11:01 AM   #2
~sHyLoCk~
Senior Member
 
Registered: Jul 2008
Location: /dev/null
Posts: 1,173
Blog Entries: 12

Rep: Reputation: 129Reputation: 129
Quote:
mount /dev/sda6 mymount/root
mount /dev/sda7 mymount/boot
To:

Quote:
mount /dev/sda6 mymount/root
mount /dev/sda7 mymount/root/boot
 
1 members found this post helpful.
Old 12-30-2009, 02:15 PM   #3
DonnieP
Member
 
Registered: Jan 2008
Location: Richmond, VA USA
Distribution: Slackware
Posts: 144

Rep: Reputation: 29
If that didn't solve it - in my experience chroot is not required. As long as the device names are the same booting from the CD as they are on your normal HD boot, then you can just mount the device that contains your usual /etc/lilo.conf and then run lilo -C from the CD pointing to that conf file (wherever you mounted it). The file itself points to the necessary boot and root devices. So if you mounted the partition with the good lilo.conf to /mymount/root then you would run from the CD:

lilo -C /mymount/root/etc/lilo.conf
 
Old 12-30-2009, 02:37 PM   #4
JokerBoy
Member
 
Registered: Sep 2009
Posts: 140

Rep: Reputation: 24
try:

Code:
mount /dev/sda6 /mnt
mount /dev/sda7 /mnt/boot
/sbin/lilo -r /mnt (if this not work try "/mnt/sbin/lilo -r /mnt" )
 
Old 12-30-2009, 07:03 PM   #5
BashTin
Member
 
Registered: May 2003
Location: West Midlands, United Kingdom.
Distribution: Slackware 14.1, Centos 7
Posts: 278

Original Poster
Rep: Reputation: 32
Thanks, one happy Slacker again!

I tried the solutions from the top and ~sHy worked straight off so did not have a chance to try DonnieP and JokerBoy's solutions but thankyou to you all.

Happy New Year.

BashTin.
 
  


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
Lilo on MBR tez Slackware - Installation 3 10-22-2004 09:20 AM
Lilo only on MBR? Teoryn Slackware - Installation 9 03-30-2004 04:10 AM
LILO not in MBR contactsanil Linux - Newbie 1 01-12-2004 03:49 AM
lilo on MBR roofy Linux - General 5 05-19-2003 04:15 PM
mbr had over write so lilo is gone how to rewrite lilo to mbr mch Linux - Software 4 10-25-2002 02:55 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 09:31 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