Compiling and Installing Custom Linux Kernel

Compiling and Installing Custom Linux Kernel
The below mentioned steps will work in Ubuntu or debian like systems. I have tested it on Ubuntu 10.10.
Download and unzip(preparing)
sudo apt-get update
sudo apt-get install kernel-package libncurses5-dev fakeroot wget bzip2
Download the kernel sources and unzip as shown below.
sudo tar xjf linux-2.6.18.1.tar.bz2sudo ln -s linux-2.6.18.1 linuxsudo cd /usr/src/linux

Configuring the Kernel
sudo cp /boot/config-`uname -r` ./.config
sudo make menuconfig
Then browse through the kernel configuration menu and make your choices. When you are finished and select Exit, answer the following question (Do you wish to save your new kernel configuration?) with Yes:
Build the Kernel
sudo make-kpkg cleansudo fakeroot make-kpkg –initrd –append-to-version=-custom_1.0 kernel_image kernel_headers
After –append-to-version= you can write any string that helps you identify the kernel, but it must begin with a minus (-) and must not contain whitespace.
Now be patient, the kernel compilation can take some hours, depending on your kernel configuration and your processor speed.
Install the new Kernel
sudo cd /usr/srcsudo ls -l
This will list the kernel files if everything was fine.
Install them like this:
sudo dpkg -i sudo dpkg -i
Now reboot the system
sudo shutdown -r now
If everything goes well, it should come up with the new kernel. You can check if it’s really using your new kernel by running
sudo uname -r

Unistalling the Kernel
Remove files
  1. /boot/vmlinuz*KERNEL-VERSION*
  2. /boot/initrd*KERNEL-VERSION*
  3. /boot/System-map*KERNEL-VERSION*
  4. /boot/config-*KERNEL-VERSION*
  5. /lib/modules/*KERNEL-VERSION*/
  6. /var/lib/initramfs-tools/
Run the command
sudo update-initramfs -k all -u

No Sound from Ubuntu linux or Mint

No Sound from Ubuntu linux or Mint
Searched google for possible answer to the problem but solution mentioned was not sufficient to solve my issues. I wasted couple of weekends resolving this issue.Finally I solved by removing PulseAudio and ALSA packages and installing OSS(Open Sound System)
What is OSS?OSS provides low -level audio drivers for users and a common API(application program interface) for developers. Unbutu and Mint by default uses ALSA ( Advanced Linux Sound Architecture) to provide audio drivers.

Does OSS support my hardware?

Check the list of supported hardware from the below link.
http://opensound.hg.sourceforge.net/hgweb/opensound/opensound/file/3db750724c2d/devlists/Linux

Preparing to install OSS

1. REMOVE Pulseaudio packages

sudo apt-get purge pulseaudio gstreamer0.10-pulseaudio

2. Removing ALSA packages

sudo /etc/init.d/alsa-utils stop

sudo apt-get remove alsa-base alsa-utils

3. Blacklisting ALSA Kernel Modules

sudo dpkg-reconfigure linux-sound-base

4. Installing Prerequisite Packages

The second command contains some recommended packages.

sudo apt-get install -y binutils libgtk2.0-0 sed gcc libc6

sudo apt-get install -y libesd0 libsdl1.2debian-oss

 

Installing OSS

1. Installing from DEB File

Download the OSS deb file from the 4front website(http://www.opensound.com/download.cgi). Before you install OSS, Reboot your system so that the ALSA modules will not load or interfere with it. When you log back in, use the terminal to install the OSS deb file (GDebi fails to install this .deb for some reason)

sudo dpkg -i oss-linux*.deb

Configuring Applications to Use OSS

Type ossxmix in your terminal to launch the mixer.

YOU ARE DONE

“I have not failed. I’ve just found 10,000 ways that won’t work” –Thomas Edison