Difference between revisions of "MailStore Server Management Shell"

[unchecked revision][unchecked revision]
(Created page with '== The MailStore Management Shell == Many instructions available in the graphical user interface of MailStore Client can also be executed using MailStore's management shell, a c...')
 
m (Changed first heading.)
Line 1: Line 1:
== The MailStore Management Shell ==
+
= The MailStore Management Shell =
  
 
Many instructions available in the graphical user interface of MailStore Client can also be executed using MailStore's management shell, a command line client which is automatically included when installing MailStore Server and MailStore Client.
 
Many instructions available in the graphical user interface of MailStore Client can also be executed using MailStore's management shell, a command line client which is automatically included when installing MailStore Server and MailStore Client.
Line 5: Line 5:
 
The management shell is useful when no graphical user interface is available (e.g. if using telnet or ssh) or for the integration of scripts (e.g. batch files) that are executed either manually or automatically.
 
The management shell is useful when no graphical user interface is available (e.g. if using telnet or ssh) or for the integration of scripts (e.g. batch files) that are executed either manually or automatically.
  
=== Option 1: Starting the Management Shell in MailStore Client ===
+
== Option 1: Starting the Management Shell in MailStore Client ==
  
 
The management shell can be started directly from MailStore: Log on to MailStore Client as administrator and click on Management Shell.
 
The management shell can be started directly from MailStore: Log on to MailStore Client as administrator and click on Management Shell.
Line 11: Line 11:
 
[[File:tech_mscmd_01.png|center|450px]]
 
[[File:tech_mscmd_01.png|center|450px]]
  
=== Option 2: Starting the Management Shell with MailStoreCmd.exe ===
+
== Option 2: Starting the Management Shell with MailStoreCmd.exe ==
  
 
The command line client can be started in interactive mode by executing MailStoreCmd.exe without any parameters. After successful login, MailStore is ready to receive commands.
 
The command line client can be started in interactive mode by executing MailStoreCmd.exe without any parameters. After successful login, MailStore is ready to receive commands.
Line 19: Line 19:
 
[[File:tech_mscmd_02.png|center|450px]]
 
[[File:tech_mscmd_02.png|center|450px]]
  
=== Using MailStoreCmd.exe in Non-Interactive Mode ===
+
== Using MailStoreCmd.exe in Non-Interactive Mode ==
  
 
In non-interactive mode, the management shell logs on with the access data passed, executes the command passed, and automatically terminates upon execution. If the login and the execution of the command were successful, the exit code (ERRORLEVEL) of the process is set to 0 (zero), otherwise it is set to any value other than 0.
 
In non-interactive mode, the management shell logs on with the access data passed, executes the command passed, and automatically terminates upon execution. If the login and the execution of the command were successful, the exit code (ERRORLEVEL) of the process is set to 0 (zero), otherwise it is set to any value other than 0.
Line 44: Line 44:
 
The actual command follows (non-interactive mode).
 
The actual command follows (non-interactive mode).
  
=== Command Overview ===
+
== Command Overview ==
  
 
'''clear'''
 
'''clear'''

Revision as of 13:52, 23 June 2010

The MailStore Management Shell

Many instructions available in the graphical user interface of MailStore Client can also be executed using MailStore's management shell, a command line client which is automatically included when installing MailStore Server and MailStore Client.

The management shell is useful when no graphical user interface is available (e.g. if using telnet or ssh) or for the integration of scripts (e.g. batch files) that are executed either manually or automatically.

Option 1: Starting the Management Shell in MailStore Client

The management shell can be started directly from MailStore: Log on to MailStore Client as administrator and click on Management Shell.

Tech mscmd 01.png

Option 2: Starting the Management Shell with MailStoreCmd.exe

The command line client can be started in interactive mode by executing MailStoreCmd.exe without any parameters. After successful login, MailStore is ready to receive commands.

Enter exit to log off and exit the management shell.

Tech mscmd 02.png

Using MailStoreCmd.exe in Non-Interactive Mode

In non-interactive mode, the management shell logs on with the access data passed, executes the command passed, and automatically terminates upon execution. If the login and the execution of the command were successful, the exit code (ERRORLEVEL) of the process is set to 0 (zero), otherwise it is set to any value other than 0.

To use the non-interactive mode, pass the parameters as follows:

MailStoreCmd.exe --h="localhost" --pkv3="23:18:06:3f:24:7d:f3:83" --u="admin" --p="admin" -c Actual Command and Parameter

The following is a description of the parameters:

--h="localhost" The machine name of the MailStore server to which MailStoreCmd.exe is to connect.

--pkv3="..." The (optional) Public Key Fingerprint, which guarantees the identity of MailStore Server.

--u="admin" User name.

--p="admin" Password.

-c The actual command follows (non-interactive mode).

Command Overview

clear Clears the texts currently displayed improving visibility.

help Displays a list of all available commands and their parameters.

debuglog-enable, debuglog-browse, debuglog-disable Activates, displays or deactivates the global debug protocol (within computer scope).

export-list Displays a list of all existing export profiles (ID and profile name).

export-execute [--name=<profilename>] [--id=<profileid>] [--verbose] Executes the export profile with the name or the ID specified (only one of these parameters is required). The parameter --verbose activates a detailed status display on the console.

import-list [--user=<username>] Displays a list of all existing archiving profiles (ID and profile name).

import-execute [--name=<profilename>] [--id=<profileid>] [--verbose] [--user=<username>] Executes the archiving profile with the name or the ID specified (only one of these parameters is required). The parameter --verbose activates a detailed status display on the console.

filegroup-attach --directory=<directory> With this command a file group, which has been removed from MailStore using filegroup-detach, can be reattached to MailStore.

filegroup-detach --gid=<filegroupid> In Administrative Tools under Storage Locations, the status of a file group can be set to inactivate. The file group (along with the emails it contains) is no longer available until it is reactivated but remains in the list of existing file groups. By using the command filegroup-detach, a file group is completely removed from MailStore but physically remains on the hard drive.

process-info Provides information about the MailStore-Windows process.

rpc-info Provides information about the connection with the MailStore Server process.

statistics-refresh Recalculates all statistics.

maintain-db [--gid=<filegroupid>] --command=[backup-restore|sweep]

maintain-ix --gid=<filegroupid> --command=[list|optimize|reload|verify|] [--ixid=<indexid>]

folder-reindex [--folder=<userfolder>] --gid=<filegroupid>

filegroup-verify --gid=<filegroupid> Information about these commands can be found in chapter Maintenance and Repair.