Reduce size of online.log?
Posted in 2000
Topics: General Discussion
I noticed in the /informix directory on my SCO server, that the file, online.log, continues to grow. Is there a way to reduce the size of the file so it doesn't continue to get larger? Thanks, Joel Sent via Deja.com http://www.deja.com/ Before you buy.
First, make sure that this file is in fact what it says it is by checking the MSGPATH and CONSOLE settings in your Informix onconfig file. Once verified that online.log is in fact the message log for Informix, you would have the following options (I am sure there are others): 1. Manually save the current file under another name and then delete the original. The new file will start growing again. 2. Implement a cron based script to periodically tail this file so you keep the last so many lines. You can find out how many lines a day takes on average in your current file and then choose to save, as an example, one week's worth of entries, however many lines they are... Keep in mind that the online log may give you useful information in case of problems, so you do not want to arbitrarily destroy the contents - or at least you want to save a reasonable history before you do... Hal Maner M Systems International, Inc. www.msystemsintl.com <jwz1@my-deja.com> wrote in message news:8nrfn1$fu2$1@nnrp1.deja.com... > I noticed in the /informix directory on my SCO server, that the file, > online.log, continues to grow. Is there a way to reduce the size of the > file so it doesn't continue to get larger? > > Thanks, > > Joel > > > Sent via Deja.com http://www.deja.com/ > Before you buy.
I'm assuming that you mean the message log file. When I was a system administrator/DBA I ran somthing like the following script each night. SAVDIR=$INFORMIXDIR/log_save D=`date '+%y.%m.%d'` mv message.log $SAVDIR/message.log.${D} cd $SAVDIR find . -name "message.log*" -ctime +30 -exec rm {} \\; jwz1@my-deja.com wrote: > I noticed in the /informix directory on my SCO server, that the file, > online.log, continues to grow. Is there a way to reduce the size of the > file so it doesn't continue to get larger? > > Thanks, > > Joel > > Sent via Deja.com http://www.deja.com/ > Before you buy.
On Mon, 21 Aug 2000 14:52:27 GMT, jwz1@my-deja.com wrote: >I noticed in the /informix directory on my SCO server, that the file, >online.log, continues to grow. Is there a way to reduce the size of the >file so it doesn't continue to get larger? > >Thanks, > >Joel > > >Sent via Deja.com http://www.deja.com/ >Before you buy. This is the question for SCO news group - I think comp.sco.unix.misc. There you can find question about reducing all LOG files like /usr/adm/syslog and others. If you cann't find question and answer I will sand you utility PRUNE that will help you. Nebojsa
Pardon my curosity. But why is this question for the SCO news group. From the mail he seems to be asking about the online.log. Cheers Pankaj remove (_at_) to reply wrote in message <16c4qs81ir7r855d36empjvnveeld528th@4ax.com>... |On Mon, 21 Aug 2000 14:52:27 GMT, jwz1@my-deja.com wrote: | |>I noticed in the /informix directory on my SCO server, that the file, |>online.log, continues to grow. Is there a way to reduce the size of the |>file so it doesn't continue to get larger? |> |>Thanks, |> |>Joel |> |> |>Sent via Deja.com http://www.deja.com/ |>Before you buy. | |This is the question for SCO news group - I think comp.sco.unix.misc. |There you can find question about reducing all LOG files like /usr/adm/syslog |and others. |If you cann't find question and answer I will sand you utility PRUNE that will |help you. | |Nebojsa
On Tue, 22 Aug 2000 09:21:04 +0100, "Pankaj" <pankaj@punks.demon.co.uk> wrote: > >Pardon my curosity. > >But why is this question for the SCO news group. From the mail he seems to be >asking about the online.log. > > >Cheers > >Pankaj Because there are a lot of log files in SCO Unix that will not be reduced by OS (for example /etc/utmp, /etc/utmpx, /etc/wtmp, /etc/wtmpx, /usr/adm/syslog, ...) and when you install Informix you have online.log, too. So the best thing, I think, you can do is to write cron procedure that will keep those files in some size and will cut them from the beginning. In that way you will have latest informations saved in those files. PRUNE utility (you can find source code, too) read from "configuration" file which files have to be reduced and what will be file size after reducing. I think that problem with online.log is the same as with other system log files and we found that using PRUNE utility is good solution. There are many other solutions too. Nebojsa