July 26th, 2005
Cool tool that you’re probably not using - Indirect files
Are you having trouble getting your weekly
or monthly database maintenance finished in a timely manner? Are
you just now upgrading and dread the HOURS that it will take to convert
the ODS of thousands of databases? Try using indirect files!
You may know what they are. The Admin Help tells you about them,
but it focuses on using them to upgrade. They can also be used routinely.
So what is an indirect file? It's the simplest of things - a plain
old text file. You create it with the powerful tool called "Notepad"
that ships with every copy of Windows. The content of the file can
vary, based on your needs, but the shortest one I've ever used contained
the text "mail1\". Save that file as mail1.ind, and you're
ready to rock. The idea is to break up that huge data directory on
your server into smaller blocks so you can run multiple, parallel instances
of your server maintenance task.
Side note: OK, the reason tasks such as fixup and compact take so
long is that they run serially. If the first database the task hits
is 1.9 G in size, the task churns away until it is finished, then starts
on the next database, which may only be 300 K. Using indirect files,
you can start multiple instances of tasks in parallel, allowing them to
finish faster. Back to your regular programming now.
So you take the contents of your data directory and somehow slice it up.
The easiest way is to use subdirectories, but you can dump a database list
and simply slice it up anyway you like. Take the indirect files you've
created (mail1.ind, mail2.ind, etc) and put them in the data directory
of your server. (This is actually only the easiest way to do this - you
can put them anywhere, but you'll have to type the path to the file when
you issue the command. As far as I'm concerned, the less typing I
do, the fewer mistakes I make.) Then you load your tasks. Tasks that
can utilize the files are compact, fixup and updall. You
can use whatever arguments you normally use with those command. The
example below if for Windows. If you run another OS, you'll know
how to make the commands work on your system.
Say you run a weekly compact task that runs an in-place compact with file
reduction. At a command prompt, change to your Lotus binaries directory
and type: "ncompact -B mail1.ind". The process will
start running against that file. Then with that task under way, open
ANOTHER command prompt, and do it again, this time typing "ncompact
-B mail2.ind". I tell administrators to keep going until the
servers scream if you're pressed for time, but the general rule is that
you can run as many tasks as you have processors, plus one or two if the
servers are down, as they might be during an upgrade.
GREAT BIG ASSUMPTION HERE: You're doing this when there are almost
no users on the server - you know how CPU-intensive this stuff is!
Since you're probably not interested in babysitting this on the weekends,
just set up multiple program documents, one for each .ind file, and let
them run. A working example is shown here:
Caveats:
- UNIX, AIX and Linux hate the backslash. You may need to test the formatting of the file a bit.
- If you're converting files from ODS41 to ODS43, ALWAYS use "compact -c -i" as your command as a minimum. You won't get corruption that way.
So give them a try if you haven't used them yet!

