Skip to content

Instance duplication

Information

This documentation describes how to duplicate a first instance of Edge Gateway Windows.
It can be followed for new instances by replacing the suffix -2 with -3 or any other unused values.

Prerequisites

To perform the following operations, administrator rights for the machine are required.

Duplicating instances allows each instance to connect to another Mediation Controller.
On the same Windows server, it is therefore possible to connect to several cyberelements.io tenants and/or several cyberelements Cleanroom platforms.

The first step is to duplicate the <INSTALLDIR>\IPdiva\IPdivaGateway\ directory.

Example

With an installation in the default directory, you will need to copy the directory IPdivaGateway for IPdivaGateway-2:

C:\Program Files (x86)\Systancia\IPdiva\IPdivaGateway\
C:\Program Files (x86)\Systancia\IPdiva\IPdivaGateway-2\

Then you need to rename the IPdivaGateway.exe executable with the same suffix as the one used for the directory copy above.

Example

The executable IPdivaGateway.exe becomes IPdivaGateway-2.exe:

C:\Program Files (x86)\Systancia\IPdiva\IPdivaGateway-2\bin\IPdivaGateway.exe
C:\Program Files (x86)\Systancia\IPdiva\IPdivaGateway-2\bin\IPdivaGateway-2.exe

Modify the file <INSTALLDIR>\IPdiva\IPdivaGateway<SUFFIX>\conf\gateway.xml (changes to lines 17 and 19 and addition to line 22):

16
17
18
19
20
21
22
23
<ssl>
    <cert>C:\Program Files (x86)\Systancia\IPdiva\IPdivaGateway<SUFFIX>\conf\ssl\my-edge-gateway-windows.p12</cert>
    <password>MyP@ss0rd</password>
    <ca-dir>C:\Program Files (x86)\Systancia\IPdiva\IPdivaGateway<SUFFIX>\conf</ca-dir>
    <cipherlist>!ADH:!AECDH:!MD5:kEECDH+AES:kEDH+AES:AES256+RSA:3DES+RSA</cipherlist>
</ssl>
<rpclisten>127.0.0.1:<RPC_PORT></rpclisten>
<proxy>

Replace:

  • <SUFFIX> by the suffix used when copying the IPdivaGateway directory
  • <RPC_PORT> by a TCP port number available on the machine, it is common for the first instance of Edge Gateway to use port 9080 and to increment it for subsequent instances

Example

Continuing with the example where the chosen suffix is -2 and this is the second instance of Edge Gateway, the TCP port selected is 9081, the C:\Program Files (x86)\Systancia\IPdiva\IPdivaGateway-2\conf\gateway.xml file would be modified as follows:

16
17
18
19
20
21
22
23
<ssl>
    <cert>C:\Program Files (x86)\Systancia\IPdiva\IPdivaGateway-2\conf\ssl\my-edge-gateway-windows.p12</cert>
    <password>MyP@ss0rd</password>
    <ca-dir>C:\Program Files (x86)\Systancia\IPdiva\IPdivaGateway-2\conf</ca-dir>
    <cipherlist>!ADH:!AECDH:!MD5:kEECDH+AES:kEDH+AES:AES256+RSA:3DES+RSA</cipherlist>
</ssl>
<rpclisten>127.0.0.1:9081</rpclisten>
<proxy>
Complete file
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<gateway>
    <server>my-tenant.cyberelements.io:443:ssl</server>
    <ticket>
        <hmac/>
    </ticket>
    <pipe>
        <ping-timeout>60000</ping-timeout>
        <push-timeout>20000</push-timeout>
        <pop-timeout>20000</pop-timeout>
        <fifo-sent-len>200000</fifo-sent-len>
        <rout-max-lock>20000</rout-max-lock>
    </pipe>
    <timeout>
        <reconnect>15000</reconnect>
    </timeout>
    <ssl>
        <cert>C:\Program Files (x86)\Systancia\IPdiva\IPdivaGateway-2\conf\ssl\my-edge-gateway-windows.p12</cert>
        <password>MyP@ss0rd</password>
        <ca-dir>C:\Program Files (x86)\Systancia\IPdiva\IPdivaGateway-2\conf</ca-dir>
        <cipherlist>!ADH:!AECDH:!MD5:kEECDH+AES:kEDH+AES:AES256+RSA:3DES+RSA</cipherlist>
    </ssl>
    <rpclisten>127.0.0.1:9081</rpclisten>
    <proxy>
        <type/>
        <address/>
        <login/>
        <password/>
        <domain/>
    </proxy>
    <webaccess>
        <useragent>true</useragent>
        <autoauth>true</autoauth>
        <forceauth>false</forceauth>
    </webaccess>
</gateway>

Then modify the <INSTALLDIR>\IPdiva\IPdivaGateway-2\conf\gwmonitor.xml file (modify line 3 and add line 9):

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
<gwmonitor>
 <upgrade-server>http://127.0.0.1:6060/IPdivaGateway.exe</upgrade-server>
 <gwxmlrpc>127.0.0.1:<RPC_PORT></gwxmlrpc>
 <mode>udp</mode>
 <restart>true</restart>
 <upgrade>true</upgrade>
 <restart-range>4:0-5:0</restart-range>
 <upgrade-range>1:0-2:0</upgrade-range>
 <suffix><SUFFIX></suffix>
</gwmonitor>

Replace:

  • <RPC_PORT> by the previously selected TCP port
  • <SUFFIX> by the suffix used when copying the IPdivaGateway directory

Example

With the RPC port 9081 and suffix -2, the C:\Program Files (x86)\Systancia\IPdiva\IPdivaGateway-2\conf\gwmonitor.xml file would be modified as follows:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
<gwmonitor>
    <upgrade-server>http://127.0.0.1:6060/IPdivaGateway.exe</upgrade-server>
    <gwxmlrpc>127.0.0.1:9081</gwxmlrpc>
    <mode>udp</mode>
    <restart>true</restart>
    <upgrade>true</upgrade>
    <restart-range>4:0-5:0</restart-range>
    <upgrade-range>1:0-2:0</upgrade-range>
    <suffix>-2</suffix>
</gwmonitor>

Using a cmd command prompt as an administrator, we will create a Windows service to automatically start the new instance of Edge Gateway Windows:

1
sc create "IPdiva Gateway<SUFFIX>" binPath= "\"<INSTALLDIR>\IPdiva\IPdivaGateway<SUFFIX>\IPdivaGateway<SUFFIX>.exe\"" type= own start= auto

Replace:

  • <INSTALLDIR> by the directory in which the Windows Edge Gateway was installed
  • <SUFFIX> by the suffix used when copying the IPdivaGateway directory

Example

With installation in the default directory and suffix -2, the command to create the service is as follows:

1
sc create "IPdiva Gateway-2" binPath= "\"C:\Program Files (x86)\Systancia\IPdiva\IPdivaGateway-2\IPdivaGateway-2.exe\"" type= own start= auto

Finally, all that remains is to manually configure the new instance so that it can connect: Manually configure the Edge Gateway instance