Python script to check if service is running linux