# system won't boot---just hangs

## Uncle_Psychosis

Hi guys

I just upgraded gcc to the latest stable version gcc-3.4.4. I followed the guide and did an emerge -e system and an emerge -e world, then I rebuilt my kernel like the following:

#mount /boot

#cd /usr/src/linux

#make menuconfig

#make && make modules_install

#cp arch/i386/boot/bzImage /boot/kernel-2.6.14-gentoo-r2

#cp System.map /boot/System.map-2.6.14-gentoo-r2

#cp .config /boot/config-2.6.14-gentoo-r2

That all went fine, so I unmounted /boot, and rebooted (I didnt need to change grub because it was already pointing to the right place, and that was *definitely* the right name for the bzImage). Problem is now that my system won't boot. I get to grub, it boots, I see the right fbsplash stuff and then all the dmesg output (no errors). It then gets to the "activating swap" line and has some stuff about priorities, and then it just hangs. Nothing. I don't understand what's going on. I can't boot any of my older (and previously working) kernels either. WTF have I done? And more to the point, how can I fix it? I'm guessing that since my linux install is on a SATA disk (I dual boot with windows which is on a normal IDE) that something weird has happened to the SATA drivers, but I don't understand why the boot process can activate swap, bluetooth, and a whole load of other things if the SATA driver is buggered! 

OK, I've done a bit more digging. When I compile the kernel I get an error that reads:

"warning: /lib/modules/2.6.14-gentoo-r2/video/nvidia.ko needs unknown symbol capable" 

So I'm guessing that's the problem. Any fixes?

Also, when I try to compile nvidia-kernel or nvidia-glx I get :

"ACCESS DENIED: open_wr /newroot/dev/vc/a" 

and the emerge fails. Similarly for alsa-driver.

Any ideas? 

SamLast edited by Uncle_Psychosis on Fri Dec 09, 2005 4:20 am; edited 1 time in total

----------

## AmosMutke

boot your computer with an old/stable kernel, back up your .config for the new kernel, and re-emerge the sources.  copy back your .config and try rebuilding the kernel.

Sounds like your kernel sources may have been damaged.

----------

## desultory

The older kernels did not boot either, as was mentioned by Uncle_Psychosis, nonetheless Uncle_Psychosis managed to get something booted. As an aside, in such circumstances I recommend a live filesystem Linux CD for analysis and recovery.

I advise you to fsck all of your filesystems, some extreme weirdness can manifest simply because of a corrupt fs.

If you have the sources and configs for a known working version of the kernel, try using that.  If that works then upgrade to a newer version.

Edit: fixed a typo, had mispelt Uncle_Psychosis.Last edited by desultory on Fri Dec 09, 2005 7:01 pm; edited 1 time in total

----------

## AmosMutke

 *desultory wrote:*   

> The older kernels did not boot either, as was mentioned by Uncle_Psychosis, nonetheless Uncle_Psycosis managed to get something booted.

 

oops.. my bad...  thx for the catch.

----------

## Uncle_Psychosis

[/code]Desultory, can you tell me how to do the fsck?

Ok, so now I can get it to boot...Here's what I did:

boot from livecd

Mounted root filesystem, boot, proc, boot, and dev. I did some googling for my ACCESS DENIED error and it suggested that doing:

#mount -o bind /dev /mnt/gentoo/dev before chrooting would allowe me to compile nvidia-kernel and nvidia-glx. 

And, indeed, it did  :Smile:  So I managed to do:

#emerge nvidia-kernel nvidia-glx

And now I was able to recompile the kernel without the "unknown symbol" error. Oh, but to get the system to boot I have to remove the CONSOLE=/dev/tty1 from the relevant part of grub---I think udev-0.70-r1 doesn't like this! Anyway now I get a whole bunch of errors like this on startup:

