Sunday, April 6, 2014

Upgrading Debian Wheezy's kernel



Upgrade form Debian Wheezy 64 bit (with GDM3/xfce) 3.2.0 to 3.14.0 kernel level/version.
(
you might also want to take a look at this tutorial as well if you are interested in creating kernel.xx.xxx.deb ready for installation packages-
http://pevma.blogspot.se/2014/07/kernel-upgrade-for-debian.html
)
First we need some tools:
apt-get install gcc libncurses5-dev bc ca-certificates pkg-config make flex bison build-essential autoconf automake
Make sure everything is updated/upgraded:
 apt-get update && apt-get upgrade
 apt-get dist-upgrade
 Just to get read of some cached space:
 apt-get clean

 Download and build the kernel:
 wget https://www.kernel.org/pub/linux/kernel/v3.x/linux-3.14.tar.xz
 tar xvfJ linux-3.14.tar.xz -C /usr/src
 cd /usr/src/linux-3.14/
 yes "" | make oldconfig


 This could take 20 min:
 make
Make and install the modules and the kernel
 make modules_install install
Verify:
root@debian64:~# ls -lh /boot
total 149M
-rw-r--r-- 1 root root 129K Apr  5 19:28 config-3.14.0
-rw-r--r-- 1 root root 127K Feb  1 20:16 config-3.2.0-4-amd64
drwxr-xr-x 3 root root  12K Apr  5 19:30 grub
-rw-r--r-- 1 root root 129M Apr  5 19:30 initrd.img-3.14.0
-rw-r--r-- 1 root root  10M Mar 11 09:26 initrd.img-3.2.0-4-amd64
-rw-r--r-- 1 root root 2.3M Apr  5 19:28 System.map-3.14.0
-rw-r--r-- 1 root root 2.1M Feb  1 20:16 System.map-3.2.0-4-amd64
-rw-r--r-- 1 root root 3.1M Apr  5 19:28 vmlinuz-3.14.0
-rw-r--r-- 1 root root 2.8M Feb  1 19:51 vmlinuz-3.2.0-4-amd64
root@debian64:~#

 your /boot/grub/grub.cfg should have a similar section (notice the new 3.14.0) :



 Make sure you have at least one non root user
 reboot


 If you want to log into the Desktop Manager as root:
 log in with the non root user.

 su root
 vim  /etc/pam.d/gdm3

 comment out (like shown)
 #auth   required    pam_succeed_if.so user != root quiet_success
 save the file

 change the root password
 passwd root
 reboot

 You can log in as root if you want to.
 Make sure you are with running the latest packages:
 apt-get update && apt-get upgrade
root@debian64:~# uname -a
Linux debian64 3.14.0 #1 SMP Sat Apr 5 19:19:46 EDT 2014 x86_64 GNU/Linux
root@debian64:~#

 Done.



2 comments: