Remove legacy procs monitoring code and improve current code.