servis 204 B

1234567891011121314
  1. #!/bin/bash
  2. if [ -z "$1" ]; then
  3. echo "kullanım: servis <servicename> start|stop|restart"
  4. exit 1
  5. fi
  6. if [ ! -f /etc/init.d/$1 ]; then
  7. echo "$1 servisi bulunamadı."
  8. exit 1
  9. fi
  10. /etc/init.d/$1 $2