View previous topic :: View next topic |
Author |
Message |
jannis Guru
![Guru Guru](/images/ranks/rank_rect_3.gif)
Joined: 05 Dec 2004 Posts: 340 Location: Germany / Bavaria / Aschaffenburg
|
Posted: Sat Oct 01, 2016 5:56 pm Post subject: [SOLVED] gentoo-sources-4.4.21 restarts kernel config |
|
|
Hi, today I updated gentoo-sources on my nas (amd64 stable) from 4.4.6 to 4.4.21. However, "make oldconfig" resets the configuration and I have to start anew:
Code: | nas16 linux-4.4.21-gentoo # uname -a
Linux nas16 4.4.6-gentoo #3 SMP Sat Jun 4 10:08:01 CEST 2016 x86_64 Intel(R) Core(TM) i3-6300T CPU @ 3.30GHz GenuineIntel GNU/Linux
nas16 linux-4.4.21-gentoo # zcat /proc/config.gz > .config
nas16 linux-4.4.21-gentoo # head .config
#
# Automatically generated file; DO NOT EDIT.
# Linux/x86 4.4.6-gentoo Kernel Configuration
#
#
# Gentoo Linux
#
CONFIG_GENTOO_LINUX=y
CONFIG_GENTOO_LINUX_UDEV=y
nas16 linux-4.4.21-gentoo # make oldconfig
scripts/kconfig/conf --oldconfig Kconfig
*
* Restart config... |
anyone knows why this happens without the kernel having new features (it's still 4.4)?
and how I can re-use my config with the new kernel?
My kernel config from gentoo-source-4.4.6 is here: https://paste.pound-python.org/show/vdvIGZERHrUqfHcgo7II/
*UPDATE*: I just updated gentoo-source-4.4.6 to 4.4.21 in a VirtualBox-VM I have since some months and I don't have the problem there. Is there a way to find out WHY the configuration is restarted exactly?
Last edited by jannis on Fri Oct 07, 2016 1:54 pm; edited 1 time in total |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
sebB l33t
![l33t l33t](/images/ranks/rank_rect_4.gif)
Joined: 02 Mar 2011 Posts: 806 Location: S.O. France
|
Posted: Sun Oct 02, 2016 11:18 am Post subject: |
|
|
Quote: | nas16 linux-4.4.21-gentoo # zcat /proc/config.gz > .config |
Why don't you do this from 4.4.6?
Have you try, simply copy the copy the .config from 4.4.6 to 4.4.21 and make oldconfig? |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
jannis Guru
![Guru Guru](/images/ranks/rank_rect_3.gif)
Joined: 05 Dec 2004 Posts: 340 Location: Germany / Bavaria / Aschaffenburg
|
Posted: Mon Oct 03, 2016 4:59 pm Post subject: |
|
|
Hi sebB, thanks for your answer. I'm doing all this while version 4.4.6 is running, the thing you see before the "#" is the current directory. "/proc/config.gz" is configuration of the currently running kernel (4.4.6) and is saved in the directory of linux version 4.4.21. Copying the .config-file from the old kernel directory has the same result. |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
iq180 n00b
![n00b n00b](/images/ranks/rank_rect_0.gif)
Joined: 23 Mar 2015 Posts: 7
|
Posted: Tue Oct 04, 2016 8:55 am Post subject: |
|
|
jannis wrote: | Hi sebB, thanks for your answer. I'm doing all this while version 4.4.6 is running, the thing you see before the "#" is the current directory. "/proc/config.gz" is configuration of the currently running kernel (4.4.6) and is saved in the directory of linux version 4.4.21. Copying the .config-file from the old kernel directory has the same result. |
Try Code: | zcat /proc/config.gz > /etc/kernels/kernel-config-x86_64-4.4.21-gentoo |
|
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
cboldt Veteran
![Veteran Veteran](/images/ranks/rank_rect_5_vet.gif)
![](images/avatars/8786426094ce7c06a7c5dd.jpg)
Joined: 24 Aug 2005 Posts: 1046
|
Posted: Tue Oct 04, 2016 10:28 am Post subject: |
|
|
I have always used `make oldconfig` when moving from one kernel to a newer one, but for no reason in particular, when going form 4.4.6 to 4.4.21, used `make olddefconfig`. It worked.
I just now tried a fresh `cd /usr/src/linux-4.4.21-gentoo ; cp ../linux-4.4.6-gentoo/.config . ; make oldconfig` and that worked too. I was not prompted for any new settings, and the `make oldconfig` command wrote a .config for the 4.4.21 kernel.
Code: | /usr/src/linux-4.4.21-gentoo # make oldconfig
scripts/kconfig/conf --oldconfig Kconfig
#
# configuration written to .config
# |
The "Restart config" message comes from the file "scripts/kconfig/conf.c" I have not sussed out what causes that message to appear.
Also FWIW, I used the `zcat /proc/config.gz > .config
This also worked, no "Restart config" message appeared. I wonder if you actually have a 4.4.6 .config file in /usr/src/linux-4.4.21-gentoo
Edit to add, I see you appear to have a .config file, based on your `head` command output. Maybe there is a permissions issue, but I have no idea how that might come to exist. |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
jannis Guru
![Guru Guru](/images/ranks/rank_rect_3.gif)
Joined: 05 Dec 2004 Posts: 340 Location: Germany / Bavaria / Aschaffenburg
|
Posted: Fri Oct 07, 2016 1:52 pm Post subject: |
|
|
Alright, I've sorted it out:
The reason for the problem is commit 5aeaf8bd6c6a3f29a1ab55987c10741ef984ea52 ( http://lkml.kernel.org/r/1454499225-21544-2-git-send-email-bp@alien8.de ) that happened between 4.4.6 and 4.4.7 in combination with kernel configs that are NOT using initrds.
To solve the problem:
- Go to the kernel sources of 4.4.6
- Run make menuconfig there and enable the initrd option
- Copy the resulting .config to the sources version 4.4.21
- Run make menuconfig (which implies make oldconfig and won't restart/reset the config this time) and disable the initrd option again
- Build your kernel
|
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
|