tru64-unix-managers (formerly alpha-osf-managers) (1994-2012)
 help / color / mirror / Atom feed
* SUMMARY: Problem using cat /dev/null
@ 2001-11-08 16:11 Myszkowski.Mark
  0 siblings, 0 replies; only message in thread
From: Myszkowski.Mark @ 2001-11-08 16:11 UTC (permalink / raw)
  To: tru64-unix-managers

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: multipart/mixed; boundary="------_=_NextPart_001_01C16870.0F6E3070", Size: 3006 bytes --]

This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.

------_=_NextPart_001_01C16870.0F6E3070
Content-Type: text/plain;
	charset="iso-8859-1"

Thank you.  I got many responses but I think we will implementing a solution
along the lines of this suggestion.

From Narendra Raavi

If the file is still open, and busy, you cannot reset the log file. We have
had this problem, but have solved it in a different way.

We get the process/program to write to a named pipe. We have another (Perl)
program that reads the pipe and writes to a log file while periodically,
switching log file extensions, based on the size of the log file.



Hello,
I am trying to use 
cat /dev/null > a.log
to reset a log file.  Unfortunately, when I do this the log file returns to
it's original size the next time that the application writing to that log
makes an update.  How can I reset a log that is being written to by a
program without stopping the program?
Thank you,

Mark Myszkowski


------_=_NextPart_001_01C16870.0F6E3070
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; =
charset=3Diso-8859-1">
<META NAME=3D"Generator" CONTENT=3D"MS Exchange Server version =
5.5.2653.12">
<TITLE>SUMMARY: Problem using cat /dev/null</TITLE>
</HEAD>
<BODY>

<P><FONT SIZE=3D2 FACE=3D"Courier New">Thank you.&nbsp; I got many =
responses but I think we will implementing a solution along the lines =
of this suggestion.</FONT>
</P>

<P><FONT SIZE=3D2 FACE=3D"Courier New">From Narendra Raavi</FONT>
</P>

<P><FONT SIZE=3D2 FACE=3D"Courier New">If the file is still open, and =
busy, you cannot reset the log file. We have</FONT>
<BR><FONT SIZE=3D2 FACE=3D"Courier New">had this problem, but have =
solved it in a different way.</FONT>
</P>

<P><FONT SIZE=3D2 FACE=3D"Courier New">We get the process/program to =
write to a named pipe. We have another (Perl)</FONT>
<BR><FONT SIZE=3D2 FACE=3D"Courier New">program that reads the pipe and =
writes to a log file while periodically,</FONT>
<BR><FONT SIZE=3D2 FACE=3D"Courier New">switching log file extensions, =
based on the size of the log file.</FONT>
</P>
<BR>
<BR>

<P><FONT SIZE=3D2 FACE=3D"Arial">Hello,</FONT>
<BR><FONT SIZE=3D2 FACE=3D"Arial">I am trying to use </FONT>
<BR><FONT SIZE=3D2 FACE=3D"Arial">cat /dev/null &gt; a.log</FONT>
<BR><FONT SIZE=3D2 FACE=3D"Arial">to reset a log file.&nbsp; =
Unfortunately, when I do this the log file returns to it's original =
size the next time that the application writing to that log makes an =
update.&nbsp; How can I reset a log that is being written to by a =
program without stopping the program?</FONT></P>

<P><FONT SIZE=3D2 FACE=3D"Arial">Thank you,</FONT>
</P>

<P><FONT SIZE=3D2 FACE=3D"Arial">Mark Myszkowski</FONT>
</P>

</BODY>
</HTML>
------_=_NextPart_001_01C16870.0F6E3070--

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2001-11-08 16:11 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-11-08 16:11 SUMMARY: Problem using cat /dev/null Myszkowski.Mark

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox