Here is the ability to schedule/automate the compact of open databases like names.nsf. log.nsf and statrep.nsf....
Do you have to compact statrep.nsf on Saturday because you need to bring down the Notes server? I used WinAT to schedule this on a Sunday morning. I created a small CMD file and scheduled that with WinAT. The files I used are from the Resource Kit (sleep.exe, shutdown.exe, winAT.exe).
- Set the NT Schedule service to start automatically. - Copy Sleep.exe , Shutdown.exe and the WinAT files (all from the NT ResourceKit) to c: as well as the cmd file ntdown.cmd. - Modify the ntstart.cmd file to your specific needs (time delays, path descriptions etc.). - Start WinAT and schedule the file c:ntdown.cmd to run at a certain time.
I tested it (I suggest you do that too) and it works just fine.
I had a problem on the spokes (mailservers). When starting the server, Notes client always prompts me to select the ID file. So when the DOS box opened and the compact wants to start, it prompts me for a password of the ID file as well. On the HUB server (where no users connect to, only other servers for mail routing and replication) I did not have that problem.
I had PcAnywhere on the servers. Therefore, I called in from home sometime before the scheduled task, take over the server console with PcAnywhere, start the client, select the server ID and shut down the client again.
It seems that at working hours, the client sessions disturb the last stored used ID setting. In the notes.ini, I did have the two lines: - KeyFilename = ... - ServerKeyFilename = nlschs01.id
code for the file ntdown.cmd: c: cd notes c:\notes\nserver -q c: cd\ c:\sleep 10 c: cd notes c:\notes\ncompact d:\notes\data\statrep.nsf c: cd\ c:\sleep 10 c: cd notes c:\notes\ncompact d:\notes\data\log.nsf c: cd\ c:\sleep 10 c: cd notes c:\notes\ncompact d:\notes\data\names.nsf c: cd\ c:\sleep 10 c:\shutdown /L /R /T:60 "Lotus Notes server is rebooting in 1 minute" /Y /C