Enterprise Manager: File System > Replication Jobs


Access to this feature requires an active Software Asset Management (SAM) subscription. See Benefits of ‘Software Asset Management' Feature Line.


To view this topic for the preceding Enterprise Manager, see Enterprise Manager Java App - Replication Jobs. For an overview, see Replication Introduction.

In BBj 13.0 and higher, there are two ways to access the replication capabilities: through an API or using the Enterprise Manager. Using the Enterprise Manager gives the administrator an intuitive user interface for creating, editing, removing, and viewing replication jobs.

IMPORTANT: Replication requires exclusive access to the data files; replication jobs cannot be created if "Shared File Access" is set for the BBjServices configuration.

Managing Replication Jobs

To access the replication jobs for a BBjServices installation:

Log in to The Enterprise Manager.

Select the “Replication” item from the navigator area.


Replication Source Jobs

Jobs showing in the Replication Source Jobs section indicate the replication job is running on the connected server. Replication monitors file operations on the monitored files on the source machine, sending any changes to the target machine. See the Replication Target Jobs section below for information about the target jobs.

Job Name - Name of the replication job.

Status - Current status of the job. A normal running job indicates Running. For additional details on the job state, select the job and note the contents of the Status area immediately below the job list.

Replicated Through -  Replication places file operation messages into a queue to be sent to the target for processing. Depending on the speed of the network and the volume of file operations occurring on the system, replication can "fall behind" with its processing of events. Typically, replication may fall behind at a particularly busy time and then get caught up when the system slows, even for just a moment. The Replicated Through setting indicates the timestamp of the last replication event that was successfully processed by the target. Use this indication to determine the performance of your system.

Last TS Ratio - A value of close to 1 indicates replication is processing close to the speed at which operations are occurring on the source. A value less than 1 indicates replication is falling behind. A value greater than 1 indicates that replication is catching up.

Last Op Rate - Operations per second between the last two timestamps. In other words the raw number of operations that happened between the last two timestamps divided by the number of real seconds between them.

Toolbar
Use the toolbar to manage replication jobs on the source machine.

Import - Import a replication job from an export file.

Export - Export the selected replication job configuration to a JSON format file. Use this file as a backup or to import the job configuration on another machine.

Recopy Enabled -  When disabled, the replication job will not attempt to recopy files that appear to be out of sync. Normally, this should be left enabled. However, if a problem occurs with a replication job where it is recopying a file over and over, it is often helpful to disable this temporarily while the admin determines the cause for the recopy events. In some cases, a recopy loop can occur, where a file is recognized as different from its target counterpart and recopied anew, over and over. Most often this is due to either corruption or files being modified on-disk, outside of BBj's control on the source server. Disabling recopy allows the user to stop this recopy cycle without impacting the rest of the replication job, giving them a chance to investigate the difference in the file.

Pause - Pause the replication job. Pausing a job causes replication to cease sending events to the target. However, the source side continues to queue any change events. Resuming the job causes all queued operations to be sent to the target for processing. This feature is helpful when performing a backup of the target files because it ensures the target files are not being changed as long as the job is paused.

Pause When Caught Up - This instructs the replication system to automatically pause the replication job as soon as all operations in the source queue have been sent to the target, as of the moment in time the administrator clicks the Pause When Caught Up button.

Cancel Pause When Caught Up - Cancels the Pause When Caught Up request if one is currently in effect.

Add - Add a new replication job using the replication job creation wizard.

Remove - Remove the selected replication job(s). The administrator will have the ability to optionally remove any target replicated files as well.

Refresh - Refresh the list of and state of all replication jobs currently on the server.

Replication Target Jobs

The Replication Target Jobs section shows a list of replications jobs replicating to the connected server. If a replication job is replicating to itself but simply in a different directory, then the job will show up in the source and target sections. Note that removing, pausing or editing replication jobs must be done by logging into the EM on the job's source machine

Create a Replication Job

From the "Replication Jobs" tab:

Click the [+] "Create New Job" button to launch the "New Replication Job Wizard."

Enter the Replication Job Name.


