LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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 04-27-2008, 04:54 PM   #1
AceofSpades19
Senior Member
 
Registered: Feb 2007
Location: Chilliwack,BC.Canada
Distribution: Slackware64 -current
Posts: 2,079

Rep: Reputation: 58
Recompiled kernel will not boot on slackware 12


Hi, I just got a new laptop, a MSI M662, I installed slackware on it, and I wanted to get suspend/hibernate working on it. I found out the default slackware kernel doesn't support suspend/hibernate, so I download the latest 2.6.24 kernel and tried recompiling it with the TuxOnIce patch. The compile went on with out any problems, however when I try to boot from it, it says it can't mount the root filesystem and it says the options are hda1, hda2, or hda3. The problem is I only have sda1, 2 and 3. I have check ed the obvious things, like making sure the filesystem was built into the kernel and stuff like that. I have also tried compiling the 2.6.23.16 kernel but the same problem keeps on coming up. Here is my lilo.conf:

Code:
# LILO configuration file
# generated by 'liloconfig'
#
# Start LILO global section
boot = /dev/sda
message = /boot/boot_message.txt
prompt
timeout = 100
# Override dangerous defaults that rewrite the partition table:
change-rules
  reset
# VESA framebuffer console @ 1024x768x64k
vga = 791
# Normal VGA console
# vga = normal
# VESA framebuffer console @ 1024x768x64k
# vga=791
# VESA framebuffer console @ 1024x768x32k
# vga=790
# VESA framebuffer console @ 1024x768x256
# vga=773
# VESA framebuffer console @ 800x600x64k
# vga=788
# VESA framebuffer console @ 800x600x32k
# vga=787
# VESA framebuffer console @ 800x600x256
# vga=771
# VESA framebuffer console @ 640x480x64k
# vga=785
# VESA framebuffer console @ 640x480x32k
# vga=784
# VESA framebuffer console @ 640x480x256
# vga=769
# End LILO global section
# Linux bootable partition config begins
image = /boot/vmlinuz
  root = /dev/sda2
  label = Linux
  read-only

image = /boot/vmlinuz-2.6.23
  root = /dev/sda2
  append="resume=swap:/dev/sda4"
  label = Linux-2.6.23
  read-only

# Linux bootable partition config ends
My laptop is a celeron M with 2 gigs of ram and an Intel 945GM video card, if you need any more info I will be happy to give it to you, any suggestions are welcome.

Thanks in advance
 
Old 04-27-2008, 05:05 PM   #2
jailbait
LQ Guru
 
Registered: Feb 2003
Location: Virginia, USA
Distribution: Debian 12
Posts: 8,337

Rep: Reputation: 548Reputation: 548Reputation: 548Reputation: 548Reputation: 548Reputation: 548
Quote:
Originally Posted by AceofSpades19 View Post

it says it can't mount the root filesystem and it says the options are hda1, hda2, or hda3. The problem is I only have sda1, 2 and 3. I have check ed the obvious things, like making sure the filesystem was built into the kernel and stuff like that.
Do you have the correct driver for your SATA chipset built into the kernel?

http://linuxmafia.com/faq/Hardware/sata.html

------------------
Steve Stites
 
Old 04-27-2008, 05:12 PM   #3
AceofSpades19
Senior Member
 
Registered: Feb 2007
Location: Chilliwack,BC.Canada
Distribution: Slackware64 -current
Posts: 2,079

Original Poster
Rep: Reputation: 58
Quote:
Originally Posted by jailbait View Post
Do you have the correct driver for your SATA chipset built into the kernel?

http://linuxmafia.com/faq/Hardware/sata.html

------------------
Steve Stites
That is probably the problem, thanks alot
 
Old 04-27-2008, 05:50 PM   #4
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,367

Rep: Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843
The SATA drivers must be compiled into the kernel (since you said your hard drives are sda1, 2, 3), as jailbait said. On a side note, you don't need to apply TuxOnIce patches -- the newer kernels include good support for hibernation (suspend to disk), suspending to RAM and standby (I haven't had any problems at all) as long as you enable those options in the kernel.
 
Old 04-27-2008, 07:51 PM   #5
AceofSpades19
Senior Member
 
Registered: Feb 2007
Location: Chilliwack,BC.Canada
Distribution: Slackware64 -current
Posts: 2,079

Original Poster
Rep: Reputation: 58
Ok, I found out that I needed an initramfs, and I build one using Alien Bob's docwiki and his script to determine the command for mkinitramfs, so I ran this command:

mkinitrd -c -k 2.6.23.16 -m usb-storage:ehci-hcd:ata_generic:mbcache:jbd:ext3 -f ext3 -r /dev/sda2

but now it says that it can't mount the root file system on /dev/sda2, I'm pretty sure I'm probably missing something in that commend, but I could be wrong

Thanks for your help so far
 
Old 04-27-2008, 08:08 PM   #6
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,367

Rep: Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843
If you built the filesystem used on your root partition INTO the kernel instead of as a module, you don't need an initrd (initial ramdisk). Your problem still stems from the lack of SATA drivers compiled into the kernel, I think. If you compiled the filesystem used on your root partition as a module, you WILL need an initrd (or just recompile your kernel with the filesystem built into the kernel), but since it's still not booting it's likely a configuration error in your kernel (again, probably an SATA thing). Go through your .config file (back it up first) using `make menuconfig` and take a look at any possible SATA options (if still nothing works, you could try SCSI options, but most PCs nowadays don't have SCSI drives and I think they're identified as /dev/sr? and not /dev/sd?, but I could be wrong). Although normally I would recommend only using the kernel from -current if you're using -current (and not just using the kernel from -current in Slackware 12.0), if you absolutely cannot figure it out you could download the kernel packages (located in the slackware/a/ directory) and install them (make sure you do NOT upgrade the kernel headers). However, I personally would build my own anyway.

Did you use the .config from one of the default 2.6.21.5 kernels included in Slackware 12.0 (if so which kernel's .config did you start from) or did you start from scratch?

Last edited by T3slider; 04-27-2008 at 08:10 PM.
 
Old 04-27-2008, 08:14 PM   #7
AceofSpades19
Senior Member
 
Registered: Feb 2007
Location: Chilliwack,BC.Canada
Distribution: Slackware64 -current
Posts: 2,079

Original Poster
Rep: Reputation: 58
Quote:
Originally Posted by T3slider View Post
If you built the filesystem used on your root partition INTO the kernel instead of as a module, you don't need an initrd (initial ramdisk). Your problem still stems from the lack of SATA drivers compiled into the kernel, I think. If you compiled the filesystem used on your root partition as a module, you WILL need an initrd (or just recompile your kernel with the filesystem built into the kernel), but since it's still not booting it's likely a configuration error in your kernel (again, probably an SATA thing). Go through your .config file (back it up first) using `make menuconfig` and take a look at any possible SATA options (if still nothing works, you could try SCSI options, but most PCs nowadays don't have SCSI drives and I think they're identified as /dev/sr? and not /dev/sd?, but I could be wrong). Although normally I would recommend only using the kernel from -current if you're using -current (and not just using the kernel from -current in Slackware 12.0), if you absolutely cannot figure it out you could download the kernel packages (located in the slackware/a/ directory) and install them (make sure you do NOT upgrade the kernel headers). However, I personally would build my own anyway.

Did you use the .config from one of the default 2.6.21.5 kernels included in Slackware 12.0 (if so which kernel's .config did you start from) or did you start from scratch?
I tried making a config from scratch and using the huge-smp confg from /boot. On Alien's docwiki it says make a initramfs if you are getting this error
VFS: Cannot open root device "802" or unknown-block (8,2)
Please append a correct "root=" boot option
Kernel Panic-not syncing: VFS: unable to mount root fs on unknown block(8,2)

and that was what I was getting, but after I build the init ramfs, it just said it couldn't mount it. I'll try looking for the sata drivers in make menuconfig, but the last time I looked, all of the ones that seemed relevant were check.
 
Old 04-27-2008, 08:42 PM   #8
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,367

Rep: Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843Reputation: 843
Do you also have a relevant line in /etc/lilo.conf (ie "initrd = /boot/initrd.gz") to load the initrd? Did you run `lilo` afterward as well? (It sounds like you did since you got a different error, but I'm just making sure).

Also, your line `mkinitrd -c -k 2.6.23.16 -m usb-storage:ehci-hcd:ata_generic:mbcache:jbd:ext3 -f ext3 -r /dev/sda2` is loading modules for the 2.6.23.16 kernel. Is that the kernel you're trying to use (ie the one being loaded from lilo.conf)? (Looking at your lilo.conf suggests yes, but it's only called vmlinuz-2.6.23, and I want to make sure it's the proper kernel -- ie that no mismatching is going on). Does /lib/modules/2.6.23.16/ exist (and contain files)?
 
Old 04-27-2008, 08:55 PM   #9
AceofSpades19
Senior Member
 
Registered: Feb 2007
Location: Chilliwack,BC.Canada
Distribution: Slackware64 -current
Posts: 2,079

Original Poster
Rep: Reputation: 58
Quote:
Originally Posted by T3slider View Post
Do you also have a relevant line in /etc/lilo.conf (ie "initrd = /boot/initrd.gz") to load the initrd? Did you run `lilo` afterward as well? (It sounds like you did since you got a different error, but I'm just making sure).

Also, your line `mkinitrd -c -k 2.6.23.16 -m usb-storage:ehci-hcd:ata_generic:mbcache:jbd:ext3 -f ext3 -r /dev/sda2` is loading modules for the 2.6.23.16 kernel. Is that the kernel you're trying to use (ie the one being loaded from lilo.conf)? (Looking at your lilo.conf suggests yes, but it's only called vmlinuz-2.6.23, and I want to make sure it's the proper kernel -- ie that no mismatching is going on). Does /lib/modules/2.6.23.16/ exist (and contain files)?
Yes, I added the line in /etc/lilo.conf and ran lilo. Yes that is the kernel I have in /etc/lilo.conf. Yes, there is a /lib/modules/2.6.23.16 and it conatains files
 
Old 04-28-2008, 08:05 AM   #10
Tux-Slack
Member
 
Registered: Nov 2006
Location: Slovenia
Distribution: Slackware 13.37
Posts: 511

Rep: Reputation: 37
Quote:
Originally Posted by T3slider View Post
but most PCs nowadays don't have SCSI drives and I think they're identified as /dev/sr? and not /dev/sd?
Wrong, I have 2 old 4,3GB SCSI disks with PCI SCSI controllers and they're both identified as /dev/sdx and not /dev/srx.



I also think this is a SATA driver problem, so you could tray the long run solution.
Compile them all in, and then start throwing them out one by one. It's a pain in the ***, but it's effective. And you're only going to do this once, because the next time you will remember which driver you need to compile.
 
Old 04-28-2008, 12:16 PM   #11
dormantor
LQ Newbie
 
Registered: Jan 2006
Location: inside stack register
Distribution: slackware 10.2
Posts: 8

Rep: Reputation: 0
unable to mount root fs problems

pls somebody... i also got this problem... even forcing the filesystem to the kernel didnt work...
 
Old 04-28-2008, 01:05 PM   #12
AceofSpades19
Senior Member
 
Registered: Feb 2007
Location: Chilliwack,BC.Canada
Distribution: Slackware64 -current
Posts: 2,079

Original Poster
Rep: Reputation: 58
Quote:
Originally Posted by Tux-Slack View Post
Wrong, I have 2 old 4,3GB SCSI disks with PCI SCSI controllers and they're both identified as /dev/sdx and not /dev/srx.



I also think this is a SATA driver problem, so you could tray the long run solution.
Compile them all in, and then start throwing them out one by one. It's a pain in the ***, but it's effective. And you're only going to do this once, because the next time you will remember which driver you need to compile.
I just think its odd it won't even boot with the huge-smp config
 
Old 04-29-2008, 03:15 AM   #13
Tux-Slack
Member
 
Registered: Nov 2006
Location: Slovenia
Distribution: Slackware 13.37
Posts: 511

Rep: Reputation: 37
When you copied your huge-smp config into /usr/src/linux/.config did you do make oldconfig?
And before even copying did you do make mrproper?
I don't know about 2.6.23.x kernels but I can asure you 2.6.24.4 is running lovely.
 
Old 04-29-2008, 06:59 PM   #14
AceofSpades19
Senior Member
 
Registered: Feb 2007
Location: Chilliwack,BC.Canada
Distribution: Slackware64 -current
Posts: 2,079

Original Poster
Rep: Reputation: 58
Quote:
Originally Posted by Tux-Slack View Post
When you copied your huge-smp config into /usr/src/linux/.config did you do make oldconfig?
And before even copying did you do make mrproper?
I don't know about 2.6.23.x kernels but I can asure you 2.6.24.4 is running lovely.
I downloaded the newest 2.6.24 kernel and copied the old smp huge config, ran make oldconfig, recompiled it, and installed it, rebooted it and it still had the same error message
 
Old 04-30-2008, 12:34 AM   #15
Tux-Slack
Member
 
Registered: Nov 2006
Location: Slovenia
Distribution: Slackware 13.37
Posts: 511

Rep: Reputation: 37
Strange. Ok but here is where my knowledge about linux kernels stop.
 
  


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
recompiled kernel on slackware 10.0, still can't compile new one salviadud Linux - Newbie 2 02-09-2005 03:08 AM
Recompiled kernel and LILO wont boot it! pnh73 Linux - Software 9 04-07-2004 02:06 PM
Inspiron laptop, kernel recompiled -> cannot boot x sedulous Red Hat 2 09-08-2003 07:59 AM
Recompiled kernel boot problem... lokee Linux - Software 5 05-15-2003 05:35 PM
kernel recompiled - but i boot from floppy? gui10 Slackware 8 05-08-2002 12:43 PM

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

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