```
Dec  9 12:06:48 klang ReiserFS: sda5: journal-1299: Setting newest_mount_id to 262

Dec  9 12:06:48 klang ReiserFS: sda5: Using r5 hash to sort names

Dec  9 12:06:48 klang rc-scripts: Could not get dependency info for "timidity"!

Dec  9 12:06:48 klang rc-scripts: Please run:

Dec  9 12:06:48 klang rc-scripts:   # /sbin/depscan.sh

Dec  9 12:06:48 klang rc-scripts: to try and fix this.

Dec  9 12:06:48 klang rc-scripts: Could not get dependency info for "timidity"!

Dec  9 12:06:48 klang rc-scripts: Please run:

Dec  9 12:06:48 klang rc-scripts:   # /sbin/depscan.sh

Dec  9 12:06:48 klang rc-scripts: to try and fix this.

Dec  9 12:06:49 klang rc-scripts: Could not get dependency info for "timidity"!

Dec  9 12:06:49 klang rc-scripts: Please run:

Dec  9 12:06:49 klang rc-scripts:   # /sbin/depscan.sh

Dec  9 12:06:49 klang rc-scripts: to try and fix this.

Dec  9 12:06:49 klang rc-scripts: Could not get dependency info for "timidity"!

Dec  9 12:06:49 klang rc-scripts: Please run:

Dec  9 12:06:49 klang rc-scripts:   # /sbin/depscan.sh

Dec  9 12:06:49 klang rc-scripts: to try and fix this.

Dec  9 12:06:49 klang rc-scripts: Could not get dependency info for "timidity"!

Dec  9 12:06:49 klang rc-scripts: Please run:

Dec  9 12:06:49 klang rc-scripts:   # /sbin/depscan.sh

Dec  9 12:06:49 klang rc-scripts: to try and fix this.

Dec  9 12:06:49 klang rc-scripts: Could not get dependency info for "vixie-cron"!

Dec  9 12:06:49 klang rc-scripts: Please run:

Dec  9 12:06:49 klang rc-scripts:   # /sbin/depscan.sh

Dec  9 12:06:49 klang rc-scripts: to try and fix this.

Dec  9 12:06:49 klang rc-scripts: Could not get dependency info for "vixie-cron"!

Dec  9 12:06:49 klang rc-scripts: Please run:

Dec  9 12:06:49 klang rc-scripts:   # /sbin/depscan.sh

Dec  9 12:06:49 klang rc-scripts: to try and fix this.

Dec  9 12:06:49 klang rc-scripts: Could not get dependency info for "vixie-cron"!

Dec  9 12:06:49 klang rc-scripts: Please run:

Dec  9 12:06:49 klang rc-scripts:   # /sbin/depscan.sh

Dec  9 12:06:49 klang rc-scripts: to try and fix this.

Dec  9 12:06:50 klang rc-scripts: Could not get dependency info for "vixie-cron"!

Dec  9 12:06:50 klang rc-scripts: Please run:

Dec  9 12:06:50 klang rc-scripts:   # /sbin/depscan.sh

Dec  9 12:06:50 klang rc-scripts: to try and fix this.

Dec  9 12:06:50 klang rc-scripts: Could not get dependency info for "vixie-cron"!

Dec  9 12:06:50 klang rc-scripts: Please run:

Dec  9 12:06:50 klang rc-scripts:   # /sbin/depscan.sh

Dec  9 12:06:50 klang rc-scripts: to try and fix this.

Dec  9 12:06:50 klang cron[10901]: (CRON) STARTUP (V5.0)

Dec  9 12:06:50 klang rc-scripts: Could not get dependency info for "xdm"!

Dec  9 12:06:50 klang rc-scripts: Please run:

Dec  9 12:06:50 klang rc-scripts:   # /sbin/depscan.sh

Dec  9 12:06:50 klang rc-scripts: to try and fix this.

Dec  9 12:06:50 klang rc-scripts: Could not get dependency info for "xdm"!

Dec  9 12:06:50 klang rc-scripts: Please run:

Dec  9 12:06:50 klang rc-scripts:   # /sbin/depscan.sh

Dec  9 12:06:50 klang rc-scripts: to try and fix this.

Dec  9 12:06:51 klang rc-scripts: Could not get dependency info for "xdm"!

Dec  9 12:06:51 klang rc-scripts: Please run:

Dec  9 12:06:51 klang rc-scripts:   # /sbin/depscan.sh

Dec  9 12:06:51 klang rc-scripts: to try and fix this.

Dec  9 12:06:51 klang rc-scripts: Could not get dependency info for "xdm"!

Dec  9 12:06:51 klang rc-scripts: Please run:

Dec  9 12:06:51 klang rc-scripts:   # /sbin/depscan.sh

Dec  9 12:06:51 klang rc-scripts: to try and fix this.

Dec  9 12:06:51 klang rc-scripts: Could not get dependency info for "xdm"!

Dec  9 12:06:51 klang rc-scripts: Please run:

Dec  9 12:06:51 klang rc-scripts:   # /sbin/depscan.sh

Dec  9 12:06:51 klang rc-scripts: to try and fix this.

Dec  9 12:06:51 klang init: Activating demand-procedures for 'A'

Dec  9 12:06:54 klang agpgart: Found an AGP 2.0 compliant device at 0000:00:00.0.

Dec  9 12:06:54 klang agpgart: Putting AGP V2 device at 0000:00:00.0 into 4x mode

Dec  9 12:06:54 klang agpgart: Putting AGP V2 device at 0000:03:00.0 into 4x mode

Dec  9 12:06:54 klang agpgart: Found an AGP 2.0 compliant device at 0000:00:00.0.

Dec  9 12:06:54 klang agpgart: Putting AGP V2 device at 0000:00:00.0 into 4x mode

Dec  9 12:06:54 klang agpgart: Putting AGP V2 device at 0000:03:00.0 into 4x mode

Dec  9 12:07:10 klang gdm(pam_unix)[11226]: session opened for user elmo by (uid=0)
```

