doc-exports/docs/lts/umn/lts_02_0015.html
Liu, Siying 35cd899fe1 LTS UMN 20230609 version.
Reviewed-by: Mützel, Andrea <andrea.muetzel@t-systems.com>
Co-authored-by: Liu, Siying <liusiying@noreply.gitea.eco.tsi-dev.otc-service.com>
Co-committed-by: Liu, Siying <liusiying@noreply.gitea.eco.tsi-dev.otc-service.com>
2023-08-08 15:12:51 +00:00

57 lines
14 KiB
HTML

<a name="lts_02_0015"></a><a name="lts_02_0015"></a>
<h1 class="topictitle1">Uninstalling ICAgent</h1>
<div id="body32001227"><p id="lts_02_0015__en-us_topic_0000001167192835_en-us_topic_0089582116_p912134511">If ICAgent is uninstalled from a host, log collection will be affected. Exercise caution when performing this operation.</p>
<div class="note" id="lts_02_0015__en-us_topic_0000001167192835_note10915102418718"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="lts_02_0015__en-us_topic_0000001167192835_p12319140193615">Only ICAgent installed on Linux hosts can be uninstalled from the <strong id="lts_02_0015__en-us_topic_0000001167192835_b3086033526125">Host Management</strong> page of the LTS console. To uninstall ICAgent from a Windows host, go to <strong id="lts_02_0015__en-us_topic_0000001167192835_b14899956996125">\ICProbeAgent\bin\manual\win</strong> in the directory where the ICAgent installation package was decompressed, and double-click the script named <strong id="lts_02_0015__en-us_topic_0000001167192835_b3232714576125">uninstall.bat</strong>. If the message <strong id="lts_02_0015__en-us_topic_0000001167192835_b8619598406125">ICAgent uninstall success</strong> is displayed, the uninstallation was successful.</p>
<p id="lts_02_0015__en-us_topic_0000001167192835_p13916924872">Uninstalling ICAgent does not delete the installation files. You need to delete them manually if necessary.</p>
</div></div>
<p id="lts_02_0015__en-us_topic_0000001167192835_a1e63d18ccc3740a8896ba307b7a03ae6">There are a number of ways to uninstall ICAgent:</p>
<ul id="lts_02_0015__en-us_topic_0000001167192835_en-us_topic_0089582116_ul46358011247"><li id="lts_02_0015__en-us_topic_0000001167192835_lbfc8dbb4e0354404874a0b9e28afcdc8"><a href="#lts_02_0015__en-us_topic_0000001167192835_s56b926e2e7b74b9ba2a87166afb4989b">Uninstalling ICAgent on the Console</a>: This can be used to uninstall ICAgent that has been successfully installed.</li><li id="lts_02_0015__en-us_topic_0000001167192835_l4dced8c4004345e08c1b128cf9055d67"><a href="#lts_02_0015__en-us_topic_0000001167192835_s3b88a85d5fc54597bdb601e26408a808">Uninstalling ICAgent on a Host</a>: This can be used to remove ICAgent that fails to be installed for reinstallation.</li><li id="lts_02_0015__en-us_topic_0000001167192835_li11176124162011"><a href="#lts_02_0015__en-us_topic_0000001167192835_section6144172213109">Remotely Uninstalling ICAgent</a>: This can be used to remotely uninstall ICAgent that has been successfully installed.</li><li id="lts_02_0015__en-us_topic_0000001167192835_li1826103317218"><a href="#lts_02_0015__en-us_topic_0000001167192835_section1091572622115">Batch Uninstalling ICAgent</a>: This can be used to uninstall ICAgent that has been successfully installed from a batch of hosts.</li></ul>
<div class="section" id="lts_02_0015__en-us_topic_0000001167192835_s56b926e2e7b74b9ba2a87166afb4989b"><a name="lts_02_0015__en-us_topic_0000001167192835_s56b926e2e7b74b9ba2a87166afb4989b"></a><a name="en-us_topic_0000001167192835_s56b926e2e7b74b9ba2a87166afb4989b"></a><h4 class="sectiontitle">Uninstalling ICAgent on the Console</h4><ol id="lts_02_0015__en-us_topic_0000001167192835_ol1163615355457"><li id="lts_02_0015__en-us_topic_0000001167192835_li13636153516452">Log in to the LTS console and choose <strong id="lts_02_0015__en-us_topic_0000001167192835_b66591813185318">Host Management</strong> in the navigation pane on the left.</li><li id="lts_02_0015__en-us_topic_0000001167192835_li1321353322419">Click the <strong id="lts_02_0015__en-us_topic_0000001167192835_b1298623555311">Hosts</strong> tab.</li><li id="lts_02_0015__en-us_topic_0000001167192835_li2636635174516">Select one or more hosts where ICAgent is to be uninstalled and click <strong id="lts_02_0015__en-us_topic_0000001167192835_b121918403539">Uninstall ICAgent</strong>.</li><li id="lts_02_0015__en-us_topic_0000001167192835_li1863643514519">In the displayed dialog box, click <strong id="lts_02_0015__en-us_topic_0000001167192835_b20111883986125">OK</strong>.<p id="lts_02_0015__en-us_topic_0000001167192835_p4648155913615">The uninstallation begins. This process takes about a minute.</p>
<p id="lts_02_0015__en-us_topic_0000001167192835_abcaa14c974d74c6294debcda7740cd79">The ICAgent uninstalled will be removed from the host list.</p>
<div class="note" id="lts_02_0015__en-us_topic_0000001167192835_note378712220197"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="lts_02_0015__en-us_topic_0000001167192835_p23592014467">To reinstall ICAgent, wait for 5 minutes after the uninstallation completes, or the reinstalled ICAgent may be unintentionally uninstalled again.</p>
</div></div>
</li></ol>
</div>
<div class="section" id="lts_02_0015__en-us_topic_0000001167192835_s3b88a85d5fc54597bdb601e26408a808"><a name="lts_02_0015__en-us_topic_0000001167192835_s3b88a85d5fc54597bdb601e26408a808"></a><a name="en-us_topic_0000001167192835_s3b88a85d5fc54597bdb601e26408a808"></a><h4 class="sectiontitle">Uninstalling ICAgent on a Host</h4><ol id="lts_02_0015__en-us_topic_0000001167192835_ol115565612467"><li id="lts_02_0015__en-us_topic_0000001167192835_li2055686104614">Log in to a host where ICAgent is to be uninstalled as user <strong id="lts_02_0015__en-us_topic_0000001167192835_b11960951105713">root</strong>.</li><li id="lts_02_0015__en-us_topic_0000001167192835_li1555611624615">Run the following command:<p id="lts_02_0015__en-us_topic_0000001167192835_p891012139469"><a name="lts_02_0015__en-us_topic_0000001167192835_li1555611624615"></a><a name="en-us_topic_0000001167192835_li1555611624615"></a><strong id="lts_02_0015__en-us_topic_0000001167192835_a4391a589ff234a96aa4761faba2c3ed7">bash /opt/oss/servicemgr/ICAgent/bin/manual/uninstall.sh;</strong></p>
<p id="lts_02_0015__en-us_topic_0000001167192835_p56221116462">If the message <strong id="lts_02_0015__en-us_topic_0000001167192835_b3752262466125">ICAgent uninstall success</strong> is displayed, the uninstallation has completed.</p>
</li></ol>
</div>
<div class="section" id="lts_02_0015__en-us_topic_0000001167192835_section6144172213109"><a name="lts_02_0015__en-us_topic_0000001167192835_section6144172213109"></a><a name="en-us_topic_0000001167192835_section6144172213109"></a><h4 class="sectiontitle">Remotely Uninstalling ICAgent</h4><p id="lts_02_0015__en-us_topic_0000001167192835_p1645519475100">You can uninstall ICAgent on one host remotely from another host.</p>
<ol id="lts_02_0015__en-us_topic_0000001167192835_ol10742172164617"><li id="lts_02_0015__en-us_topic_0000001167192835_li12742721174615">Run the following command on the host where ICAgent has been installed, <em id="lts_02_0015__en-us_topic_0000001167192835_i067211918413">x.x.x.x</em> is the IP address of the host you want to uninstall ICAgent from.<p id="lts_02_0015__en-us_topic_0000001167192835_p940902511469"><strong id="lts_02_0015__en-us_topic_0000001167192835_b7727829135813">bash /opt/oss/servicemgr/ICAgent/bin/<strong id="lts_02_0015__en-us_topic_0000001167192835_b167211329155813">remoteUninstall</strong>/remote_uninstall.sh -ip </strong><em id="lts_02_0015__en-us_topic_0000001167192835_i1727152913583">x.x.x.x</em></p>
</li><li id="lts_02_0015__en-us_topic_0000001167192835_li19742182124613">Enter the password for user <strong id="lts_02_0015__en-us_topic_0000001167192835_b195619350589">root</strong> of the host when prompted.<div class="note" id="lts_02_0015__en-us_topic_0000001167192835_note65919111169"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="lts_02_0015__en-us_topic_0000001167192835_ul11493202120168"><li id="lts_02_0015__en-us_topic_0000001167192835_li184931521161615">If the Expect tool is installed on the host that has ICAgent installed, the ICAgent uninstallation should be able to complete without prompting you for a password. Otherwise, enter the password as prompted.</li><li id="lts_02_0015__en-us_topic_0000001167192835_li106360398163">Ensure that user <strong id="lts_02_0015__en-us_topic_0000001167192835_b144462516416">root</strong> can run SSH or SCP commands on the host where ICAgent has been installed to communicate with the remote host to uninstall ICAgent.</li><li id="lts_02_0015__en-us_topic_0000001167192835_li15814953113619">If the message <strong id="lts_02_0015__en-us_topic_0000001167192835_b20120037096125">ICAgent uninstall success</strong> is displayed, the uninstallation has completed.</li></ul>
</div></div>
</li></ol>
</div>
<div class="section" id="lts_02_0015__en-us_topic_0000001167192835_section1091572622115"><a name="lts_02_0015__en-us_topic_0000001167192835_section1091572622115"></a><a name="en-us_topic_0000001167192835_section1091572622115"></a><h4 class="sectiontitle">Batch Uninstalling ICAgent</h4><p id="lts_02_0015__en-us_topic_0000001167192835_p291117412375">If ICAgent has been installed on a host and the ICAgent installation package <strong id="lts_02_0015__en-us_topic_0000001167192835_b13241105120112">ICProbeAgent.tar.gz</strong> is in the <strong id="lts_02_0015__en-us_topic_0000001167192835_b14247051014">/opt/ICAgent/</strong> directory of the host, you can use this method to uninstall ICAgent from multiple hosts at once.</p>
<div class="notice" id="lts_02_0015__en-us_topic_0000001167192835_note1297320585379"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="lts_02_0015__en-us_topic_0000001167192835_p13973155814378">The hosts must all belong to the same Virtual Private Cloud (VPC) and be on the same subnet.</p>
</div></div>
<p id="lts_02_0015__en-us_topic_0000001167192835_p7639318174319"><strong id="lts_02_0015__en-us_topic_0000001167192835_b12639318194317">Prerequisites</strong></p>
<p id="lts_02_0015__en-us_topic_0000001167192835_p2616113913431">The IP addresses and passwords of all hosts to uninstall ICAgent have been collected, sorted in the <strong id="lts_02_0015__en-us_topic_0000001167192835_b74641982214">iplist.cfg</strong> file, and uploaded to the <strong id="lts_02_0015__en-us_topic_0000001167192835_b7470480215">/opt/ICAgent/</strong> directory on the host that has ICAgent installed. Each IP address and password in the <strong id="lts_02_0015__en-us_topic_0000001167192835_b065612174217">iplist.cfg</strong> file must be separated by a space, as shown in the following example:</p>
<p id="lts_02_0015__en-us_topic_0000001167192835_p1548225822014"><strong id="lts_02_0015__en-us_topic_0000001167192835_b11109727123816">192.168.0.109</strong> <em id="lts_02_0015__en-us_topic_0000001167192835_i15109142719389">Password</em> (Replace the IP address and password with the actual ones)</p>
<p id="lts_02_0015__en-us_topic_0000001167192835_p141601016222"><strong id="lts_02_0015__en-us_topic_0000001167192835_b5215429173810">192.168.0.39</strong> <em id="lts_02_0015__en-us_topic_0000001167192835_i421512933814">Password</em> (Replace the IP address and password with the actual ones)</p>
<div class="note" id="lts_02_0015__en-us_topic_0000001167192835_note1496715574713"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="lts_02_0015__en-us_topic_0000001167192835_ul10444321164817"><li id="lts_02_0015__en-us_topic_0000001167192835_li5122111919357">Because the <strong id="lts_02_0015__en-us_topic_0000001167192835_b2644123153111">iplist.cfg</strong> file contains sensitive information, you are advised to clear it after using it.</li></ul>
<ul id="lts_02_0015__en-us_topic_0000001167192835_ul33449336484"><li id="lts_02_0015__en-us_topic_0000001167192835_li15759174210487">If all hosts share a password, list only IP addresses in the <strong id="lts_02_0015__en-us_topic_0000001167192835_b16156307220">iplist.cfg</strong> file and enter the password during execution. If one of the hosts uses a different password, type the password behind its IP address.</li></ul>
</div></div>
<p id="lts_02_0015__en-us_topic_0000001167192835_p179427484620"><strong id="lts_02_0015__en-us_topic_0000001167192835_b2025522713">Procedure</strong></p>
<ol id="lts_02_0015__en-us_topic_0000001167192835_ol14788175515460"><li id="lts_02_0015__en-us_topic_0000001167192835_li1178812550461">Run the following command on the host that has ICAgent installed:<p id="lts_02_0015__en-us_topic_0000001167192835_p152442311959"><a name="lts_02_0015__en-us_topic_0000001167192835_li1178812550461"></a><a name="en-us_topic_0000001167192835_li1178812550461"></a><strong id="lts_02_0015__en-us_topic_0000001167192835_b11980542182212">bash /opt/oss/servicemgr/ICAgent/bin/remoteUninstall/remote_uninstall.sh -batchModeConfig /opt/ICAgent/iplist.cfg</strong></p>
<p id="lts_02_0015__en-us_topic_0000001167192835_p12876313165214">Enter the default password for user <strong id="lts_02_0015__en-us_topic_0000001167192835_b828255316210">root</strong> of the hosts to uninstall ICAgent. If the passwords of all hosts have been configured in the <strong id="lts_02_0015__en-us_topic_0000001167192835_b328845314216">iplist.cfg</strong> file, press <strong id="lts_02_0015__en-us_topic_0000001167192835_b8288155319212">Enter</strong> to skip this step.</p>
<pre class="screen" id="lts_02_0015__en-us_topic_0000001167192835_screen146121372410">batch uninstall begin
Please input default passwd:
send cmd to 192.168.0.109
send cmd to 192.168.0.39
2 tasks running, please wait...
End of uninstall agent: 192.168.0.109
End of uninstall agent: 192.168.0.39
All hosts uninstall icagent finish.</pre>
<p id="lts_02_0015__en-us_topic_0000001167192835_p1568349182512">If the message <strong id="lts_02_0015__en-us_topic_0000001167192835_b3543820476125">All hosts uninstall icagent finish.</strong> is displayed, the batch uninstallation has completed.</p>
</li><li id="lts_02_0015__en-us_topic_0000001167192835_li87883553460">Choose <strong id="lts_02_0015__en-us_topic_0000001167192835_b13269153010321">Host Management</strong> &gt; <strong id="lts_02_0015__en-us_topic_0000001167192835_b15269173023217">Hosts</strong> on the LTS console to view the ICAgent status.</li></ol>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="lts_04_0012.html">Managing Hosts</a></div>
</div>
</div>