# I can boot with kernel 4.18.10, but not with 4.18.11

## hariskar

I get no screens found error. I use nvidia drivers. Is it some new configuration in the kernel I have to do?

----------

## Keruskerfuerst

How did you configure the new kernel ?

----------

## hariskar

root #cd /usr/src/linux

root #make olddefconfig

root #make

but before that with 

emerge -c sources of 4.18.10 were deleted (by mistake) and re-installed. I guess all configuration of config file of 4.18.10 is lost?

----------

## joanandk

 *hariskar wrote:*   

> root #cd /usr/src/linux
> 
> root #make olddefconfig

 

Prior to make oldconfig, you did copy the running .config from the 4.18.10 source directory to /usr/src/linux?

BR

----------

## hariskar

Yes I did. I have done the proceedure many times with previous kernel updates without problem.

----------

## toralf

 *hariskar wrote:*   

> but before that with 
> 
> emerge -c sources of 4.18.10 were deleted (by mistake) and re-installed. I guess all configuration of config file of 4.18.10 is lost?

 Well, that's why 

```
/proc/config.gz
```

was developed for.

----------

## hariskar

I don't have such a file.. Will I stay with 4.18.10 forever??   :Shocked: 

----------

## toralf

 *hariskar wrote:*   

> I don't have such a file.. Will I stay with 4.18.10 forever??  

 IMO "emerge -C" does not delete files outside of its (==Gentoos ebuild) scope, therefore /usr/src/linux/.config should therefore stay where it is. Of course it is overwritten/backed up my the next "make menuconfig" to .config.old. It is still worth a try to look for that file.

----------

## Yamakuzure

The old config is in

  /usr/src/linux-4.18.10-gentoo/.config

and stays there when you unmerge the sources.

The new config will be in 

  /usr/src/linux-4.18.11-gentoo/.config

The simplest way is to copy the old .config into the new folder and run 'make oldconfig' and not olddefconfig. That one will set new symbols to their default value without prompting, which was not what I wanted in many cases. Like supporting new hardware, which always defaults to Y.

However, normally a patchlevel update never yields any additions/removals that would make 'oldconfig' prompt for anything...

Well, you *did* remember to run 'emerge @module-rebuild" after building the new kernel?

----------

## hariskar

'emerge @module-rebuild"

was the solution!

But I wonder why. I never run it and never had problems..

Thank you!

----------

## Tony0945

Amplifying Toralf's remarks:

When you make menuconfig, under "General Setup" you with find a checkbox " Enable access to .config through /proc/config.gz "

This will enable CONFIG_IKCONFIG_PROC   which will do as it says. So if you ever lose the .config you can restore it from the running kernel with 

```
zcat /proc/config.gz > /usr/src/linux/.config
```

----------

## ups

 *Yamakuzure wrote:*   

> 
> 
> The simplest way is to copy the old .config into the new folder and run 'make oldconfig' and not olddefconfig. That one will set new symbols to their default value without prompting, which was not what I wanted in many cases. Like supporting new hardware, which always defaults to Y.
> 
> However, normally a patchlevel update never yields any additions/removals that would make 'oldconfig' prompt for anything...
> ...

 

I usually do 'make localmodconfig', the benefit of this is that all unnecessary stuff is removed from the kernel. But you need to carefully configure the first kernel on every machine by hand and load all modules just before every updates.

----------

## k9dog

Well answered a bit off topic in my previous posts.

Copying your old configuration is answered with the previous answers and I think your own solution with emerge @module-rebuild was your answer.

It might be an idea to create a new kernel from scratch though (if you can boot more than one  :Smile:  )

I think I'd go with a new boot cd (you could "-o loop" mount the iso, the config is in /boot).

I would copy the config into a recent kernel source as .config.

Update system if you haven't and can

Since you are running nvidia proprietary driver, i would disable the nouveau driver.

I'd run : lspci | grep VGA to see my driver

Visit https://www.nvidia.com/Download/index.aspx to search for my driver version

Install the driver: emerge =x11-drivers/nvidia-driver-<version> (or something close but not later)

^^ You could install after you build kernel too, otherwise emerge @module-rebuild rebuilds

(I'll presume grub and genkernel is installed)

For compile of kernel I use this script:

```
cd /usr/src/linux

make clean

# edit -j4 if you got more/fewer kernels

nice -n 10 make -j4

make modules

emerge @module-rebuild

make modules_install

mount /boot

make install

genkernel initramfs

grub-mkconfig -o /boot/grub/grub.cfg

```

This might help a bit. just be sure you can fallback on your old kernel etc.

----------

