Re: oaf-slay improvements



Brian Cameron <Brian Cameron Sun COM> wrote: 
[snip]
> > > $ps_cmd = "/bin/ps -e -opid,user,args | /bin/grep ".$username;
> > 
> > and that assumes a SVR4-style ps. Is there some perl module that can be
> > used for process listing stuff instead?
> 
> I'm not aware of any standard Perl module that shelters Perl users from
> the "ps" command.  I've typically seen Perl programs deal with this
> by checking uname and building the appropriate ps command.  I tested
> the script I provided on Solaris and Linux and it works okay.  Someone
> will likely need to hack it a bit to get it to work on BSD, but that
> should be just a little work.
> 
> If there is a standard Perl module that can be used, point me towards it
> and I'll happily update the script to use it.
[snip]
Don't know if it is standard, but Proc::ProcessTable.

http://cpan.valueclick.com/modules/by-category/04_Operating_System_Interfaces/P
roc/DURIST/

 /mill

-- 
#############################################################
# S-mail: Olof Oberg     #  mill pedgr571 sn umu se         #
#         Pedagoggr. 7A  #  mill ludd luth se               #
#         S-907 30 Umea  #  tdv94oog cs umu se              #
# Phone:  090-197395     #  http://pedgr571.sn.umu.se/~mill #
#############################################################






[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]