Slackware This Forum is for the discussion of Slackware Linux.
|
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
10-10-2014, 01:52 PM
|
#1
|
Senior Member
Registered: Apr 2007
Location: Buenos Aires.
Distribution: Slackware
Posts: 4,442
Rep:
|
boot message: mount: mounting /dev/sda1 on /mnt failed: Invalid argument.
Hi: I created partition 6 and moved slackware 14.0-32, which was in partition 1 to partition 6. Then I modified lilo.conf and fstab and ran lilo. Maybe I modified the fstab that was in 1 instead of that of 6, do not remember well. When I booted slackware everything went well. Then I deleted partition 1 and booted again. But this time, during booting, I got the message in the thread title followed by "ERROR: No /sbin/init found on rootdev (or not mounted). Trouble ahead. You can try to fix it. Type 'exit' when things are done". And was given a prompt.
Now, why is the system trying to mount /dev/sda1? I can't understand. How does it know the O.S. was in /dev/sda1 before?
|
|
|
10-10-2014, 02:03 PM
|
#2
|
LQ Addict
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,179
Rep:
|
Because you still told to mount /dev/sda1 on / in the /etc/fstab found on your new root file system (mounted on /dev/sda6), as this is not the file that you have edited. So the system looks for /sbin/init on /dev/sda1 but when it does so /dev/sda1 is not yet mounted.
So no, the system doesn't not "know" that /dev/sda1 was the old root device, it just reads /etc/fstab to know what the root device is, as it should.
Last edited by Didier Spaier; 10-10-2014 at 02:10 PM.
|
|
|
10-10-2014, 02:14 PM
|
#3
|
Senior Member
Registered: Apr 2007
Location: Buenos Aires.
Distribution: Slackware
Posts: 4,442
Original Poster
Rep:
|
But in sda6/etc/fstab I tell it it's sda6! The /etc/fstab in sda6 now says:
/dev/sda6 / ext2 defaults 1 1
I don't know how to make the system forget about sda1!
|
|
|
10-10-2014, 02:18 PM
|
#4
|
LQ Addict
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,179
Rep:
|
That would mean that the lilo stanza you use still has
Last edited by Didier Spaier; 10-10-2014 at 02:20 PM.
|
|
|
10-10-2014, 02:20 PM
|
#5
|
Senior Member
Registered: Apr 2007
Location: Buenos Aires.
Distribution: Slackware
Posts: 4,442
Original Poster
Rep:
|
Apparently. But I ran lilo with boot=/dev/sda6 and root=/dev/sda6.
|
|
|
10-10-2014, 03:01 PM
|
#6
|
Senior Member
Registered: Apr 2007
Location: Buenos Aires.
Distribution: Slackware
Posts: 4,442
Original Poster
Rep:
|
All of a sudden I understood what is happening. When linux was in sda1 the boot loader was in the MBR (disk absolute sector 0). I had root=/dev/sda in lilo.conf. Then I move it to sda6 and changed that line to root=/dev/sda6. But BIOS was still loading the boot loader from the MBR! What I did now is to run lilo with the old line root=/dev/sda and the system boot OK.
However, the only way I had found to be able to boot windows 7, which I have in partitions 2 and 3, was to have root=/dev/sda6 (root=/dev/sda1 before moving linux). With root=/dev/sda I get "bootmgr is missing" when booting win 7.
|
|
|
10-10-2014, 03:10 PM
|
#7
|
Member
Registered: May 2013
Location: Massachusetts
Distribution: Slackware, NetBSD, Debian, 9front
Posts: 346
Rep:
|
Quote:
Originally Posted by stf92
All of a sudden I understood what is happening. When linux was in sda1 the boot loader was in the MBR (disk absolute sector 0). I had root=/dev/sda in lilo.conf. Then I move it to sda6 and changed that line to root=/dev/sda6. But BIOS was still loading the boot loader from the MBR! What I did now is to run lilo with the old line root=/dev/sda and the system boot OK.
|
I'm confused. Do you mean root= or boot= above? Cause according to the man page it's boot= that says where to put the boot loader and root= is just a way to pass along the kernel command line parameter of that name to linux.
|
|
|
10-10-2014, 03:51 PM
|
#8
|
Senior Member
Registered: Apr 2007
Location: Buenos Aires.
Distribution: Slackware
Posts: 4,442
Original Poster
Rep:
|
I had linux in sda1 and boot=/dev/sda (sic). Then I installed windows 7 and couldn't make lilo boot it until I happened to put boot=/dev/sda1. Then I created partition 6 and moved linux to it, with boot still equal boot=/dev/sda6. And here is where I got "mount: mounting /dev/sda1 on /mnt failed" at boot time and could boot linux no longer. Then I put boot=/dev/sda and I could boot well. That's all I can say. Of course root= was modified where appropriate.
EDIT: my mistake. In post #6 it should say 'boot=' and not 'root='.
Last edited by stf92; 10-10-2014 at 04:05 PM.
|
|
|
All times are GMT -5. The time now is 07:27 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|