[SunHELP] command to check if a file is open and something is writing to it

Chris.Smith at txucom.com Chris.Smith at txucom.com
Tue Jul 15 20:57:51 CDT 2003


Or you can use fuser.  It will return the PID of the process that has it 
open.

Chris 





Dale Ghent <daleg at elemental.org>
Sent by: sunhelp-bounces at sunhelp.org
07/15/2003 06:24 PM
Please respond to The SunHELP List

 

To:
The SunHELP List <sunhelp at sunhelp.org>
cc:

Subject:
Re: [SunHELP] command to check if a file is open and something  is writing 
to it




On Tuesday, July 15, 2003, at 05:45 PM, Nguyen, David M wrote:

> I need to write a script to check if /var/adm/messages log is open and
> something is writing to it.  What command should I use to check that
> event, for example lsof command?
>

I don't know why you asked your question... you answered it yourself...

/dale
_______________________________________________
SunHELP maillist  -  SunHELP at sunhelp.org
http://www.sunhelp.org/mailman/listinfo/sunhelp



More information about the SunHELP mailing list