Select replication job type BBj Directory/File Replication or Database Replication.

Click [Next >]

BBj Directory/File Replication

BBj Directory/File Replication contains a mapping of source files to target files. The target files can reside on the same machine or an entirely different installation of BBj Services. While the job runs, any changes made to any of the source files or directories (including all files in that directory as well as all sub-directories) will be made to the target files and directories. In addition, the target files and directories are read only while the replication job is running.

Complete the fields in the "File System Connection Settings" dialog box.


Click [Next >].

Complete the information, as needed, in the “Other Job Settings” dialog.



Click [Next >].

Select the [Folder] icon or [Files] icon of the directories and/or files to include in the job

 

.

Click [OK].


Click [Finish].

Database Replication

Database Replication makes it quick and easy to replicate an entire database to another location on the same machine, or a machine across the world, with just a few settings. All directories used by the database will be replicated and a new database will be created on the target machine - all automatically. The administrator can add additional directories to the replication job if there are other directories and files not directly referenced by tables or stored procedures. Any changes made to the files in the source database will also occur on the target database including: WRITE, WRITE RECORD, INSERT, UPDATE, DELETE, CREATE/DROP TABLE, etc.

In the “New Replication Job Wizard” window,

Select the Database to replicate.

Specify the desired target database name or accept the default


Complete the fields in the “File System Connection Settings” window.



Click [Next >].

Complete the information, as needed, in the “Other Job Settings” dialog.


Click [Next >].

Click [Next >].



Click [Finish].

Replication Job Properties

Your job is now scheduled and will run as configured. Should you choose to verify or edit the properties of the job, double click the job entry in the Replication Job tab to view the following properties:

Properties view of a Directory/File Replication


Properties view of a Database Replication


Advisory Locking Indicates whether the selected database is using mandatory or advisory locking.
ID A unique identifier automatically generated for the replication job.
Name A name for the job that will be used to identify the job when viewing current jobs.
Source Database Select the database to replicate. When a database is selected, it will automatically populate the list of directories to include in the replication job.
Source/ Destination Mapping Table List of source to target mappings. The source can be a single file or an entire directory. If it is a directory, all files and sub-directories will be replicated as well.
SSL Whether the remote file system server is using SSL or not.
Synchronous When replication should happen synchronously or asynchronously. Synchronous means that write operations on monitored files will wait until the replication is complete. Asynchronous means that the write operation continues regardless of whether the replication operation is complete. Consult “Replication Overview” for additional information.
Target Admin Port Port on which the target Admin Server is running. The default is 2002.
Target Database

The name of the database to be created on the target. If left blank, it will not create a database entry in the Enterprise Manager. However, the files will still be created and replicated on the target in the location specified in the source to target mapping table.

Target Filesystem Port Port on which the target Filesystem Server is running. The default is 2000.
Target Host Optional host name for the target BBjServices. If left blank, the replication will occur to a location on the local computer.
Target Password Password to use when establishing the connection.
Target User User to use to establish the connection.

Edit Replication Jobs

It is also possible to edit currently running replication jobs.

Select the replication job from the list of jobs


Double click the Job Name as it appears in the listing

As needed, change either of these two properties that can be modified on a running replication job:.

Synchronous

Change the synchronous/asynchronous mode if performance needs to be adjusted on the fly.

List/Mapping of Source/Target Files/Directories

Adding or removing of source files and directories is allowed. However, when a mapping or item is removed, the target file may also be removed. Further, if a file or directory is added to a BBj Replication Job and it is currently using synchronous mode, there may be a significant delay after the first write operation as the target becomes synchronized with the source.

Stop a Replication Jobs

Replication jobs continue to run, even between restarts of BBjServices, until they are stopped. Stopping a job gives the administrator the option of also removing the job from the job configuration file.

Select the job from the list of jobs.

Click the [Stop] button.


Remove a Replication Jobs

Select the job from the list of jobs.

Click the red "X".

Select the Database to be removed from the “Confirm Termination and Removing Replication Job(s)” dialog box.

Click the [OK] button.

See Also

Replication Introduction