Support Questions

Find answers, ask questions, and share your expertise

Uninstall NiFi

avatar
New Contributor

How to uninstall NiFi from Linux 7.9?

 

The process org.apache.nifi.registry.NiFiRegistry is up and running on the server. We need to remove the product completely. I am not sure how it was installed.

We do not use d2iq dcos framework. 

 

1 ACCEPTED SOLUTION

avatar
Master Mentor

@winbob 
- What does the output of "ps -ef|grep -i nifi" return on your server where NiFi-Registry is installed?
- Is this an Apache NiFi-Registry install or a Cloudera managed NiFi-Registry install?  (I see you mentioned you're not sure how it was installed, but uninstalling the service properly differs depending on how it was installed.).

Assuming this is just an Apache NiFi-Registry installation on Linux, the most common installation method is simply to unpack the tar.gz NiFi-registry file in user defined install location (output from "ps -ef" command will help determine where it is installed).  Then the user would configure the nifi-registry.properties file in the conf directory and start the service via "<install/unpack directory>/bin/nifi-registry.sh start" command.

1. So step one is to stop NiFi-Registry: 
           - Check to see if NiFi-Registry was installed as a linux service "systemctl status nifi-registry". If this returns then NiFi-Registry was installed as a service.  If it returns unknown service then it was not.  Assuming this returns you can stop the service using "systemctl stop nifi-registry". Then issue following commands to remove the linux service setup (does not uninstall product so will still need to complete steps 2 forward). 

systemctl disable nifi-registry
rm /etc/systemd/system/nifi-registry
rm /usr/lib/systemd/system/nifi-registry

           - If not a managed linux service, stop NiFi-Registry using "<install/unpack directory>/bin/nifi-registry.sh stop" ("ps -ef | grep -i nifi" should not return any processes for NiFi-Registry after executing this command).

2. Now you must inspect some NiFi-Registry conf directory files to identify any directory location defined by the user who installed the product. (default would have them all located with the directory tree where NiFi-Registry was unpacked, but very often these path are manually changed).  Search the following configuration files for directory paths:
          - nifi-registry.properties
          - authorizers.xml
          - providers.xml
          - logback.xml
NOTE: if any of the directory property paths start with "./" then NiFi-Registry is building the directory path tree within the existing NiFi-Registry installation path tree.

3. Once you have all the path external to the NiFi-Registry installation base path located, you can start deleting these directories and there sub-directories and contents.
4. Delete the NiFi-Registry installation directory tree.

The product is now uninstalled.

If you found that the provided solution(s) assisted you with your query, please take a moment to login and click Accept as Solution below each response that helped.

Thank you,

Matt

 

 

 

View solution in original post

2 REPLIES 2

avatar
Master Mentor

@winbob 
- What does the output of "ps -ef|grep -i nifi" return on your server where NiFi-Registry is installed?
- Is this an Apache NiFi-Registry install or a Cloudera managed NiFi-Registry install?  (I see you mentioned you're not sure how it was installed, but uninstalling the service properly differs depending on how it was installed.).

Assuming this is just an Apache NiFi-Registry installation on Linux, the most common installation method is simply to unpack the tar.gz NiFi-registry file in user defined install location (output from "ps -ef" command will help determine where it is installed).  Then the user would configure the nifi-registry.properties file in the conf directory and start the service via "<install/unpack directory>/bin/nifi-registry.sh start" command.

1. So step one is to stop NiFi-Registry: 
           - Check to see if NiFi-Registry was installed as a linux service "systemctl status nifi-registry". If this returns then NiFi-Registry was installed as a service.  If it returns unknown service then it was not.  Assuming this returns you can stop the service using "systemctl stop nifi-registry". Then issue following commands to remove the linux service setup (does not uninstall product so will still need to complete steps 2 forward). 

systemctl disable nifi-registry
rm /etc/systemd/system/nifi-registry
rm /usr/lib/systemd/system/nifi-registry

           - If not a managed linux service, stop NiFi-Registry using "<install/unpack directory>/bin/nifi-registry.sh stop" ("ps -ef | grep -i nifi" should not return any processes for NiFi-Registry after executing this command).

2. Now you must inspect some NiFi-Registry conf directory files to identify any directory location defined by the user who installed the product. (default would have them all located with the directory tree where NiFi-Registry was unpacked, but very often these path are manually changed).  Search the following configuration files for directory paths:
          - nifi-registry.properties
          - authorizers.xml
          - providers.xml
          - logback.xml
NOTE: if any of the directory property paths start with "./" then NiFi-Registry is building the directory path tree within the existing NiFi-Registry installation path tree.

3. Once you have all the path external to the NiFi-Registry installation base path located, you can start deleting these directories and there sub-directories and contents.
4. Delete the NiFi-Registry installation directory tree.

The product is now uninstalled.

If you found that the provided solution(s) assisted you with your query, please take a moment to login and click Accept as Solution below each response that helped.

Thank you,

Matt

 

 

 

avatar
Community Manager

@winbob, Has the reply helped resolve your issue? If so, please mark the appropriate reply as the solution, as it will make it easier for others to find the answer in the future.  



Regards,

Vidya Sargur,
Community Manager


Was your question answered? Make sure to mark the answer as the accepted solution.
If you find a reply useful, say thanks by clicking on the thumbs up button.
Learn more about the Cloudera Community: