Monday, October 27, 2014

How to compile Linux kernel module.

** In the following example Ubuntu 12.04 is used.
** Ubuntu 12.04 is installed on VMware as VM

Steps are as follows:
1. Login as "root"
2. Execute following commands.
   a. sudo apt-get update
   b. sudo apt-get install make
   c. sudo apt-get install build-essential
   d. sudo apt-get install linux-headers-$(uname -r)
3. create a Makefile using following command
          vi Makefile
4. insert following content into the Makefile and save it.








5. create "hello.c" file and insert following content.
 











 
 


6. Keep both "Makefile" and "hello.c" file in same directory.
7. execute following commands
    a. make
    b. insmod hello.ko
          After executing above command you should get the message "Hello, Baby..."
          This command load the "hello" module.
    c. rmmod hello
        output:  "Goodbye, cruel world....."
          This command unload the above inserted module.



*Oracle VirtualBox can be use as an alternative for VMware (See how to)
*See how to install Ubuntu on Oracle VirtualBox. (link)




-Thank  you




 

 
 

Monday, October 20, 2014

How to install Ubuntu on Oracle VirtualBox.

To install Ubuntu onto VirtualBox follow below mentioned steps.

1.   Download Ubuntu OS from below link.
        For latest version: http://www.ubuntu.com/download/desktop
        For old releases : http://old-releases.ubuntu.com/releases/

2.   Download and install Oracle VirtuaklBox. [See How To]

3.   Watch below video to install Ubuntu onto VirtualBox
     
       Link: http://youtu.be/Kk7Fhdy3Ypw

*The same way you can install any OS onto Oracle VirtualBox


-Thank you

 

 

How to Install Oracle Virtual Box

Follow below steps to Install Oracle VirtualBox.
* Here I am Using VirtualBox for Windows 64.

Go to the link below Download VirtualBox.
http://www.oracle.com/technetwork/server-storage/virtualbox/downloads/index.html

Watch the below Video to install Oracle VirtualBox.


YouTube link :  http://youtu.be/7z9DoEu_OVw
Next session we'll discuss how to install an OS onto Oracle VirtualBox.


-Thank You