Installing and Configuring the JAMS Failover
Installing JAMS
- Install the JAMS Primary Scheduler.
- The Local Agent Name defaults to the name of the Primary Scheduler. Update the name of the Secondary Scheduler to localhost.
- For redundancy of the JAMS Database, you can configure AlwaysOn Availability after you complete these steps.
- Stop the JAMS Scheduler service on the JAMS Scheduler Server.
-
If the primary and secondary JAMS Schedulers are to share a database, add a user to the JAMS database to allow the secondary JAMS Scheduler to connect. This can be done by running the SQL statements below on the JAMS database. Replace the login name with the machine name.
Copyexec sp_grantlogin @loginame='YourDomain\YourMachineName$'
exec sp_grantdbaccess @loginame='YourDomain\YourMachineName$', @name_in_db='JAMSMachine2'
exec sp_addrolemember @rolename='JAMSApp', @membername='JAMSMachine2' -
Install the JAMS Scheduler on the secondary server.
- When prompted for the database server, enter the same SQL Server, Instance, and Database Name as the primary JAMS Scheduler server.
- Click Next. On the dialog stating "Database already exists", select Use Database.
-
Stop the JAMS Scheduler service on the secondary server.
-
Create and edit a Failover.config file in the C:\Program Files\MVPSI\JAMS\Scheduler\directory on the primary and secondary servers. A sample Failover file is shown below.
A Sample Failover config
<FailoverConfig>
<Primary>Server1</Primary>
<Secondary>Server2</Secondary>
<Port>4773</Port>
<Interval>60</Interval>
</FailoverConfig>
- The primary and secondary server names are the hostnames of the respective machines.
- The port is the port used by the primary and secondary scheduler to communicate the heartbeat connection.
- The interval value is the length of time that must elapse before a heartbeat is missed. If 3 heartbeats are missed, then the failover process will start.
- The interval value can be modified to suit the users needs. It is recommended to not have this value lower than 15 seconds to ensure that the schedulers are not constantly trying to take control of the database during intermittent network issues.
Working with the Root Certificate Authority
For JAMS 7.7.3 and later, a root certificate authority is included with the JAMS installer. The steps below need to be completed on versions 7.7.3 and later.
Primary JAMS Scheduler
- On the primary JAMS Scheduler, go to \Program Files\MVPSI\JAMS\Scheduler.
- Right-click JAMSRegister.exe and select Run as administrator. A command prompt window opens.
- Run the command shown below to export the certificate. You need to copy this to the Secondary JAMS Scheduler.
Export root ca /filename="C:\root.pfx" /prompt
- Enter a password to store the private key, which is referred to as the root key password and will be used in another step.
- Enter the password again when prompted to verify it.
- Run the command shown below:
Add Exec Listener /NEWCERT /EXECNAME=<Enter the shared name for the primary and secondary JAMS Scheduler> /ADDRESS=<Enter the network address or name for the primary server>
NOTE: The /ADDRESS is only needed if the machine name alone cannot specify the servers on the network. For example, you may need to enter the address if the servers are not within a company network. - Close the JAMSRegister application.
- Copy the root.pfx file that you exported to the secondary JAMS Scheduler.
Secondary JAMS Scheduler
- On the secondary JAMS Scheduler, go to \Program Files\MVPSI\JAMS\Scheduler.
- Right-click JAMSRegister.exe and select Run as administrator. A command prompt window opens.
- Run the command shown below to import the certificate. Ensure you update the /filename command to specify the location where the file is saved.
Import root ca /filename=root.pfx /prompt /makedefault /storekey
- Enter the root key password.
- Run the command shown below:
Add Scheduler Listener /NEWCERT
Restarting the Services and Granting Permissions
- Start the JAMS Scheduler on both the primary and secondary servers.
- Grant permissions to the MSMQ Service from the secondary JAMS Scheduler as described in How to Grant Permissions to the MSMQ Service from a Secondary JAMS Scheduler.
Common Log Output Location
To have a common log output location on network share for both Primary and Secondary schedulers, see Setting a common log output location for JAMS in a Failover Environment for more information.