forked from docs/doc-exports
Reviewed-by: Hasko, Vladimir <vladimir.hasko@t-systems.com> Co-authored-by: Yang, Tong <yangtong2@huawei.com> Co-committed-by: Yang, Tong <yangtong2@huawei.com>
49 lines
14 KiB
HTML
49 lines
14 KiB
HTML
<a name="mrs_01_1594"></a><a name="mrs_01_1594"></a>
|
|
|
|
<h1 class="topictitle1">Installing the Flume Client on Clusters of Versions Earlier Than MRS 3.x</h1>
|
|
<div id="body1595928090852"><div class="section" id="mrs_01_1594__s9d464cc917ca45b1ba39e9a7c0df6006"><h4 class="sectiontitle">Scenario</h4><p id="mrs_01_1594__a8920e65594ce47e0bc00261e734e1588">To use Flume to collect logs, you must install the Flume client on a log host. You can create an ECS and install the Flume client on it.</p>
|
|
<p id="mrs_01_1594__p2452133604410">This section applies to MRS 3.<em id="mrs_01_1594__i08862175314">x</em> or earlier clusters.</p>
|
|
</div>
|
|
<div class="section" id="mrs_01_1594__s9821fff1057643ba92d438ba705d54f8"><h4 class="sectiontitle">Prerequisites</h4><ul id="mrs_01_1594__ueab0ff8756a74ee6952ee4539ef5b0cb"><li id="mrs_01_1594__l3e939d5c4a87445b804b469675d40176">A streaming cluster with the Flume component has been created.</li><li id="mrs_01_1594__l93fbddeb02074d298088ee23ae81b740">The log host is in the same VPC and subnet with the MRS cluster. </li><li id="mrs_01_1594__le8b04f7354e443e4ad419f2200d32c2c">You have obtained the username and password for logging in to the log host.</li></ul>
|
|
</div>
|
|
<div class="section" id="mrs_01_1594__section187301421162510"><h4 class="sectiontitle">Procedure</h4><ol id="mrs_01_1594__ol115134551648"><li id="mrs_01_1594__li10514555842"><span>Create an ECS that meets the requirements.</span></li><li id="mrs_01_1594__li13806122116487"><span>Go to the cluster details page.</span><p><ul id="mrs_01_1594__ul1692910323486"><li id="mrs_01_1594__li792916322486">For versions earlier than MRS 1.9.2, log in to MRS Manager and choose <strong id="mrs_01_1594__b8522125134718">Services</strong>.</li><li id="mrs_01_1594__li979413816488">For MRS 1.9.2 or later, click the cluster name on the MRS console and choose <strong id="mrs_01_1594__b1287620461472">Components</strong>.</li></ul>
|
|
</p></li><li id="mrs_01_1594__li1514145518420"><a name="mrs_01_1594__li1514145518420"></a><a name="li1514145518420"></a><span>Click <strong id="mrs_01_1594__b32347135832421">Download Client</strong>.</span><p><ol type="a" id="mrs_01_1594__ol1551465512415"><li id="mrs_01_1594__li105141355844">In <span class="parmname" id="mrs_01_1594__parmname1051419551849"><b>Client Type</b></span>, select <span class="parmvalue" id="mrs_01_1594__parmvalue351414555415"><b>All client files</b></span>.</li><li id="mrs_01_1594__li135147558412">In <span class="parmname" id="mrs_01_1594__parmname1515145512418"><b>Download to</b></span>, select <span class="parmvalue" id="mrs_01_1594__parmvalue95151755949"><b>Remote host</b></span>.</li><li id="mrs_01_1594__li151520551643">Set <span class="parmname" id="mrs_01_1594__parmname62379481232421"><b>Host IP Address</b></span> to the IP address of the ECS, <span class="parmname" id="mrs_01_1594__parmname113775124532421"><b>Host Port</b></span> to <span class="parmvalue" id="mrs_01_1594__parmvalue143895318232421"><b>22</b></span>, and <span class="parmname" id="mrs_01_1594__parmname173796778332421"><b>Save Path</b></span> to <span class="parmvalue" id="mrs_01_1594__parmvalue1151512554416"><b>/home/linux</b></span>.<ul id="mrs_01_1594__ul151510551643"><li id="mrs_01_1594__li65151355549">If the default port <span class="parmvalue" id="mrs_01_1594__parmvalue651514551942"><b>22</b></span> for logging in to an ECS through SSH has been changed, set <span class="parmname" id="mrs_01_1594__parmname1515145515410"><b>Host Port</b></span> to a new port.</li><li id="mrs_01_1594__li95158551449">The value of <span class="parmname" id="mrs_01_1594__parmname19515555846"><b>Save Path</b></span> contains a maximum of 256 characters.</li></ul>
|
|
</li><li id="mrs_01_1594__li10919401436">Set <span class="parmname" id="mrs_01_1594__parmname1397017715431"><b>Login User</b></span> to <span class="parmname" id="mrs_01_1594__parmname2976076438"><b>root</b></span>.<p id="mrs_01_1594__p195164551749">If another user is used, ensure that the user has permissions to read, write, and execute the save path.</p>
|
|
</li><li id="mrs_01_1594__li105162551245">In <span class="parmname" id="mrs_01_1594__parmname8516205516415"><b>SSH Private Key</b></span>, select and upload the key file used for creating the cluster.</li><li id="mrs_01_1594__li751695510416">Click <span class="uicontrol" id="mrs_01_1594__uicontrol125161955846"><b>OK</b></span> to generate a client file.<p id="mrs_01_1594__p11516355949">If the following information is displayed, the client package is saved.</p>
|
|
<pre class="codeblock" id="mrs_01_1594__codeblock16516175515418">Client files downloaded to the remote host successfully.</pre>
|
|
<p id="mrs_01_1594__p105168559417">If the following information is displayed, check the username, password, and security group configurations of the remote host. Ensure that the username and password are correct and an inbound rule of the SSH (22) port has been added to the security group of the remote host. And then, go to <a href="#mrs_01_1594__li1514145518420">3</a> to download the client again.</p>
|
|
<pre class="codeblock" id="mrs_01_1594__codeblock135171655741">Failed to connect to the server. Please check the network connection or parameter settings.</pre>
|
|
</li></ol>
|
|
</p></li><li id="mrs_01_1594__li15172550416"><span>Choose <strong id="mrs_01_1594__b105234431032421">Flume</strong> > <span class="uicontrol" id="mrs_01_1594__uicontrol67038408432421"><b>Instance</b></span>. Query the <span class="parmname" id="mrs_01_1594__parmname37437590632421"><b>Business IP Address</b></span> of any Flume instance and any two MonitorServer instances.</span></li><li id="mrs_01_1594__li1351711554415"><span>Log in to the ECS using VNC. See section "Login Using VNC" in the <i><cite id="mrs_01_1594__cite28844811230">Elastic Cloud Service User Guide</cite></i> (<span class="menucascade" id="mrs_01_1594__menucascade2886480234"><b><span class="uicontrol" id="mrs_01_1594__uicontrol88813481231">Instances</span></b> > <b><span class="uicontrol" id="mrs_01_1594__uicontrol588144816239">Logging In to a Linux ECS</span></b> > <b><span class="uicontrol" id="mrs_01_1594__uicontrol2088148192318">Login Using VNC</span></b></span>.</span><p><p id="mrs_01_1594__p740012148291"></p>
|
|
<p id="mrs_01_1594__p924516130597">Log in to the ECS using an SSH key by referring to <a href="https://docs.otc.t-systems.com/usermanual/ecs/en-us_topic_0017955380.html" target="_blank" rel="noopener noreferrer">Login Using an SSH Key</a> and set the password. Then log in to the ECS using VNC.</p>
|
|
</p></li><li id="mrs_01_1594__li1251714553418"><span>On the ECS, switch to user <strong id="mrs_01_1594__b20517145513416">root</strong> and copy the installation package to the <span class="filepath" id="mrs_01_1594__filepath135171155640"><b>/opt</b></span> directory.</span><p><p id="mrs_01_1594__p651720551441"><strong id="mrs_01_1594__b14517115518410">sudo su - root</strong></p>
|
|
<p id="mrs_01_1594__p12517655947"><strong id="mrs_01_1594__b651715557418">cp /home/linux/MRS_Flume_Client.tar /opt</strong></p>
|
|
</p></li><li id="mrs_01_1594__li351875515419"><span>Run the following command in the <span class="filepath" id="mrs_01_1594__filepath1151835512419"><b>/opt</b></span> directory to decompress the package and obtain the verification file and the configuration package of the client:</span><p><p id="mrs_01_1594__p18518755644"><strong id="mrs_01_1594__b1451835519420">tar -xvf MRS_Flume_Client.tar</strong></p>
|
|
</p></li><li id="mrs_01_1594__li65187551646"><span>Run the following command to verify the configuration package of the client:</span><p><p id="mrs_01_1594__p1051820553413"><strong id="mrs_01_1594__b16518655941">sha256sum -c MRS_Flume_ClientConfig.tar.sha256</strong></p>
|
|
<p id="mrs_01_1594__p1552312551248">If the following information is displayed, the file package is successfully verified:</p>
|
|
<pre class="screen" id="mrs_01_1594__screen1552310551048">MRS_Flume_ClientConfig.tar: OK</pre>
|
|
</p></li><li id="mrs_01_1594__li852412551749"><span>Run the following command to decompress <span class="filepath" id="mrs_01_1594__filepath95241355345"><b>MRS_Flume_ClientConfig.tar</b></span>:</span><p><p id="mrs_01_1594__p1552435515418"><strong id="mrs_01_1594__b175249552412">tar -xvf MRS_Flume_ClientConfig.tar</strong></p>
|
|
</p></li><li id="mrs_01_1594__li2052475511412"><span>Run the following command to install the client running environment to a new directory, for example, <span class="filepath" id="mrs_01_1594__filepath85241755549"><b>/opt/Flumeenv</b></span>. A directory is automatically generated during the client installation.</span><p><p id="mrs_01_1594__p6524105519417"><strong id="mrs_01_1594__b1152417551449">sh /opt/MRS_Flume_ClientConfig/install.sh /opt/Flumeenv</strong></p>
|
|
<p id="mrs_01_1594__p45247551040">If the following information is displayed, the client running environment is successfully installed:</p>
|
|
<pre class="screen" id="mrs_01_1594__screen1152485510416">Components client installation is complete.</pre>
|
|
</p></li><li id="mrs_01_1594__li1852445510411"><span>Run the following command to configure environment variables:</span><p><p id="mrs_01_1594__p205253551843"><strong id="mrs_01_1594__b1352511556413">source /opt/Flumeenv/bigdata_env</strong></p>
|
|
</p></li><li id="mrs_01_1594__li1152512556414"><span>Run the following commands to decompress the Flume client package:</span><p><p id="mrs_01_1594__p652511557410"><strong id="mrs_01_1594__b1052510551849">cd /opt/MRS_Flume_ClientConfig/Flume</strong></p>
|
|
<p id="mrs_01_1594__p852515512410"><strong id="mrs_01_1594__b45251755740">tar -xvf FusionInsight-Flume-1.6.0.tar.gz</strong></p>
|
|
</p></li><li id="mrs_01_1594__li352517557414"><span>Run the following command to check whether the password of the current user has expired:</span><p><p id="mrs_01_1594__p6525255741"><strong id="mrs_01_1594__b1652516551347">chage -l root</strong></p>
|
|
<p id="mrs_01_1594__p125251155441">If the value of <span class="parmname" id="mrs_01_1594__parmname195251155747"><b>Password expires</b></span> is earlier than the current time, the password has expired. Run the <strong id="mrs_01_1594__b652518551419">chage -M -1 root</strong> command to validate the password.</p>
|
|
</p></li><li id="mrs_01_1594__li45251955648"><span>Run the following command to install the Flume client to a new directory, for example, <span class="filepath" id="mrs_01_1594__filepath105251255444"><b>/opt/FlumeClient</b></span>. A directory is automatically generated during the client installation.</span><p><p id="mrs_01_1594__p75254551344"><strong id="mrs_01_1594__b88602329132421">sh /opt/MRS_Flume_ClientConfig/Flume/install.sh -d /opt/FlumeClient -f </strong><em id="mrs_01_1594__i197969126832421">service IP address of the MonitorServer instance</em><strong id="mrs_01_1594__b125646674632421"> -c </strong><em id="mrs_01_1594__i114490917832421">path of the Flume configuration file</em> <strong id="mrs_01_1594__b22809548232421">-l /var/log/ -e </strong><em id="mrs_01_1594__i9906249232421">service IP address of Flume</em> <strong id="mrs_01_1594__b184770729932421">-n </strong><em id="mrs_01_1594__i117208681632421">name of the Flume client</em></p>
|
|
<p id="mrs_01_1594__p2052519554416">The parameters are described as follows:</p>
|
|
<ul id="mrs_01_1594__ul155251555413"><li id="mrs_01_1594__li185251555044"><strong id="mrs_01_1594__b122062560032421">-d</strong>: indicates the installation path of the Flume client.</li><li id="mrs_01_1594__li1852575516418">(Optional) <strong id="mrs_01_1594__b14582247232421">-f</strong>: indicates the service IP addresses of the two MonitorServer instances, separated by a comma (,). If the IP addresses are not configured, the Flume client will not send alarm information to MonitorServer, and the client information will not be displayed on MRS Manager.</li><li id="mrs_01_1594__li752513557410">(Optional) <strong id="mrs_01_1594__b31040219832421">-c</strong>: indicates the <span class="filepath" id="mrs_01_1594__filepath213569782132421"><b>properties.properties</b></span> configuration file that the Flume client loads after installation. If this parameter is not specified, the <strong id="mrs_01_1594__b166402707832421">fusioninsight-flume-1.6.0/conf/properties.properties</strong> file in the client installation directory is used by default. The configuration file of the client is empty. You can modify the configuration file as required and the Flume client will load it automatically.</li><li id="mrs_01_1594__li85261755142">(Optional) <strong id="mrs_01_1594__b175239580232421">-l</strong>: indicates the log directory. The default value is <strong id="mrs_01_1594__b121434924132421">/var/log/Bigdata</strong>.</li><li id="mrs_01_1594__li1952645519418">(Optional) <strong id="mrs_01_1594__b28765688232421">-e</strong>: indicates the service IP address of the Flume instance. It is used to receive the monitoring indicators reported by the client.</li><li id="mrs_01_1594__li17526115511414">(Optional) <strong id="mrs_01_1594__b116784329432421">-n</strong>: indicates the name of the Flume client.</li><li id="mrs_01_1594__li352615512420">IBM JDK does not support <strong id="mrs_01_1594__b210377460032421">-Xloggc</strong>. You must change <strong id="mrs_01_1594__b89957522532421">-Xloggc</strong> to <strong id="mrs_01_1594__b39561375332421">-Xverbosegclog</strong> in <strong id="mrs_01_1594__b149120023632421">flume/conf/flume-env.sh</strong>. For 32-bit JDK, the value of <strong id="mrs_01_1594__b22214430932421">-Xmx</strong> must not exceed 3.25 GB.</li><li id="mrs_01_1594__li125265557417">In <strong id="mrs_01_1594__b155041231532421">flume/conf/flume-env.sh</strong>, the default value of <strong id="mrs_01_1594__b111699425032421">-Xmx</strong> is 4 GB. If the client memory is too small, you can change it to 512 MB or even 1 GB.</li></ul>
|
|
<p id="mrs_01_1594__p1652620554419">For example, run <strong id="mrs_01_1594__b11526115512413">sh install.sh -d /opt/FlumeClient</strong>.</p>
|
|
<p id="mrs_01_1594__p95261455241">If the following information is displayed, the client is successfully installed:</p>
|
|
<pre class="screen" id="mrs_01_1594__screen552612551415">install flume client successfully.</pre>
|
|
</p></li></ol>
|
|
</div>
|
|
</div>
|
|
<div>
|
|
<div class="familylinks">
|
|
<div class="parentlink"><strong>Parent topic:</strong> <a href="mrs_01_0392.html">Installing the Flume Client</a></div>
|
|
</div>
|
|
</div>
|
|
|