1.

Solve : Write the script to stop and restart the daemon?

Answer»

There are two two tasks I need to CHECK whtat is the process id, once I find the process id, I need to kill the daemon.

Is it USE the if.. then....else

Thanks
look at pgrep, pkill, pidof ETC. then read up on shell scripting.What PROGRAM are you WANTING to kill? If it has a name, you can use this:
Code: [Select]#!/bin/bash
killall [name of program]Make sure to replace "[name of program]" with your program name.



Discussion

No Comment Found