onlog and dd'ing log tapes
Posted in 1997
Hi Family!
We have a client who would like to maintain an audit trail for every
blessed table in his database. If we were using SE, I would write a
script to create audit for every blessed table. However, since we are
using DSA (7.x) we need alternatives.
The most obvious: Run onlog scripts against the logs or log tapes. If
something suspicious has happened to a particular table, we can filter
the onlog with that table's partition number.
Objection from client: Since certain errors don't rear their heads until
months after the bad data was entered, we would have to keep log tapes
for many months. Could the audit be kept on a disk file someplace?
Well, that got me thinking, an unsafe practice at best. ;-) I already
know from experience that I cannot "dd" an ontape-created archive tape
to a disk file. ("dd" thinks it has found the EOT marker after 1 block.
This is a separate Informix idiosyncrasy I don't want to get into now.)
However, I have never had the occasion to try to dd an ontape-create log
backup tape to a disk file.
Q1: Has anyone else out there done this? Motivation: If it CAN be
done, then one could run a sequence of onlog commands against the
copies of the log tapes stored on disk, using -d <file-name> instead
of the name of the log-tape device.
Q2. Has anyone ever run onlog against a log tape create by OnArchive?
Or does onlog get confused by the different tape header on this
tape?
Q3. Has anyone ever run onlog against a log-backup on DISK as created by
OnArchive? I'm not certain if there is even a syntax for this. It
is certainly not mentioned in the [7.2] DSA Admin Guide!
It is unlikely I will ever be able to convince the client to use
OnArchive for backups, let alone for the mere purpose of a seldom-used
audit of events (Awrite! Who did what? ;-) So the answer to Q1 is
really the important one. Where I am, I have no log backup tapes to try
that dd. And terrible things would happen to me if I ran OnArchive here.
Thanks for any useful answers.
--
-- Jake (In pursuit of undomesticated aquatic avians)
+-----------------------------------------------------------+
| Impeccable Logic: A thought process which successfully |
| resists chicken bites |
+-----------------------------------------------------------+