参考两篇文章
http://www.centoscn.com/CentOS/config/2014/1124/4170.html 的前半部份
http://ju.outofmemory.cn/entry/63491
29 yum update -y 30 yum upgrade -y 31 yum install gcc gcc-c++ xz bc ncurses-devel 32 yum install hmaccalc zlib-devel binutils-devel elfutils-libelf-devel 33 cd /usr/local/ 34 ll 35 cd src 36 ll 37 wget https://www.kernel.org/pub/linux/kernel/v3.x/linux-3.12.17.tar.xz 38 ll 39 tar zxvf linux-3.12.17.tar.xz 40 tar -xf linux-3.12.17.tar.xz 41 ll 42 sudo yum groupinstall "Development Tools" # 一口气安装编译时所需的一切工具 43 sudo yum install hmaccalc zlib-devel binutils-devel elfutils-libelf-devel #创建 CentOS-6 内核时需要它们 44 uname -r 45 ll 46 cd linux-3.12.17 47 ll 48 cp /boot/config-2.6.32-431.el6.x86_64 .config 49 sh -c 'yes "" | make oldconfig' 50 sudo make -j18 bzImage 51 sudo make -j18 modules 52 sudo make -j8 modules_install 53 sudo make install 54 vim /etc/grub.conf 55 sudo reboot