You are required to develop a Linux kernel loadable module c
You are required to develop a Linux kernel loadable module called las 02. ko. The module should have a parameter pid_input. When the module is loaded it should print to the kernel log the following information of the process with pid that matches to the parameter: process id parent process id command line system time user time priority userid When the module is unloaded, it should display the same information for the parent process of the corresponding process. Test the module and make sure you handle all cases, exceptions and cover possible user mistakes. You must submit a compressed file that contains: 1- kernel module files 2- Print screen of the sample run 3- Output of the kernel log 4- output of the \"ps\" command and user id to support your answer
Solution
Here I am giving solution for the problem.
As soon as this module get loaded it will print the process information like process id .process parent id , process group,command line, system time, user time ,priority ,user id. Tested working fine on my Local machine.
