How to find the pid of the a given process.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi All,

I have given an assignment to find out the pid of the process from its's name. I am not supposed to use proc filesystem as well as ps output. I am supposed to write a USER SPACE C program input to it will be a program name string, say bash, and then it should print corresponding PID.
The next part of the assignment is to find the PPID of a given process and then print it's tree till init process.

I am clue less of how to do it.
Please someone help. Please give some hints. Thanks in advance.

Thanks and Regards,
Prasad.

[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux