Moka5
Moka5


Backing Up and Restoring Your Moka5 Management Server   « Go Back
The following procedures document the proper way to backup and restore a Moka5 server. We recommend that you back up your server before upgrades, when migrating from one server to another, and to facilitate disaster recovery.

Applies To

Moka5 Management Server 4.0 and later


Best Practices

When you perform a backup, complete the procedures below in full. Maintaining consistent backups is very important to restoring a fully functional deployment. If you try to restore a deployment from backups that were made at different times, you may lose data.

A full server backup requires more storage space than backing up individual components. Make sure you have enough storage to complete a full backup before you begin.

Perform backups as often as you feel appropriate, given the needs of your deployment, risks specific to your use case, the likelihood that you will need to perform a restoration, and, in the case of Derby databases, commitments to uptime.


Backing up Your Moka5 Management Server


Backing up the SQL Server Database

There are multiple ways to produce database backups. We recommend performing a full backup to restore complete deployment functionality.

There are more advanced techniques to perform SQL server backups, such as scheduling them through SQL Server Agent, or, if you have a manual backup already, log shipping. The procedure below outlines one backup option.


Backing Up Your Database with SQL Server Management Studio

You can use SQL Server Management Studio to perform a “full” Moka5 database backup.
  1. Right-click on the database you wish to back up.
  2. ClickTasks > Back up...

This backup should be performed on a regular basis. The contents should be stored in a separate location than the SQL server.



There is also some configuration data that is stored on the Moka5 Servers themselves. If you have multiple Management Servers behind a load balancer, you should perform this backup for each of your Management Servers.

Backing Up the Entire “conf” Folder

Back up of the entire “conf” folder. This folder is in the Moka5 Program Folders directory.

This folder changes whenever a configuration change is made on the server via iconfig, and sometimes during upgrades.

In order to fully restore a Moka5 deployment after data loss, back up your entire “conf” folder regularly.

If you lose your backup, most of the files inside “conf” can be reconfigured via iconfig. There are, however, two files in the “conf” directory that are necessary to restore a damaged deployment:
  • sslcerts.ks – This file contains the SSL certificate and private key of the server. It is critical to keep a safe backup of this file. If this file is lost, it cannot be restored. If the Player policy is set to validate SSL certificates, then you will not be able to restore communication to the server with previously installed clients.
  • xmfs/access-keys.properties – This file contains a list of keys/secrets for creating secure URLs to the Image Store. If this file is lost, you will need to re-install the Image Store, copy the newly generated access keys, and reconfigure all of your image stores via the Management Console.
These files are absolutely necessary in order to restore a fully functional Moka5 deployment.


Backing Up Image Store Files

If this server is an Image Store Server or an All-In-One Management Server, then you should also keep a backup of the “m5fs” folder. This folder contains all LivePC versions, as well as Moka5 Client Packs and host scripts.


Backing Up Other Components

Backing Up Derby Databases

Derby databases are supported in Moka5 4.0 and below for trial or small deployments.
To back up a Derby database:
1. Stop the production server.
2. Copy the “derby” directory to your backup location.
3. Restart the production server.

Backing Up OpenDS

To back up OpenDS, copy the “opends” directory to your backup location.


Restoring from Backups

In the event of a data loss, follow the procedure below completely to restore your deployment.


Step 1: Restore SQL Server

Restore the SQL Server backup. Assuming you have already reinstalled a copy of SQL Server, perform the restore with SQL Server Management Studio.
  1. Right click on “Databases.”
  2. Choose “Tasks > Restore > Database.”
  3. Select your backup file as the source media.


Step 2: Install Moka5 Server

Reinstall the Moka5 server using the same version you had previously installed.


Step 3: Restore backup files

Stop the M5ES service and copy back the files from your backup.
  1. Remove the files that the installer generated.
  2. Copy your backed up files into place.
  3. Restart the M5ES service.
At this point you should have successfully restored your Moka5 Server from backup. It should function identically to your previous Server. If there were some files lost in the process, then you may need to reconfigure your servers in order to restore original functionality.


Step 4: Perform functionality testing

Confirm that your server has been successfully restored by performing basic functionality tests. These include downloading and installing a Moka5 Player, and subscribing to a LivePC version.

Tests like these can provide quick confirmation that a deployment has been successfully restored, or indicate that further recovery work is needed.