logrotate and perl file handles. How do I know when to reopen my log file?

2004-01-29 Thread TeamSolCO
I have written a long running perl application to help me with some trivial administrative functions. Due to the volume of logging generated by this application, I am managing its output with logrotate. The problem I face is that perl is "following" the log files that logrotate swaps out.

Re: logrotate and perl file handles. How do I know when to reopen my log file?

2004-01-29 Thread TeamSolCO
om: "Robby Russell" <[EMAIL PROTECTED]> To: "TeamSolCO" <[EMAIL PROTECTED]> Sent: Thursday, January 29, 2004 4:54 PM Subject: Re: logrotate and perl file handles. How do I know when to reopen my log file? : TeamSolCO typed this on 01/29/2004 01:16 PM: : > I ha

Re: logrotate and perl file handles. How do I know when to reopen my log file?

2004-01-29 Thread TeamSolCO
t.pid : >/dev/null` 2>/dev/null || true : endscript : } : : perhaps calling it "myPerlScript.log". Note - replace "myPerlScript" with : the actual name of your Perl script. Note that when the signal handler : actually executes, the previous myPerlScript.log file has alread

Can't use global FILEHANDLEs?

2004-01-30 Thread TeamSolCO
To start, let me say this: 1) I have both "Learning Perl 3rd Ed" and "Programming Perl 3rd Ed" 2) I have read "Learning Perl 3rd Ed", and I use "Programming Perl 3rd Ed" as reference. 3) I have searched with Google for several key words related to my problem, but the mass of junk I get back is no

Re: Can't use global FILEHANDLEs?

2004-01-30 Thread TeamSolCO
Awesome. This tip cleared the problem right up; thanks for explaining it! - Original Message - From: "Steve Grazzini" <[EMAIL PROTECTED]> To: "TeamSolCO" <[EMAIL PROTECTED]> Cc: "Perl Beginners List" <[EMAIL PROTECTED]> Sent: Friday,

Re: Can't use global FILEHANDLEs?

2004-01-31 Thread TeamSolCO
: > 4) The application source is roughly 450 lines long, and the FAQ for this : > list asks users not to mass-post such things, otherwise I'd post it here : > en-masse for help. : If you could post it somewhere where it can be downloaded, that would be : best. I'll consider that, but people intere

Re: Can't use global FILEHANDLEs?

2004-01-31 Thread TeamSolCO
: > I'm sure I read it somewhere, but I had forgotten about the qwirky : > system() return. Based on your recommendation, I have fully rewritten : > that (and similar) segment of code to be more sensitive to failure : ? (useless $! values will just come with the territory): : > : > unless ((unli

Re: Can't use global FILEHANDLEs?

2004-01-31 Thread TeamSolCO
This matter has already been resolved. Thank you for following up. : TeamSolCO wrote: : : > To start, let me say this: : > 1) I have both "Learning Perl 3rd Ed" and "Programming Perl 3rd Ed" : > 2) I have read "Learning Perl 3rd Ed", and I use "Prog