Better process tracking

This update allows the process count(s) to be correctly calculated based on the output of the ps command. Additionally, the $jail_id variable needed to be trimmed, as it had trailing whitespace - "3 " instead of "3".