M-Files Backup Policy
M-Files Backup Policy
M-Files Backup Policy
VERSION 1.2
Contents
1. Introduction ......................................................................................................................................................................... 3
Page 2 of 10
CONFIDENTIAL PROPERTY OF M-FILES CORPORATION, DO NOT COPY OR PUBLISH ONLINE WITHOUT AUTHORIZATION
1. Introduction
The purpose of this document is to introduce guidelines and best practices for backing up M-Files Server and the data
controlled by it. As every M-Files deployment is potentially different and the particular backup procedures vary across
customers, the recommendations presented here should be treated as informative rather than normative.
The scope of this document is limited to on-premises deployments of M-Files, as M-Files Cloud Vaults are maintained and
backed up by M-Files Corporation according to separate guidelines. The basic procedures described in this document apply
both in situations where M-Files Server, its SQL database, and object files are deployed to a single server, and in situations
where they are distributed across multiple servers.
The document is targeted to M-Files employees and authorized partners and customers. The steps about configuring backup
jobs are discussed in the Administrator Track of M-Files Academy.
2. Backup Types
In this section, we will cover the main aspects of and items included in both of these backup types. According to the
customer's needs, backup jobs can either be scheduled to run periodically at specific intervals, or performed manually by
system administrators.
Best practices are covered in section 3 and sample backup plans in section 4.
M-Files server-specific data is always stored in the embedded Firebird SQL database regardless of the chosen deployment or
configuration type. It is very important to regularly create master database backups, not only vault backups.
Page 3 of 10
CONFIDENTIAL PROPERTY OF M-FILES CORPORATION, DO NOT COPY OR PUBLISH ONLINE WITHOUT AUTHORIZATION
• Notification settings
• Licenses
• M-Files Web settings
You can restore master database backups with M-Files Admin (see the M-Files user guide). After the backup has been
restored, it is usually a good idea to verify its integrity by reviewing the restored server-level items in M-Files Admin.
It is possible to perform either a full or differential backup on the vault-specific data. M-Files currently supports two
different database technologies for storing vault-specific data:
Full backups include all object files and the vault metadata:
• Objects with their version history, files, and metadata (for instance documents, customers, and so on)
• Value lists, property definitions and classes
• Metadata structure
• Users, user groups and named access control lists
• User permissions and vault roles
• Workflows
• Connections to other systems
• Event log
• Vault applications and scripts
Differential backups contain changes since the last full backup, thus reducing the amount of disk space needed for storing
backups. In order to perform a successful restore operation, the latest full and the latest differential backup (if one exists)
are needed.
In addition to vault backups, it is crucial to also regularly create master database backups.
When using the embedded Firebird SQL database engine, vault metadata is stored in the database and object files are
always stored in the file system (can be a network folder as well).
Page 4 of 10
CONFIDENTIAL PROPERTY OF M-FILES CORPORATION, DO NOT COPY OR PUBLISH ONLINE WITHOUT AUTHORIZATION
Figure 1: With Firebird, metadata is stored in the database and object files are stored in the file system.
M-Files Server locks the files of online vaults, and these files should not be accessed directly. These vaults can be backed up
using Scheduled Jobs in M-Files Admin. The tool creates a single backup file of each document vault. Therefore,
administrators do not need to backup object files from the file system separately.
When using Microsoft SQL Server as the database engine, administrators can choose to store file data either in the database
or in the file system. Accessing and modifying M-Files vault databases directly using Microsoft SQL Server Management
Studio or similar is not recommended.
Notice that the components in Figure 2 can be deployed on a single physical server machine or distributed across multiple
servers. This has no effect on how and in which order the backups are taken.
Page 5 of 10
CONFIDENTIAL PROPERTY OF M-FILES CORPORATION, DO NOT COPY OR PUBLISH ONLINE WITHOUT AUTHORIZATION
Figure 2: With Microsoft SQL, file data can be stored either in the database or in the file system.
When using the first option, where files are stored in the database, only one database per vault needs to be backed up.
When using the second option, where file data is stored in the file system, administrators must back up both the Microsoft
SQL database and the files in the file system separately.
Important: Always back up the SQL database first and then the file system data in order to avoid references to
non-existing object files.
Microsoft SQL Server is backed up using the tools provided by Microsoft (such as SQL Server Management Studio) or any
compatible tools from 3rd parties. With Microsoft SQL Server, administrators can choose to take full backups and differential
backups on the database itself.
File system data can be backed up using any suitable backup system and with any backup method supported by that system
(for example using incremental backups or similar). Choosing these tools and backup methods is out of the scope of this
document.
Whichever tool set is used for creating the backups, the same tool set should be used when testing and restoring them.
Page 6 of 10
CONFIDENTIAL PROPERTY OF M-FILES CORPORATION, DO NOT COPY OR PUBLISH ONLINE WITHOUT AUTHORIZATION
2.3 Items Not Included in Backups
Regardless of the database used, M-Files Server creates certain secondary data for each vault. This data is stored on the hard
drive of the M-Files server machine. M-Files Server re-recreates the secondary data after the vault backup has been
restored. The secondary data includes:
• Index files
• PDF renditions for hit-highlighting and preview
• Thumbnails
Keep in mind that rebuilding, for instance, the search index of a large document vault can take a significant amount of time
(see Backing Up the Index Files further below).
In addition to secondary data, the behavior of the system may have been modified via various Windows registry key values.
These settings can be exported to a text file and backed up separately as these settings are not included in the vault or
master backups. Also, for example, notification message templates, the M-Files Web user interface and other aspects of the
system may have been configured by editing files in the M-Files Server installation folder. These files must be backed up
manually.
In large vaults, where the index recreation could take a significant amount of time, it is recommended to back up the index
as well. If the default M-Files search engine (dtSearch) is used, backing up the index is as simple as taking a file system level
copy of the Indexes subfolder under the data location of the vault on the server (for example C:\Program Files\M-
Files\Server Vaults\<vault name>\Indexes). The index itself stores its state, and your backup of the index does
not need to be as new as the vault backup. The index begins catching up with the vault automatically.
This would result in the indexing to begin catching up until it is completely up to date. If the Indexes subfolder is completely
empty, the indexing process needs to start from scratch and will take a lot longer.
If you are using Micro Focus IDOL as your search engine, contact M-Files for instructions on backing up the index files.
Page 7 of 10
CONFIDENTIAL PROPERTY OF M-FILES CORPORATION, DO NOT COPY OR PUBLISH ONLINE WITHOUT AUTHORIZATION
3. Best Practices for Backups
Taking regular backups of the M-Files system is important. The backup interval depends on the use case and the criticality of
the system. The recommended minimum level is described in this section.
A hardware disaster or logical errors might not be noticed during the same day that they occur. Therefore, it is important to
store enough restore points of the system and always store backup files in a secure off-site location.
To protect the system against a hardware disaster, using redundant hardware, such as RAID (redundant array of
independent disks) is recommended. Please refer your IT hardware provider for guidance on redundant hardware.
Built-in document control features, including version history and soft-deleting eliminate the need of restoring backups in
multiple scenarios. These features do not, however, protect against logical errors caused by administrators or system errors.
Do not back up an active M-Files system with a snapshot of the file system where its data is stored. This can create a
damaged or unusable backup because writes to files, most importantly the database engine files, can be ongoing and thus
incomplete.
If you use full virtual machine (VM) snapshots for backups, make sure that the VM software fully supports creation of
snapshots of an active system. This means that the software can restore the system to exactly the same state, including the
memory and CPU states.
We recommend designing the backup system in such a way that the system can be restored to reflect the situation of any of
the previous 14 days. This can be achieved by taking either full backups only, or a combination of full and differential
backups.
Additionally, we recommend storing monthly, quarterly and annual backup files separately.
Page 8 of 10
CONFIDENTIAL PROPERTY OF M-FILES CORPORATION, DO NOT COPY OR PUBLISH ONLINE WITHOUT AUTHORIZATION
4.1 Full Backups Only
If possible, it is recommended to always take full backups of both the master database and the vault data, keeping the last
14 backups stored securely in an off-site location:
In larger systems, the "full backups only" method is naturally not feasible, in which case we recommend using a combination
of full and differential backups as follows:
It is recommended to verify that the different master database and vault database jobs are scheduled to run on consecutive
days in a logical order. You can see a list of the scheduled backup jobs in M-Files Admin by selecting Scheduled Jobs under
the server connection node in the left-side tree view. In the example scenario described in section 4.2, you should have the
following backup jobs on the list:
Page 9 of 10
CONFIDENTIAL PROPERTY OF M-FILES CORPORATION, DO NOT COPY OR PUBLISH ONLINE WITHOUT AUTHORIZATION
• M-Files Master Backup 12 • M-Files <vault name> DIFF 1_5
• M-Files Master Backup 13 • M-Files <vault name> DIFF 1_6
• M-Files Master Backup 14 • M-Files <vault name> FB 2
• M-Files <vault name> DIFF 2_1
Vault:
• M-Files <vault name> DIFF 2_2
• M-Files <vault name> FB 1
• M-Files <vault name> DIFF 2_3
• M-Files <vault name> DIFF 1_1
• M-Files <vault name> DIFF 2_4
• M-Files <vault name> DIFF 1_2
• M-Files <vault name> DIFF 2_5
• M-Files <vault name> DIFF 1_3
• M-Files <vault name> DIFF 2_6
• M-Files <vault name> DIFF 1_4
Testing and verifying the integrity of a backup can be done using any computer with M-Files Server installed. This should be
done regularly to ensure the backup jobs are functioning correctly. We recommend testing your backups two to four times a
year, at minimum.
If the embedded Firebird SQL database is used, refer to M-Files user guide for instructions on how to restore backups (see
Backing Up and Restoring the Master Database and Restoring a Document Vault). If Microsoft SQL Server is used, refer to
the documentation of the backup tools you are using for creating the backups.
6. Change History
1.1 2018/05/23 Updated the document template. Added instructions on backing up index files (section 2.4).
Page 10 of 10
CONFIDENTIAL PROPERTY OF M-FILES CORPORATION, DO NOT COPY OR PUBLISH ONLINE WITHOUT AUTHORIZATION