On Friday 14 November 2003 10:14 am, Oleg Broytmann wrote:
> On Fri, Nov 14, 2003 at 09:06:38AM -0600, Skip Montanaro wrote:
> > On a related note, restarting the scgi server is a little bit of a pain.
> > Is this the best I can do
> >
> > ps auxww | egrep 'python main' | egrep -v egrep \
> >
> > | awk '{print $2}' | sort -n | xargs kill -1
> >
> > (Thank goodness for bash command recall!)
>
> From my .shellrc:
>
> psg() { ps auxw | egrep -i ${1+"$@"} | grep -v grep; }
> psgw() { ps auxwww | egrep -i ${1+"$@"} | grep -v grep; }
>
> pidOf() { psgw ${1+"$@"} | awk '{print $2}'; }
> KillAll() { pidOf "$1" | xargs kill "$2"; }
Put it on the wiki, man!
Maybe create a RecipeSection or TipsAndTricks page.
--
Mark Bucciarelli, www.hubcapconsulting.com
As we enjoy great advantages from inventions of others, we should
be glad of an opportunity to serve others by any invention of ours;
and this we should do freely and generously. -- Benjamin Franklin