You can perform a manual migration precheck directly from the command line on your
NiFi nodes even if NiFi is managed by Cloudera Manager. This method
provides administrators with more control and is useful in scenarios that require or prefer
a manual process. Follow the below steps to perform a precheck directly from the command
line.
-
Switch the user to NiFi using
su nifi
.
-
Find the location of these files.
- pre_upgrade_check.py
- CFM4-Deprecated-components.csv
- NiFi-1.x-components-with-legacy-Kerberos-properties.csv
-
Identify the
${NIFI_WORKING_DIRECTORY}
environment variable,
which can be found in stdout.log during NiFi startup.
-
Use Python3 to run the script with the following command, replacing the
placeholders with the actual paths.
python3 [***/path/to***]/pre_upgrade_check.py \
"${NIFI_WORKING_DIRECTORY}/flow.json.gz" \
"[***/path/to***]/CFM4-Deprecated-components.csv" \
"[***/path/to***]/NiFi-1.x-components-with-legacy-Kerberos-properties.csv" \
"[***NIFI_WORKING_DIRECTORY***]/config_backup/bootstrap.conf" \
"${CUSTOM_JAVA_HOME}"
-
If necessary, specify the
${CUSTOM_JAVA_HOME}
argument.
This should be set if the JAVA_HOME
environment variable for
the "nifi" user is different from the JAVA_HOME
you are using
to run the NiFi service.
-
Once all file paths are updated in the command, run it to start the pre-upgrade
check.