Difference between revisions of "Upgrading from Version 10 to Version 11"

From FMR Knowledge Base
Jump to navigation Jump to search
(Migrating Registry Tables from 10 to 11)
(Overview)
 
(49 intermediate revisions by 3 users not shown)
Line 1: Line 1:
 +
[[Category:How_To]]
 +
[[Category:How_To V11]]
 
== Overview ==
 
== Overview ==
  
The structure of the operating database has changed in Fusion Metadata Registry (FMR) version 11 making it incompatible with version 10. An existing FMR 10 installation '''cannot''' be directly upgraded to version 11, and a version 11 database cannot be used with version 10 of FMR.
+
The structure of the operating database changed in Fusion Metadata Registry (FMR) version 11 making it incompatible with version 10. An existing FMR 10 installation '''cannot''' be directly upgraded to version 11, and a version 11 database cannot be used with version 10 of FMR.
  
 
If you attempt to start an FMR instance using a version 10 database it will fail to start.  We recommend using an empty database and loading structures into it.  To upgrade from 10 to 11 please follow the steps below.
 
If you attempt to start an FMR instance using a version 10 database it will fail to start.  We recommend using an empty database and loading structures into it.  To upgrade from 10 to 11 please follow the steps below.
  
If you wish to preserve structures and settings from a version 10 database please see the section below titled: XXXX
+
If you wish to preserve structures and settings from a version 10 database please see the article titled: [https://fmrwiki.sdmxcloud.org/Migrating_Structural_Metadata_History_and_Settings Migrating Structural Metadata History and Settings]
  
 +
Other options are available as described in the next paragraph.
  
== Backing Up an Existing Fusion Metadata Registry ==
+
== Migrating structures and settings from FMR 10 to FMR 11 ==
  
 +
=== Option 1 - Using the Backup and Restore Command line tool V11.3 and later ===
 +
Full instructions can be found [https://fmrwiki.sdmxcloud.org/Backup_and_Restore in this article] however please note that the '''Restore''' option is only available in Version 11.3 (and higher) of FMR. If this is not the case, use Option 2.
 +
 +
===Option 2 - Using the Export Structures tool===
 
To create a file containing all of the structural metadata within your Registry, please perform the following:
 
To create a file containing all of the structural metadata within your Registry, please perform the following:
  
Line 18: Line 25:
  
 
You may now stop the Apache Tomcat running this instance of FMR.
 
You may now stop the Apache Tomcat running this instance of FMR.
 +
 +
===Option 3 - Migrating Structural Metadata History and Settings===
 +
This option explains how structures and certain settings can be migrated from FMR 10 to FMR 11 using SQL commands to directly modify FMR’s operating database. To learn more, please read [https://fmrwiki.sdmxcloud.org/Migrating_Structural_Metadata_History_and_Settings this article]
  
 
== Starting the Version 11 Fusion Metadata Registry ==
 
== Starting the Version 11 Fusion Metadata Registry ==
Line 23: Line 33:
 
If you attempt to start FMR against a version 10 database, the Registry will detect this and will halt the startup process. It is highly recommended to use an empty database.
 
If you attempt to start FMR against a version 10 database, the Registry will detect this and will halt the startup process. It is highly recommended to use an empty database.
  
To start FMR version 11
+
===To start FMR version 11, 11.1, 11.2 or 11.3===
  
 
* Deploy the war file into your existing Java WebServer (e.g. Apache Tomcat).
 
* Deploy the war file into your existing Java WebServer (e.g. Apache Tomcat).
Line 34: Line 44:
 
You will now have a running FMR (although with no content) that has an associated database for persistance of your structures and settings
 
You will now have a running FMR (although with no content) that has an associated database for persistance of your structures and settings
  
== Login and Upload Structures ==
+
===To start FMR version 11.4 or higher===
 +
Prior to starting the tomcat you need to ensure that the MySQL jar file is available as discussed in this [https://fmrwiki.sdmxcloud.org/Upgrading_to_Version_11.4 article.]
 +
 
 +
== Login and Upload Structures (Option 1 only) ==
 
You should login to the Fusion Registry and upload the structure file you obtained from FMR version 10.
 
You should login to the Fusion Registry and upload the structure file you obtained from FMR version 10.
  
Line 45: Line 58:
 
In the unlikely event that there are any issues loading the structures, please check the Web Server log files and also the "Server Integrity" page (located in the left-hand menu bar) which reports any structures that break the Registry Integrity.  If you need help, please contact Metadata Technology for further support.
 
In the unlikely event that there are any issues loading the structures, please check the Web Server log files and also the "Server Integrity" page (located in the left-hand menu bar) which reports any structures that break the Registry Integrity.  If you need help, please contact Metadata Technology for further support.
  
== Migrating Structural Metadata History and Settings ==
+
'''Note''': if you have used the Restore tool (Option 1) or have migrated your structures and settings manually (Option 2) this step is not necessary.
 
 
When migrating from Registry 10 to Registry 11 it is easier to start afresh. However if you wish it is possible to preserve the following:
 
* All metadata structures
 
* The history for individual structures
 
* Many of the settings from FR10
 
* Some of the audits from FR10
 
 
 
The instructions are detailed below. Within these instructions shall refer to the database that is used for Fusion Registry 10 as '''FR_10_DB''' and the database used for Fusion Registry 11 as '''FR_11_DB'''. Of course your database names will be different. FR_11_DB should be an empty database.
 
 
 
For information about the purpose of each Registry table, please refer to [[Explanation_of_Registry_Tables|this page ]]
 
 
 
 
 
=== Instructions ===
 
 
 
# Using the database tool of your choice (for example SQLYog) navigate to the FR_10_DB.
 
# Create a SQL Dump of the table Structure and Data for the following tables:
 
** registry_audit
 
** registry_maintainable_sdmx
 
** registry_maintainables
 
** registry_settings
 
** registry_settings_dv
 
** registry_settings_ser
 
** sdmx_backup
 
** sdmx_transaction
 
** sdmx_transaction_item
 
** tx_backup
 
 
 
In SqlYog the way to do this is to use the menu option: Database -> Backup/Export -> Backup Table(s) as SQL Dump... and in the modal that appears, select only the tables listed above. Ensure the radio button "Structure and Data" is checked.
 
 
 
This may be quite a large file. It depends on the content of your Registry.
 
 
 
#<li value="3"> View the generated file in an editor of your choice. SqlYog lists 3 occurrences of the FR_10_DB. These are:
 
* On line 3: in a comment
 
* On line 15: in a "CREATE DATABASE"
 
* On line 17: in a "USE" statement
 
 
 
Change all of these so that they refer to the database you are going to use for FR_11 then save the file again.
 
 
 
#<li value="4"> Against the database FR_11_DB. Load in the file. Using SqlYog use the menu option: Database -> Import -> Execute SQL script.  In the modal that appears select the file and click "Execute"
 
#<li value="5"> If it errors, please let me know
 
#<li value="6"> Once the import finishes your FR_11_DB will contain the 10 tables listed above.
 
 
 
Run the following MySql script in a window. '''NOTE:''' change the first line to the actual name of your FR_11_DB:
 
<pre>
 
USE `FR_11_DB`;
 
 
 
DELETE FROM registry_settings WHERE NAME = 'installed.version';
 
DELETE FROM registry_settings WHERE NAME = 'registry.url';
 
DELETE FROM registry_settings WHERE NAME LIKE 'EXCEL_TEMPLATE_PWD_%';
 
COMMIT;
 
</pre>
 
 
 
Then
 
 
 
ALTER TABLE sdmx_transaction_item MODIFY COLUMN id VARCHAR(255) NOT NULL;
 
COMMIT;
 
</pre>
 
 
 
#<li value="7"> Start the Tomcat that will be running FR11. This should direct to step 1 of the Install Wizard.
 
# On step 1 specify the details for database FR_11_DB.
 
# The Registry should now show install page 2. If it doesn't something has gone wrong.
 
# On install wizard step 2 enter the password for the root user. Complete the install wizard.
 
# The front page of the Regsitry should be shown. Remember that security prevents viewing of unauthorized structures. Either use Fusion Security Manager to give permission to public or log on.
 
# Check that the structures are present.  Check that individual structures have history
 

Latest revision as of 07:23, 31 August 2023

Overview

The structure of the operating database changed in Fusion Metadata Registry (FMR) version 11 making it incompatible with version 10. An existing FMR 10 installation cannot be directly upgraded to version 11, and a version 11 database cannot be used with version 10 of FMR.

If you attempt to start an FMR instance using a version 10 database it will fail to start. We recommend using an empty database and loading structures into it. To upgrade from 10 to 11 please follow the steps below.

If you wish to preserve structures and settings from a version 10 database please see the article titled: Migrating Structural Metadata History and Settings

Other options are available as described in the next paragraph.

Migrating structures and settings from FMR 10 to FMR 11

Option 1 - Using the Backup and Restore Command line tool V11.3 and later

Full instructions can be found in this article however please note that the Restore option is only available in Version 11.3 (and higher) of FMR. If this is not the case, use Option 2.

Option 2 - Using the Export Structures tool

To create a file containing all of the structural metadata within your Registry, please perform the following:

  • In your current version 10.X FMR, navigate to the Export Structures / Bulk Actions page.
  • Click on the green "Download all structures" button
  • In the modal that appears ensure that the format is specied as Fusion-JSON. You may choose to download as a Zip file so that the generated film is smaller in size.
  • Download the structures and store them safely as these will be used to upload in your Fusion Registry version 11

You may now stop the Apache Tomcat running this instance of FMR.

Option 3 - Migrating Structural Metadata History and Settings

This option explains how structures and certain settings can be migrated from FMR 10 to FMR 11 using SQL commands to directly modify FMR’s operating database. To learn more, please read this article

Starting the Version 11 Fusion Metadata Registry

If you attempt to start FMR against a version 10 database, the Registry will detect this and will halt the startup process. It is highly recommended to use an empty database.

To start FMR version 11, 11.1, 11.2 or 11.3

  • Deploy the war file into your existing Java WebServer (e.g. Apache Tomcat).
  • Start the Java Web Server and wait for the FMR to fully deploy
  • Using your browser navigate to the front page of FMR.
  • Step 1 of the install wizard will be shown. Supply the details of your new database.
  • On Step 2 of the install wizard set the server location and the root account.
  • Finish the install wizard.

You will now have a running FMR (although with no content) that has an associated database for persistance of your structures and settings

To start FMR version 11.4 or higher

Prior to starting the tomcat you need to ensure that the MySQL jar file is available as discussed in this article.

Login and Upload Structures (Option 1 only)

You should login to the Fusion Registry and upload the structure file you obtained from FMR version 10.

  • Login to the FMR
  • Navigate to the front page
  • Using the "Load Structures" control found at the top right of the page, load the structure file
  • Wait - the time taken to load will depend on the size of the structures present in your file.
  • Ensure that the structures have loaded by looking at individual pages or the Export Structures / Bulk Actions page to see an overview.

In the unlikely event that there are any issues loading the structures, please check the Web Server log files and also the "Server Integrity" page (located in the left-hand menu bar) which reports any structures that break the Registry Integrity. If you need help, please contact Metadata Technology for further support.

Note: if you have used the Restore tool (Option 1) or have migrated your structures and settings manually (Option 2) this step is not necessary.