Showing posts with label kernel compile on ubuntu vksalian. Show all posts
Showing posts with label kernel compile on ubuntu vksalian. Show all posts

Sunday, December 25, 2011

Create ISO files and mount ISO files a folder.

In Linux (Ubuntu) it is possible to convert a contents of a folder into an "iso" file just using the command given below.

mkisofs -o /home/linuxlookup/example.iso /source/directory/

Similarly, you can mount an "iso" image as a folder using the coomand below.

# mount -o loop disk1.iso /mnt/

Similarly, to mount an "iso" as a drive use the below command,

sudo mount /home/vijays/redhat_4.8.iso /mnt/ -t iso9660 -o loop

Monday, November 28, 2011

How to compile a kernel from kernel.org in Ubuntu 10.04 LTS.

This quick how-to is based on http://linuxtweaking.blogspot.com/2010/05/how-to-compile-kernel-on-ubuntu-1004.html

Open a terminal and work through the following set of commands.

Install these packages

sudo apt-get install fakeroot kernel-wedge build-essential makedumpfile kernel-package libncurses5 libncurses5-dev

Run this

sudo apt-get build-dep --no-install-recommends linux-image-$(uname -r)

Create your source directory

mkdir ~/src
cd ~/src

Download and extract your kernel


You can browse for kernels at http://www.kernel.org/pub/linux/kernel/v2.6/ This guide is using kernel 2.6.37.

wget http://www.kernel.org/pub/linux/kernel/v2.6/linux-2.6.37.tar.gz
tar xvf linux-2.6.37.tar.gz
cd linux-2.6.37

Configure your Kernel

make menuconfig

Build your Kernel

export CONCURRENCY_LEVEL=3
make-kpkg clean
time fakeroot make-kpkg --initrd kernel-image kernel-headers

General rule, concurrency level = number of processor cores + 1


Install your kernel

cd ~/src

dir        
sudo dpkg -i linux-image-2.6.37_2.6.37-10.00.Custom_amd64.deb
sudo dpkg -i linux-headers-2.6.37_2.6.37-10.00.Custom_amd64.deb

Create the initramfs image

sudo update-initramfs -c -k 2.6.37

Update your grub.cfg

sudo update-grub

Reboot your system


Enjoy your new kernel.