Re: Automatic Clearing of Logical Logs
Posted in 1998
Foo Chin wrote:
> > You realize, of course, that if your logical log archive device is a
> > tape drive, or even a file, that you are overwriting your previous
> > archive with each ontape -a command, assuming that there are any logs
> > to backup, and certainly with each cron execution. If your log archive
> > device is /dev/null then this is not needed as the logs clear
> > themselves. If you do not want to keep the log archives just set the
> > LTAPEDEV to /dev/null and be done with it.
> This is not really true for all applications running on IDS. When I read
> the manuals
> and also verified with the Informix Technical HelpDesk, they all claimed
> that the logs
> will clear themselves once you set the LTAPEDEV to /dev/null. Unfortunately
> from testing, certain
> application that accesses the IDS can't work once the onstat -l shows that
> all the logs are full even when the LTAPEDEV is set to /dev/null, that's
> why I posted this script, as
> I faced this problem with the application that I am working on. It is true
> however that the file
> I am writing to is actually a soft link to /dev/null. So for those of you
> who needs to backup
> your logs, do not use it. This script is only for those who don't need the
> logical logs and
> might find it a hindrance to your normal execution of your programs.
You've obviously recently upgraded from 5.xx. In 5.xx after a log was
backed up it's status was changed to 'F'. In 7.xx the status is left
as 'B' backed up and only changed to 'F' free immediately prior to the
log file being reused when the logs wrap around. The 'F' status lasts
only a fraction of a second, unless the unlikely circumstance that the
provious log exactly filled with the last activity and the engine has
suddenly gone quiet. HOWEVER, the logs ARE INDEED freed as soon as
they fill if the LTAPEDEV is set to the string "/dev/null" NOT A LINK.
The reporting was changed so that you could look at the archived log
files using onlog which you could not do in 5.xx because they had been
marked FREE. Believe me I've been doing this in 7.[123]x for several
years with no problem. (I have yet to convince my sysadmin to allocate
the 8-10GB I need for 5 days worth of logs on disk.)
Art S. Kagel