Subject: Re: signal confusion
To: dustin sallings <dustin@spy.net>
From: Paul B Dokas <dokas@cs.umn.edu>
List: current-users
Date: 11/06/1998 21:36:57
On Thu, 5 Nov 1998, dustin sallings wrote:
> On Thu, 5 Nov 1998, Paul B Dokas wrote:
> // BTW, I've other wise solved this problem in my program by rewriting
> // it. Expect a psh type program (see the thread of about 2 weeks ago)
> // soon!
>
> Wouldn't it make more sense to just use psh? :)
Darn! And I've just about finished it too.... So where do I find psh?
I've done a basic search and haven't found it.
I guess that this whole thing has boiled down to an programming exercise.
What I've built is a program to perform complex foreach-like loops for
security-checking purposes. Something like this (in csh syntax):
foreach i (`cat machines`)
rsh $i 'find /dev -type -print' | fgrep -v MAKEDEV
end
foreach i (`cat moremachines`)
rsh $i 'cat ~root/.rhosts'
end
but all in parallel, keeping N rshs running simultaneously.
The only thing that I added is probably best summed up by looking at
a sample config file:
%sunservers = {server1, server2};
%sunclients = {sun1, sun2, sun3, sun4, sun5, sun6};
%suns = (%sunservers + %sunclients);
%sunservers: /usr/local/sbin/servercheck
%sunclients: /usr/bin/perl
#
# insert perl script here to check clients
#
%suns: find /dev -type f -print
Yes, I added a full YACC frontend that lets you define sets of things,
do set operations on them. You can even execute a command and use
it's results to define a set...
<sigh>
Oh well, in hind sight I've reinvented the wheel twice by 1) duplicating
the functionality of psh and 2) by creating a C program to handle sets
where a relatively simple perl script would suffice.
Anyone want a copy? It's mostly done. :-)
Paul
--
Paul Dokas dokas@cs.umn.edu
======================================================================
Don Juan Matus: "an enigma wrapped in mystery wrapped in a tortilla."