View previous topic :: View next topic |
Author |
Message |
AreA n00b
![n00b n00b](/images/ranks/rank_rect_0.gif)
Joined: 27 Dec 2004 Posts: 13 Location: Belgium
|
Posted: Tue Jun 13, 2006 9:42 pm Post subject: kernel update |
|
|
i just updated my kernel from 2.6.16-r7 to 2.6.16-r9 but something went wrong or i just forgot something
so when i boot it does what it normally does, then it says something about udev (don't remember, but if it's important i can just reboot and write it down ), and then i get to log in... but it doesn't show my hostname (just localhost), dno if this is normal but i would suppose not, and i can't log in, it doesn't ask for a password and it just shows the login thing again.
i updated the kernel following the kernel guide, followed all the necessary steps and i don't think i forgot something (at least not something important) in the config.
i booted the livecd and try to change the /usr/src/linux folder back to the previous kernel folder and tried to boot that kernel which didn't help much but i suppose i did something wrong this ![Smile :-)](images/smiles/icon_smile.gif) _________________ yea I know... |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
lxg Veteran
![Veteran Veteran](/images/ranks/rank_rect_5_vet.gif)
![](images/avatars/19265729674c9fac4bb9adf.png)
Joined: 12 Nov 2005 Posts: 1019 Location: Aachen, Germany
|
Posted: Tue Jun 13, 2006 11:23 pm Post subject: Re: kernel update |
|
|
AreA wrote: | i just updated my kernel from 2.6.16-r7 to 2.6.16-r9 but something went wrong or i just forgot something
so when i boot it does what it normally does, then it says something about udev (don't remember, but if it's important i can just reboot and write it down ), and then i get to log in... but it doesn't show my hostname (just localhost), dno if this is normal but i would suppose not, and i can't log in, it doesn't ask for a password and it just shows the login thing again. |
The udev thing and the hostname not being set are usually nothing critical.
Is it possible you have updated some packages responsible for user management (e.g. shadow), and forgot to run etc-update?
AreA wrote: | i updated the kernel following the kernel guide, followed all the necessary steps and i don't think i forgot something (at least not something important) in the config. |
I can't imagine that a login issue is caused by a kernel malfunction. (But, who knows...)
AreA wrote: | i booted the livecd and try to change the /usr/src/linux folder back to the previous kernel folder and tried to boot that kernel which didn't help much but i suppose i did something wrong this ![Smile :-)](images/smiles/icon_smile.gif) |
Next time, keep your old kernel and initrd unless the new one is known to work. Just add a srction with your new kernel to grub.conf and leave the old alone. _________________ lxg.de – codebits and tech talk |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
AreA n00b
![n00b n00b](/images/ranks/rank_rect_0.gif)
Joined: 27 Dec 2004 Posts: 13 Location: Belgium
|
Posted: Wed Jun 14, 2006 12:01 am Post subject: |
|
|
hm actually, yes, i did an emerge -uD system before i updated the kernel and shadow was on the list. how can i fix this?
i added that new kernel to the grub.conf, keeping the old config file as the manual proposed, so i tried booting that one, but it just gave the exact same thing. (doesn't that line just use a different config file? when you make that symlink /usr/src/linux-2.6.16-r9 /usr/src/linux , then it uses that folder as the kernel folder, so i'm still using the new kernel but just with the other config file? or am i mistaken ) _________________ yea I know... |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
lxg Veteran
![Veteran Veteran](/images/ranks/rank_rect_5_vet.gif)
![](images/avatars/19265729674c9fac4bb9adf.png)
Joined: 12 Nov 2005 Posts: 1019 Location: Aachen, Germany
|
Posted: Wed Jun 14, 2006 8:54 am Post subject: |
|
|
AreA wrote: | hm actually, yes, i did an emerge -uD system before i updated the kernel and shadow was on the list. how can i fix this? |
Usually it should be enough to run etc-update (you might need to chroot to your environment with a LiveCD). If that doesn't help, this thread might inspire you.
AreA wrote: | i added that new kernel to the grub.conf, keeping the old config file as the manual proposed, so i tried booting that one, but it just gave the exact same thing. (doesn't that line just use a different config file? when you make that symlink /usr/src/linux-2.6.16-r9 /usr/src/linux , then it uses that folder as the kernel folder, so i'm still using the new kernel but just with the other config file? or am i mistaken ) |
No. the config file is just the plan to build the kernel. It contains no runtime information. The purpose of putting the kernel config to boot is to backup a running kernel's config in case you mess up things, so you can copy it back to the specific kernel's source directory and rebuild then.
It is also not possible to take an old config file for building a new kernel, because there are always changes in the contained modules and their relationships. If you build a new kernel version, you always need to restart from scratch. (However, gentoo-sources comes with a good pre-config, so there's not much to change.) This differs from other distros where a kernel update is only a patch, i.e. you don't get a new version. In this case you could take the old config (or /proc/config.gz) and build your "new" kernel based on that.
If I may give you an advise: The next time you want to install a new kernel, do the following:
- Emerge the sources (will most likely be done automatically).
- Go to /usr/src, rm the linux symlink and set a new one (ln -s NEW_KERNEL_DIR linux). You could also set the symlink USE flag in order to get this done automatically, but this can lead to problems when you need additional modules to be built outside the kernel.
- Go into linux, build your kernel and copy it to /boot, as the handbook says
- Add a section with the new kernel to your grub.conf; don't delete the section of the old kernel. You can have multiple kernels in /boot and in grub.conf, that is no problem.
- Prepare all the other stuff (like modules.autoload.d), as the handbook says
- Reboot and chose your kernel.
_________________ lxg.de – codebits and tech talk |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
/carlito Guru
![Guru Guru](/images/ranks/rank_rect_3.gif)
![](images/avatars/771466582465a5e7215b9f.jpg)
Joined: 31 Dec 2004 Posts: 451 Location: Belgium
|
Posted: Wed Jun 14, 2006 4:46 pm Post subject: |
|
|
lx0 wrote: | It is also not possible to take an old config file for building a new kernel, because there are always changes in the contained modules and their relationships. If you build a new kernel version, you always need to restart from scratch. |
I've been using my config file since 2.6.8 and never had any problems rebuilding my kernel... _________________
.O.
..O
OOO
|
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
lxg Veteran
![Veteran Veteran](/images/ranks/rank_rect_5_vet.gif)
![](images/avatars/19265729674c9fac4bb9adf.png)
Joined: 12 Nov 2005 Posts: 1019 Location: Aachen, Germany
|
Posted: Thu Jun 15, 2006 2:44 pm Post subject: |
|
|
/carlito wrote: | lx0 wrote: | It is also not possible to take an old config file for building a new kernel, because there are always changes in the contained modules and their relationships. If you build a new kernel version, you always need to restart from scratch. |
I've been using my config file since 2.6.8 and never had any problems rebuilding my kernel... |
Ok, correction... It actually is possible; the kernel's configuration routine can detect older configurations and will apply them, in case a .config file doesn't exist yet. However, with every new kernel version, there are changes (new/expunged/renamed/split/merged modules, changed inter-module-dependencies). So you can, and actually will, have a configuration related to your "template", but it's important to check each option; to be sure you don't miss crucial features. _________________ lxg.de – codebits and tech talk |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
/carlito Guru
![Guru Guru](/images/ranks/rank_rect_3.gif)
![](images/avatars/771466582465a5e7215b9f.jpg)
Joined: 31 Dec 2004 Posts: 451 Location: Belgium
|
Posted: Thu Jun 15, 2006 8:09 pm Post subject: |
|
|
I get your point, but the developers already found a solution for this...make oldconfig. _________________
.O.
..O
OOO
|
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|