But I think this is a seperate error, so I will post a new thread. 

Sam

----------

## sundialsvc4

Yup, an "unknown symbol" is definitely a sign of no-go.

Also, if your system uses modules, one must not forget to make install && make modules_install so that all of the expected modules will be present, and current.  Otherwise, you can wind up in .. an unstable situation.  

as in: <<Play "six_million_dollar_man_opening.mov" ... "we can rebuild him ... we have the technology ...">>

----------

## Uncle_Psychosis

I compiled the kernel the same way I always do:

#make && make modules_install

What is the correct, definitive, this *will* work way to compile your kernel after a gcc upgrade? 

#make clean bzImage modules modules_install   ?

#make && make modules_install  ?

#make install && make modules install  ?

Every guide to kernel compilation I've ever seen uses a different method---why can't we just have one way and stick to it? 

Sam

----------

## desultory

 *Uncle_Psychosis wrote:*   

> Desultory, can you tell me how to do the fsck?

 

Surely, the easiest way I can think of would be:

Boot your livecd.

Mount your root partition.

Copy your normal /etc/fstab into to the livecd environment, e.g. ~/myfstab.

Umount your root partition.

Run, in a terminal: 

```
FSTAB_FILE='~/myfstab' fsck -As
```

All this does is check all of your filesystems listed in your normal fstab without you having to specify them individually.

You might want to check that the fs_passno (the sixth field on the line, a whole number; see man 5 fstab for details) on each of your physical filesystems is >0 with your root filesystem having an fs_passno of 1 and others being preferably >1.

As for the unknown symbol errors, just a thought, did you not set a local version for the kernel built with the new gcc?

----------

## Uncle_Psychosis

Thanks. 

I don't know what you mean by local version of the kernel...Can you expand a little?

Sam

----------

## desultory

Will this do?

Run make menuconfig

Select 'General Setup  --->'

Select 'Local Version - append to kernel release'

Type something (like your gcc version), just escape any apostrophes (i.e. single quotes): see post 2907871.

Accept the new local version name.

Exit saving changes.

Make your kernel and modules.

Install your kernel and modules.

Congratulations; you now have a local version on your kernel, which will allow it to sit beside an otherwise identical kernel without stomping its modules. 

I recommend doing this if you upgrade gcc without upgrading your kernel, make sure to give the kernels distinct names so you can associate a kernel with its modules.

----------

