Uninstalling your agents
Uninstall a single agent or all the agents from a managed system.
Before you begin
For multi-instance
agents, you must remove all agent instances before you uninstall the agent. Otherwise, agent entries
are not cleared from the registry. To remove instances, run the following command:
name-agent.bat remove instance_name
./name-agent.sh remove instance_name
For the following agents, an agent-specific task must be completed before you complete the uninstallation procedure:
- For the Monitoring Agent for HTTP Server, you
must delete the
Include
statement in the http.conf file, for example,"Include "/opt/ibm/apm/agent/tmp/khu/kvm65s2_8044.conf"
, before you restart the IBM® HTTP server. - For
the Monitoring Agent for Python, run
install_dir/lx8266/pg/bin/uninstall.sh
to remove injection codes before you uninstall the agent. - For the Monitoring Agent for PHP, run
install_dir/bin/lx8266/pj/lib/uninstall.instance_name.sh
to move injection codes before you uninstall the agent. - For the Monitoring Agent for WebSphere® Applications, you
must unconfigure the data collector for all monitored server instances before you uninstall the
agent. Follow the instructions in WebSphere Applications agent: Unconfiguring the data collector.For the WebSphere Applications agent, make sure that the user ID, which is used to uninstall the agent, has full read and write permissions to the logs and runtime directories and all their contained subdirectories and files within the data collector home directory. The data collector home directory is as follows:
- install_dir\dchome\7.3.0.14.08
- install_dir/yndchome/7.3.0.14.08
- For the Node.js agent, you must remove the monitoring plug-in from your Node.js application before you uninstall the agent. Follow the instructions in Node.js agent: Removing the monitoring plug-in.
- For the Microsoft .NET agent, you
must complete the following before you uninstall the agent:
- Disable the modules for .NET Core Applications. Follow the instructions in Disabling Modules for .NET Core Applications.
- Remove the data collector from your .NET applications. Follow the instructions in Microsoft .NET agent: Removing the .NET data collector.
- For the IBM Integration Bus agent, if you configured transaction tracking for brokers with the agent provided user exit, you must remove the user exit before you uninstall the agent. Follow the instructions in Removing the KQIUserExit user exit.
- For the Internet Service Monitoring, go to <candle_home>\BIN and run the ism-agent.bat file with uninstall as an argument. In case you want to uninstall all monitoring agents on the server using smai-agent.bat, first run the ism-agent.bat with uninstall as an argument and then run the smai-agent.bat
- For the Monitoring Agent for SAP NetWeaver Java™ Stack,
before you uninstall the agent, stop all SAP NetWeaver Java Stack agent instances by using the
following command:
sap_netweaver_java_stack-agent.bat stop instance_name
About this task
Procedure
What to do next
For the Monitoring Agent for HTTP Server, after you uninstall the agent, you must
remove the following files manually:
- /tmp/khu_cps.properties
- /tmp/httpserver-disc.error
For the Monitoring Agent for Python:
- Delete the Django
pyc
configuration file to ensure the restored Djangopyc
file generates its binary. - Restart the Apache server to remove the loaded middleware in the Apache processes.
For the Monitoring Agent for Ruby, to
uninstall the diagnostics data collector:
- Navigate to the home directory of your application, open its
Gemfile
, and remove the following line from the file:gem 'stacktracer'
- Restart your Ruby on Rails application.
- Uninstall the diagnostics data collector. Enter:
gem uninstall Gemfile
- Remove the runtime directory of the data collector. The default location of this directory is install_dir/install-images/kkm/dchome
For the Monitoring Agent for Microsoft .NET, complete
these steps:
- Remove the data collector
dll
files using one of the following options:- Reboot your operating system.
- Try to delete the file
install_dir\qe\bin64\CorProfLog.dll
.A File in Use dialog is displayed. It identifies the .NET processes that are currently running.
- Restart each of the .NET processes.
- Restart your .NET applications.