You are required to develop a Linux kernel loadable module called las 02. ko. Th
ID: 3929119 • Letter: Y
Question
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 answerExplanation / Answer
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.
Related Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.