How do I upgrade Metadefender Core while preserving configuration?

Some of Metadefender Core's components are stored in the Windows registry and others in a local configuration file. Therefore, it is important to preserve the configurations of these when upgrading. OPSWAT recommends using the backup and restore functionality in the Metadefender Core Management Console. Export the settings before uninstalling Metadefender Core and then import the settings after the new version of Metadefender Core has been installed. There is also a tool to export and import settings from the command line. To export your current configuration do the following:

  1. Navigate to http://localhost:8008/management/

  2. In the upper-right section of the page click on Backup / Restore

  3. If you want to set a password for the exported configuration file, check Encrypt Backup with the following password and provide a password

  4. Click on DOWNLOAD BACKUP

This backup, unfortunately, will only handle a portion of the needed configurations. Other configurations reside in the Metadefender Core configuration file (by default it's C:\Program Files\OPSWAT\Metadefender Core X\omsConfig.ini). In this file many antivirus engine specific configurations are placed, along with Custom Engine settings, DB controller settings, proxy settings and ICAP settings. NONE of this information is handled by the upgrade and if any information has been added to this file, it will be lost during the upgrade. Make a copy of this file and store it in a safe place before uninstalling for an upgrade. The same goes for any IISExpress web server changes the user might have made in the web.config file located in the Metadefender Core installation directory, Rest\Web folder. In this file, the user could have blocked certain API's or modified the file upload size by the variables maxRequestLength, requestLengthDiskThreshold and maxAllowedContentLength. Such changes are rather unlikely but make a copy of this file as well and place it somewhere safe. Now, the user can safely uninstall Metadefender Core and reinstall the new version, a restart may be required. After installing Metadefender Core do the following:

  1. Navigate to http://localhost:8008/management/

  2. In the upper-right section of the page click on Backup / Restore

  3. Under Restore From Backup click Browse and select the previously exported configuration to import it

  4. If you encrypted the backup file with a password, check Decrypt Backup with the following password and provide the password

  5. Click on UPLOAD & RESTORE

(Optional) To import other non-registry settings please do the following:

  1. Copy over pertinent information to the new “omsConfig.ini” from the old "omsConfig.ini", being the engine-specific configurations such as “heuristic scanning” and “extract archive”, but NOT the “update server”. The reason that “update server” should not be changed is due to newer Metadefender Core releases may contain newer AV engine versions, which cannot use the old definition files.

  2. If ICAP or Proxy is used, port those configurations over as well.

  3. If the DB controller settings were changed by the Administrator, change them as well.

You can also view a short video tutorial on the subject on the OPSWAT YouTube channel.

This article pertains to Metadefender Core v3
This article was last updated on 2016-09-01
AF