LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware - Installation (http://www.linuxquestions.org/questions/slackware-installation-40/)
-   -   Slackware V12.1 Problem installing older Kernel (http://www.linuxquestions.org/questions/slackware-installation-40/slackware-v12-1-problem-installing-older-kernel-678935/)

m_g-m 10-25-2008 12:39 AM

Slackware V12.1 Problem installing older Kernel
 
Hi,
I've searched the Internet and the Forum for my problem but I couldn't find it yet. If there is something already I've missed, I'm sorry to bother you.

I'm doing a commissioning of a forging line and there is a Siemens IPC which should run on a Slackware V12.1.
We're using a Comsoft Profibus Card for Communication. That's where the problems started. The Driver for our current Kernel (2.6.24.5) will be finished until next week. It's not good to stay nearly one week without beeing able to work so we decided to compile an old Kernel for which we have a driver to already test the Signals. (2.6.22.1)

I'm not that deep into Linux and so I've done it step by step with a linux advanced user of our company via telephone.
He did the same operations on his Computer. His installation worked, mine didn't.
When I try to start the old Kernel I get this Error while booting:
Code:

md: Autodetecting RAID arrays.
md: autorun ...
md: ... autorun DONE.
List of all partitions:
0300 156290904 hda driver: ide-disk
 0301          3903763 hda1
 0302                1 hda2
 0305        152384526 hda5
1600        407008 hdc driver: ide-cdrom
No filesystem could mount root, tried: romfs
Kernel panic - not syncing: VFS: Unable to mount root fs on unkown-block(3,5)

Now what have we done?
Code:

cd /usr/src/linux/
ls
cp .config ../linux-2.6.22.1/
cd ../linux-2.6.22.1/
ls .config  -al
make oldconfig
make
make modules_install
cp ./arch/i386/boot/bzImage /boot/kernel-2.6.22.1
joe /etc/lilo.conf
lilo

I've seen here in the Kernel Compile Guide, the link of the linux folder is changed to the Kernel folder which I'm installing. But I wonder why it worked at our company with exact the same actions I did.
So I think that isn't the Problem, but I'm also affraid of deleting or overwriting stuff of the running Kernel.

With the new Kernel ther is also a Problem. I'm not able to switch from the X-Server to the Command Line anymore. I only get blackscreens when I use [ctrl]+[alt]+[f?] , [ctrl]+[alt]+[backspace] , "shutdown -r/h now" or just when exiting it. So my only chance to shutdown is to cut the Power supply. Slackware V12.0 worked flawlessly until I've installed V12.1 then it used to recognize my tiping twice. For example if I wrote "root" it actually became "rroooott". Even if I start it from the DVD. But later we need V12.1 anyway so V12.0 would just be an option for testing until other software parts ar finished.

I hope someone could help me.

Thanks in advance,

Martin

Bruce Hill 10-25-2008 07:33 AM

Welcome to LQ!

You should build test kernels under /home/username/ so that
you don't mess up /usr/src. This guide will help with that.

As for your error message:
Quote:

Kernel panic - not syncing: VFS: Unable to mount root fs on unkown-block(3,5)
usually means your kernel does not have support for either
the root filesystem, or the hard drive controller, or both.

You've left a lot out of your post that we'd have to guess
about, such as hardware specs, actually commands, etc.

Not to be rude, but you can Google and find these answers.

m_g-m 10-26-2008 12:08 AM

Thanks for the reply.
I've searched quite a lot, but I think I probably used the wrong terms.
But i knew it had to do something with the HD. But that the filesystem could be a problem didn't come to my mind.
I'm using ext3 right now. Yesterday I did all step by step like in the guide in this section and somehow it worked to get to 2.6.22.1.
But only when I choose the Kernel 2.6.24.5. It welcomes me to 2.6.22.1 and also "uname -r" returns 2.6.22.1.
If I use the real LILO entry for 2.6.22.1, the error still appears.
The really weird thing is, the driver isn't recognized as the correct version.
So I think I'm still not finished with the Kernel and instead I have some mix of the Kernels.

The Blackscreen problem was discussed quite often but with nvida and ati drivers. This was my fault not to mention what HW Specs this PC has, but I wasn't sure myself, since it isn't that easy to get to the IPC through the cables which are under voltage. Indian wiring some kind of different. ^^
Yesterday evening we had some time without power so I finally was able to get to it.

So these are the Specs:
Simatic Box PC 840 V2

Intel Pentium 4 Mobile 2,2 GHz,
400 MHz FSB, 512 Kbyte L2-Cache

1x 1GB DDR SDRAM

2 x PCI: 1 x short, 1 x long,
2x PCI/ISA (shared) long, 1x ISA long

Graphic is Onboard wasn't able to identify it probably within VIA VT8235M Southbridge (it's using the VESA driver)

160GB HDD EIDE

I'll reinstall the whole Slackware an then log everything during the kernel compiling the way we did it first.
Also I'll try with ext2.

Best regards,

Martin

€dit:
Btw. your link didn't work, but if I mess up my src directory, I'll just install slackware again from the beginning. ;)

