I was in a similar situation where I couldn't recall why a RoR instance was running on one of the ports.
So I did a ps -auxww to get the process id of the process and then
cp> cd /proc/[process_id]/cwd
cp> pwd
/home/cpatil/....
Pretty cool!
/proc is a virtual filesystem and allows you to peek inside the OS kernel at runtime and find information about the processes running on the machine. Google for it, a one time read is a must for all linux users, young and old.
It is quite funky the way it is set up. For e.g. most files are 0 bytes and you need to do a cat to read it. Stuff like that.
No comments:
Post a Comment