Invoking Intermapper Clone
CloneIM (or CloneIM.sh for Microsoft Windows systems) is a script that synchronizes a local Intermapper installation with (or mirrors a file system directory from) a remote Intermapper server. It creates successive requests to the remote server's embedded web server by either HTTP or HTTPS using a curl command. It is supported on MacOS, Linux, and Microsoft Windows systems that have Cygwin.
If your Microsoft Windows installation of Intermapper does not include Cygwin, you can use the VBScript implementation CloneIM.vbs. In the default invocation, CloneIM copies all accessible resources from the following categories from the Intermapper server on the specified host to the corresponding locations in the local Intermapper server installation: icons, sounds, mibs, probes, tools, webpages, fonts, extensions, maps, and translations. Alternatively, the -D (or /d for Microsoft Windows systems) option allows you to specify an alternate location in the local file system to which the resources are copied instead. You can limit the categories of resources transferred by specifying one or more categories as positional parameters. Note that downloading of chart data is not supported. The Preferences database is always downloaded.
Linux, MacOS, and Cygwin on Microsoft Windows
For Linux and MacOS systems, the script is called CloneIM. This script is used to synchronize local and remote Intermapper servers using the following command:
CloneIM options categories
For example,
CloneIM [-[bs]] [-S] [-q] [-C] [-v] [-h] [-r remote-host] \
[-P protocol] [-t port] [-u user [-p password]] \
[-D target-dir] [-L log-file] \
For Cygwin on Microsoft Windows systems, the script is called CloneIM.sh. This script is used to synchronize local and remote Intermapper servers using the following command:
sh CloneIM.sh options categories
For example,
sh CloneIM.sh [-[bs]] [-S] [-q] [-C] [-v] [-h] [-r remote-host] \
[-P protocol] [-t port] [-u user [-p password]] \
[-D target-dir] [-L log-file] \
Options
| Argument | Description |
|---|---|
| -b | bounces the local Intermapper server across synchronization (if appropriate) |
| -s | the synonym for -b |
|
-S |
Runs in secure mode. Normally, CloneIM uses the HTTP protocol to connect to the remote server. If the -P (protocol) option is used to specify HTTPS but the -S option is not used, CloneIM connects to the server using HTTPS and the port specified by the -t option (or it defaults to port 443), it does not check the client SSL certificate. If -S is specified, CloneIM uses the HTTPS protocol and the specified port (or it defaults to port 443) and checks the client SSL certificate. On each platform where you are using the shell script implementation of CloneIM, make sure that the SSL certificate for the target Intermapper server is accessible to your local implementation of the curl command. On Cygwin, the relevant implementation of curl can be Microsoft Windows or the Cygwin, depending on your Cygwin installation. You can verify that you have the correct certificate using a browser (such as Mozilla Firefox or Chrome) hosted by your intended host for CloneIM to access the URL (https://Intermapper server IP:port/~files. If you can access the URL through your browser without adding a security exception, and your browser and curl are referencing the same certificate storage, you can use CloneIM with the -S option. SSL certificates are sometimes bound to a domain, server name, or hostname. They are installed on a server to tie an organization's identity to its location. For this reason, they are only granted for a Fully Qualified Domain Name (FQDN). This means that you might need to specify the target Intermapper server hostname as an FQDN when supplying it as the argument for the -r option when using the -S option. |
|
-q |
operates quietly |
|
-C |
assumes compatibility |
|
-v |
prints the version number |
|
-h |
prints the Help message |
|
-P |
specifies the protocol (httpby default or https which is implied by -S) |
|
-r |
specifies the remote host with which to synchronize |
|
-t |
specifies the remote Intermapper server's web service listener port (defaulted from protocol) |
|
-u |
specifies the user that invokes the web service. The default is admin. |
|
-p |
specifies the user's password for the destination Intermapper server. The default is password. |
|
-L |
specifies the log file to which to append execution details. Use - for none. |
|
-D |
specifies the local destination directory. The default is the local Intermapper installation. |
Categories
- icons
- sounds
- mibs
- probes
- tools
- webpages
- fonts
- extensions
- maps
- translations
Files
Linux Systems
/var/local/InterMapper_Settings/Scripts/CloneIM
MacOS Systems
/Library/Application Support/InterMapper_Settings/Scripts/CloneIM
Microsoft Windows
For Microsoft Windows systems, the script is called CloneIM.vbs. This script is used to synchronize local and remote Intermapper servers using the following command:
cscript CloneIM.vbs options categories
Options
For the following options, you can alternatively use the words listed after the single-letter options. For example, for /r, you can also use /host, or /remote-host.
| Argument | Description |
|---|---|
|
/r host,remote-host |
Specifies the Intermapper server host from which to make the download requests. Because the default remote host name is intermapper1, this option is typically mandatory. Unless the /d option is supplied, this is an error that specifies the local host as the argument to this option. |
|
/p protocol |
Specifies the protocol used for making resource requests to the remote server. protocol must be http or https. The default is http. |
|
/t port |
Specifies the port number used for resource requests to the remote server. The default is 80 for http and 443 for https. |
| /s |
Runs the curl command in secure mode. Normally, CloneIM.vbs uses the HTTP protocol to connect to the remote server. If /p (protocol) is specified with /p:https but -s is not used, CloneIM.vbs uses https:443 to connect to the remote server and ignores checking the client SSL certificate. If /s is used, CloneIM.vbs uses https:port to connect to the remote server and checks the client SSL certificate. On Microsoft Windows, you should import the SSL certificate that the Intermapper server is using to a local browser, such as Mozilla Firefox or Chrome. If you can verify that https://IM Server IP/port/~files (the port is usually 443) works on your browser without SSL certificate error (where is does not use an exception), then you should be able use CloneIM.vbs with the /s option. SSL certificates are sometime bound together to a domain and server name or hostname. They are installed on a server to associate an organization’s identity to its location. For this reason, they are only granted to a Fully Qualified Domain Name (FQDN) because the server address specified with the /r option might need to be the FQDN of the server. |
|
/u user |
Specifies the Intermapper user account that is making the requests to the remote server. The account must be an Intermapper administrator within the remote Intermapper server. In the CloneIM script, as distributed, the default user account is admin. |
|
/pw password |
Specifies the password for the Intermapper user account that is making the requests to the remote server. You cannot specify a password without specifying a user. In the CloneIM script, as distributed, the default is password. |
|
/d target-dir |
By default, CloneIM.vbs downloads the requested resources into the Intermapper Settings directory of the local Intermapper installation. You can use this option to specify an alternative directory as the root directory of a sub-tree of the file system into which the resources are downloaded. The directory is created if it does not already exist. Otherwise, if CloneIM is ran with the root privilege, the directory must be empty to avoid errors. |
|
/b |
If CloneIM.vbs is required to overwrite the installation directory of the local Intermapper installation, it checks if the local Intermapper server is running. By default, it terminates with an error message if the local server is active. By supplying this option, you can request that it attempts to deactivate the local Intermapper server before the first download request and attempt to reactivate it before a successful termination (after completing the last download request). |
|
/L log |
CloneIM normally writes time-stamped records to a log file. By default, the log file is CloneIM.log in the current directory. This option allows the specification of an alternative log file. You can suppress logging using the /L:- or /L- options. |
| /q |
Operates the command quietly. By default, CloneIM.vbs displays a message verifying each download request. This option suppresses these messages. |
|
/v |
Instructs CloneIM.vbs to display a message including the Intermapper version number. |
|
/h |
Instructs CloneIM.vbs to display a help message and then terminate. |
Categories
- icons
- sounds
- mibs
- probes
- tools
- webpages
- fonts
- extensions
- maps
- translations
File
C:/ProgramData/InterMapper/InterMapper Settings/Scripts/CloneIM.vbs
- The CloneIM.vbs script can only be run by the intermapper and administrator users because the text might contain a hard-coded default password. If you want to enforce a policy prohibiting this, you can relax the execution permission criteria. Contact HelpSystems before attempting such configuration. When CloneIM.vbs is invoked to copy maps from the remote server, it retrieves only enabled maps. Disabled maps in the remote Intermapper installation are ignored. CloneIM.vbs always connects to the Intermapper Server in IPv4 mode. If you use CloneIM.vbs to synchronize Intermapper installations at differing major or minor versions, the version skew is detected and reported. The synchronization attempt is abandoned unless you specify the /d option. If your destination directory is not the local Intermapper installation, execution proceeds, otherwise an interactive execution prompts for confirmation from the standard input.
Copyright Help/Systems LLC and its group of companies. The content in this document is protected by the Copyright Laws of the United States of America and other countries worldwide. The unauthorized use and/or duplication of this material without express and written permission from HelpSystems is strictly prohibited. Excerpts and links may be used, provided that full and clear credit is given to HelpSystems with appropriate and specific direction to the original content. HelpSystems and its trademarks are properties of the HelpSystems group of companies. All other marks are property of their respective owners.