Before you begin, you can perform some tasks to ensure the efficiency and success of your upgrade process.
- Optimizing your NiFi Directory Structure for Upgrade
- Preserving your custom processors
- Preserving customized NAR files
Optimizing your NiFi Directory Structure for Upgrade
When you install NiFi and perform the minimum configuration requirements by editing the
nifi.properties file, your installation directory contains several files and directories. Assuming you have installed into an opt/ directory, the NiFi installation directory structure is similar to:
/ --> opt/ --> nifi-current_version |--> LICENSE |--> NOTICE |--> README |--> bin/ |--> conf/ |--> docs/ |--> lib/ |--> work/ |--> content_repository/ |--> flowfile_repository/ |--> logs/ |--> provenance_repository/
To optimize the NiFi directory structure for upgrade:
Move the following directories out of the NiFi installation directory:
All content repositories
NiFi log repository
All provenance repositories
See the System Administrator's Guide for information on options for creating these repositories to optimize performance and stability.
Move static items that do not change from version to version out of the conf directory. These items include:
The templates directory
Note: NiFi 1.0.0 no longer contains
authorized-users.xml. Instead, it contains
users.xml. During upgrade, preserve
authorized-users.xml so that NiFi 1.0.0 can use it to populate the values of the
A good directory structure that supports easy upgrading looks similar to:
/ |--> opt/ | |--> nifi-current_version | | |--> LICENSE | | |--> NOTICE | | |--> README | | |--> bin/ | | |--> conf/ | | |--> docs/ | | |--> lib/ | | |--> work/ | | | |--> Configuration_resources/ | | |--> authorized-users.xml | | |--> flow.xml.gz | | |--> templates/ | | |--> custom_lib/ | |--> database_repository/ |--> content_repository_1/ |--> content_repository_N |--> flowfile_repository/ |--> NiFi-logs/ |--> provenance_repository_1/ |--> provenance_repository_N/
Important: Upgrading from NiFi 0.x to 1.x converts your database, content, flowfile, log, and provenance repositories automatically. Once upgraded, you can not revert the repositories back to 0.x format.
If you have written any custom NARs, first test and validate them in a separate new NiFi release sandbox prior to upgrading. The verified NARs can be preserved during the upgrade by storing them in a centralized location as follows:
Create a second library directory, called
Move your custom NARs to this new lib directory.
Add a new line to the
nifi.propertiesfile to specify this new lib directory:
If you have modified any of the default NAR files, an upgrade will overwrite these changes. To preserve the customization:
Identify and save the changes you have made to the default NAR files in your existing instance.
Perform your upgrade to NiFi 1.0.0.
Redo the changes you have made to the NAR files in your NiFi 1.0.0 instance.