Usenet comp.unix.tru64 (2000-2013)
 help / color / mirror / Atom feed
* Reducing The size of /var/adm/messages file
@ 2002-09-17  2:35 DS Group
  2002-09-17  7:54 ` andy thomas
  2002-09-17 11:56 ` Nico Kadel-Garcia
  0 siblings, 2 replies; 4+ messages in thread
From: DS Group @ 2002-09-17  2:35 UTC (permalink / raw)


To reduce the size of the /var/adm/messages file, can I just open it with vi
and delete some of the lines it contains? Or is there another way? Thanks.




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Reducing The size of /var/adm/messages file
  2002-09-17  2:35 Reducing The size of /var/adm/messages file DS Group
@ 2002-09-17  7:54 ` andy thomas
  2002-09-17 11:56 ` Nico Kadel-Garcia
  1 sibling, 0 replies; 4+ messages in thread
From: andy thomas @ 2002-09-17  7:54 UTC (permalink / raw)


On Tue, 17 Sep 2002, DS Group wrote:

> To reduce the size of the /var/adm/messages file, can I just open it with vi
> and delete some of the lines it contains? Or is there another way? Thanks.

You could just do:

	cd /var/adm
	tail -100 messages > tmpfile
	cat tmpfile > messages

This saves the last 100 lines while preserving the open /var/adm/messages
file state.

Andy



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Reducing The size of /var/adm/messages file
  2002-09-17  2:35 Reducing The size of /var/adm/messages file DS Group
  2002-09-17  7:54 ` andy thomas
@ 2002-09-17 11:56 ` Nico Kadel-Garcia
  2002-09-18  7:13   ` andy thomas
  1 sibling, 1 reply; 4+ messages in thread
From: Nico Kadel-Garcia @ 2002-09-17 11:56 UTC (permalink / raw)



"DS Group" <dsgroup@sbcglobal.net> wrote in message
news:%xwh9.9789$yt3.4718644@newssrv26.news.prodigy.com...
> To reduce the size of the /var/adm/messages file, can I just open it with
vi
> and delete some of the lines it contains? Or is there another way? Thanks.

You have to stop and restart the syslog process.




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Reducing The size of /var/adm/messages file
  2002-09-17 11:56 ` Nico Kadel-Garcia
@ 2002-09-18  7:13   ` andy thomas
  0 siblings, 0 replies; 4+ messages in thread
From: andy thomas @ 2002-09-18  7:13 UTC (permalink / raw)


On Tue, 17 Sep 2002, Nico Kadel-Garcia wrote:

>
> "DS Group" <dsgroup@sbcglobal.net> wrote in message
> news:%xwh9.9789$yt3.4718644@newssrv26.news.prodigy.com...
> > To reduce the size of the /var/adm/messages file, can I just open it with
> vi
> > and delete some of the lines it contains? Or is there another way? Thanks.
>
> You have to stop and restart the syslog process.

If you do it the way I suggested in my posting earlier, you don't need to
stop/restart syslogd. I use the same technique with syslog.log files (on
other systems, not Tru64) and also with apache log files which means
apache needn't be stopped while the logs are pruned.

Andy




^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2002-09-18  7:13 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-09-17  2:35 Reducing The size of /var/adm/messages file DS Group
2002-09-17  7:54 ` andy thomas
2002-09-17 11:56 ` Nico Kadel-Garcia
2002-09-18  7:13   ` andy thomas

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