Bruce Hill 10-26-2008 01:37 AM

Another link to my Kernel Rebuild Guide

m_g-m 10-26-2008 09:08 AM

Good evening.
Now I've done it completely like in your guide.

Code:

bash-3.1$ cd /home/bharat/
bash-3.1$ mkdir testkernels
bash-3.1$ cd ./testkernels/
bash-3.1$ mkdir kernelbuildlog
bash-3.1$ cp /mnt/memory/linux-2.6.22.1.tar.gz ./
bash-3.1$ tar -xf linux-2.6.22.1.tar.gz
bash-3.1$ cd ./linux-2.6.22.1/
bash-3.1$ cp /usr/src/linux/.config ./
bash-3.1$ make oldconfig | tee ../kernelbuildlog/makeoldconfig.txt
bash-3.1$ make | tee ../kernelbuildlog/make.txt
bash-3.1$ su
Password:
bash-3.1# cp System.map /boot/System.map-2.6.22.1
bash-3.1# ln -sf /boot/System.map-2.6.22.1 /boot/System.map
bash-3.1# make modules_install | tee ../kernelbuildlog/makemodulesinstall.txt
bash-3.1# cp arch/i386/boot/bzImage /boot/vmlinuz-2.6.22.1
bash-3.1# cd /boot/
bash-3.1# mkinitrd -c -k vmlinuz-2.6.22.1 -m ext2
2981 blocks
bash-3.1# rename initrd.gz 2.6.22.1-initrd.gz
bash-3.1# joe /etc/lilo.conf
Processing '/etc/joe/joerc'...Processing '/etc/joe/ftyperc'...done
done

File /etc/lilo.conf saved
bash-3.1# cp /etc/lilo.conf /home/bharat/testkernels/kernelbuildlog/
bash-3.1# lilo
Warning: LBA32 addressing assumed
Added Slack-2.6.24.5 *
Added Slack-2.6.22.1
One warning was issued.


With the initrd file I've made, following appeared:
Code:

mount: mounting /dev/hda1 on mnt failed: No such device
ERROR: No/sbin/init found on rootdev (or not mounted). Trouble ahead.
      You can try to fix it Type exit when things are done.
/bin/sh: can't access tty; job control turned off
/ $

But then nothing happens anymore. And when I delete the initrd file in the lilo.conf the same error as before appears.

The exported log files are here, including the commands above:
http://www.file-upload.net/download-...ldlog.rar.html

Maybe also necessary:
hda1: linux partition, bootable and formated as ext2, ~158GB
hda2: linux swap partition, ~2GB

I hope now I've made it better than on my first attempt. :)

Greetings,

Martin

€dit: Read the reason is a problem with the initrd file and also found somewhere a little bit different code for building it.

Code:

mkinitrd -c -f ext3 -k 2.6.24.5-smp -m ext3 -r /dev/hda2 -o /boot/26245smp.gz
In my case:
Code:

mkinitrd -c -f ext2 -k linux-2.6.22.1 -m ext2 -r /dev/hda1 -o /boot/2.6.22.1-initrd.gz
First thing I'll do tomorrow morning is trying this.

Sry for asking some stuff before searching. Normally that's not me, but it just takes so much nerves here. I'd really like to apologise for that.

€dit2:
It works! I added lba32 and append="APCI=off" to the lilo.conf.
Now only my graphic problem is remaining.
Thanks for the Guide Bruce Hill, there is also well explained why some things shouldn't be done, which isn't in many other I've read.


All times are GMT -5. The time now is 12:54 AM.