[geeks] Killing process by name with cron.

Tugrul Galatali geeks at sunhelp.org
Sun Jul 22 14:21:54 CDT 2001


On Sun, 22 Jul 2001, William S. wrote:

> I have my PC166MMX playing streaming audio at night
> and usually fall asleep with it running. I use a
> ncurses app called trplayer to do this. The problem
> is, in the morning cron runs various programs that max
> out the memory and lock up the whole thing. What I
> would like to do is set up a "kill" in my6 crontab to
> kill trplayer and give me some memory "elbow room".

	Lock up as in stuck in thrashing or like crash? That shouldn't happen.

> Is there any script I can write that can kill the
> process by name? Something like ps -a | grep trplayer
> | kill bla bla bla?
> 
> Any suggestions?

	Linux? "man killall"
	FreeBSD? "man killall" (probably Net/Open too)
	Solaris? "man pkill"

	Tugrul Galatali (damn Solaris killall =P)





More information about the geeks mailing list