in reply to getting a child's process ID

I think what you're looking for is fork. -aijin