Using the sample Server.Load scripts

Many of these scripts were created using a specific template that may change from release to release, so take this into consideration when using or customizing any of these scripts.

To add documents to a view

This script adds documents to the default view All Document $all.

changeto [mailserver]!!mail\mail[#].nsf mail8.ntf -keepopen
add [NumMailNotesPerUser]
drop

To add documents to the Inbox folder

This script adds documents to the Inbox folder using the format -f foldername.

changeto [mailserver]!!mail\mail[#].nsf mail9.ntf -keepopen
add [NumMailNotesPerUser] -f $Inbox
drop

To add one document to the Inbox view

This script adds a single document to the Inbox view. In this example, the document Subject (length of summary item) is set to 30 bytes and the Body (length of non-summary item) is set to 10000 bytes.

changeto [mailserver]!!mail\mail[#].nsf mail9.ntf -keepopen
add 1 30 10000 -f $Inbox
drop

To create a local database

This script creates a local database -- in this example, a Journal database. The NOTES.INI file contains the setting TemplateVersion=9. Text enclosed in asterisks (**) indicates comments.

Changeto journal.nsf journal[templateversion].ntf -KeepOpen
pause 5000

**Populate the view with 10 documents**

populate 10
pause 5000

**Open the view collection**

open

**Update the view index**

index
pause 5000

**Close the view collection**

close

To create multiple databases on a server

This script creates multiple databases on a specified server. In this example, a Journal database is created; the actual thread number is substituted for the "#" symbol; and the NOTES.INI file contains the setting TemplateVersion=9. Text enclosed in asterisks (**) indicates comments.

**Creation of multiple databases, based on the number of threads; all test databases will be placed in the journal directory**

Changeto [MailServer]!!journals\journal[#].nsf journal[templateversion].ntf -KeepOpen
pause 5000

To update a view collection

This script updates a view collection. In this example, Journal databases are created; the actual thread number is substituted for the "#" symbol; and the NOTES.INI file contains the setting TemplateVersion=9. Text enclosed in asterisks (**) indicates comments.

Changeto [MailServer]!!journals\journal[#].nsf journal[templateversion].ntf -KeepOpen
pause 5000

**Populate the $All view with 10 documents**

populate 10 $All
pause 5000
open $All

**Update the view index**

index
pause 5000

**Close the view collection**

close

To create and initialize mail files

This script creates and initializes one or more mail files The variable NumMailNotesPerUser is used to determine the number of documents in each mail file.

changeto [MailServer]!!mail\mail[#].nsf mail9.ntf
populate [NumMailNotesPerUser] $Inbox
open
close
drop

To issue remote console commands

This example uses the Console command to issue the Show Stat command remotely. You can substitute any server command for Show Stat.

Console [MailServer] sh stat