openSUSE Forums > Archives > SF Archives > ARCHIVES - Tips, Tricks & Tweaks » Cliffnotes: How To Recompile A New Suse Kernel

Go Back   openSUSE Forums > Archives > SF Archives > ARCHIVES - Tips, Tricks & Tweaks
Forums FAQ Members List Search Today's Posts Mark Forums Read


ARCHIVES - Tips, Tricks & Tweaks Tips and Solutions for SUSE Linux
(Please do not post questions here)

 
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 01-Nov-2007, 22:02
famewolf
Guest
 
Posts: n/a
Default

Suse does an excellent job of giving us out of the box kernel's that will run almost anything...so good in fact it's been ages since I had to compile my kernel..and during that time the process has gotten alot simpler...I thought I would throw a quick reminder together of the steps to custom compiling a kernel (and keeping your old one as a backup).

1) Make sure you have gcc gcc-c++ make, autogen, autoconf and kernel-source installed.
2) If you use ndiswrapper make sure you have the .tar.gz of the latest version and the windows files you will need because you will have to reinstall ndiswrapper afterward. ( Boot under your kernel and do following: (cd to ndiswrapper dir - make clean ; make ; sudo make install ; sudo ndiswrapper -r <driver> ; sudo ndiswrapper -i <driver>.inf ; sudo modprobe ndiswrapper> )
3) If you use virtualbox make sure you have the latest rpm from virtualbox.org handy because you can do a "rpm -Uvh virtualbox*.rpm --force" and at the end it recompiles your kernel module. (do this after booting off new kernel)
4) If you are using usb-rndis-lite for internet sharing via a wm6 phone cd to the dir of the drive and do following: make clean ; make ; sudo ./clean.sh ; sudo make install (do this after booting off new kernel)
5) Any other special modules you use I didn't list..have them ready.

6) Cd to /usr/src/linux and type "make cloneconfig"...if it works it should copy all your current kernel options and build a .config.
7) type "make menuconfig"...if you get an error make sure you have ncurses-devel installed and try again.
8) Here is where you change what you want...first stop:
Processor type and features --->
Processor Family ---> Here's your chance to pick AMD...Athlon64 etc....

9) Desktop Tweaks: The new kernel includes some tweaks to reduce response time on the desktop..gives users a snappier feel. I choose to use these tweaks...here they are:
Processor type and features --->
Enable:
Preemption Model (Preemptible Kernel (Low-Latency Desktop))
Preempt The Big Kernel Lock
Change Timer frequency to (1000 HZ)
--- The help on each of these will explain them better than I can. ---

10 Under General Setup change Local version from "-default" to something else like "-amd" or "-mykernel". This is what prevents a conflict with current kernel.

11) Any other tweaks you wanna make......

Wrapping up.... exit out until it asks if you want to save your config and select yes.

Execute the following in order and make sure you don't get any errors:
make clean
make all
make modules_install install

No the last wasn't a typo or a repeat...it first installs the modules..then the kernel...if you have grub it adds a new menu option for your custom kernel but the OLD kernel is STILL the default...now's the time to try a reboot and select your kernel and see if you have any problems....if you DO, it's as simple as rebooting again and let it select the default one..then trying again.

If you DON'T have any problems booting...well now is the time to reinstall all those kernel modules I mentioned earlier and start enjoying your "optimized" kernel.

Hope it helps someone....changing the local version prevents ALOT of grief if things go wrong.






 

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




 

Search Engine Friendly URLs by vBSEO 3.3.0 RC2