Yang, Tong 6182f91ba8 MRS component operation guide_normal 2.0.38.SP20 version
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>
2022-12-09 14:55:21 +00:00

94 lines
32 KiB
HTML

<a name="mrs_01_0856"></a><a name="mrs_01_0856"></a>
<h1 class="topictitle1">Changing NodeManager Storage Directories</h1>
<div id="body1590130746685"><div class="section" id="mrs_01_0856__s961978f8a3e94ca9b84b6180eec1e507"><h4 class="sectiontitle">Scenario</h4><p id="mrs_01_0856__a7edb8e0639c74282bf157c9e3e997a15">If the storage directories defined by the Yarn NodeManager are incorrect or the Yarn storage plan changes, the system administrator needs to modify the NodeManager storage directories on Manager to ensure that the Yarn works properly. The storage directories of NodeManager include the local storage directory <strong id="mrs_01_0856__b10844955674139">yarn.nodemanager.local-dirs</strong> and log directory <strong id="mrs_01_0856__b10873753944139">yarn.nodemanager.log-dirs</strong>. Changing the ZooKeeper storage directory includes the following scenarios:</p>
<ul id="mrs_01_0856__uaf344b192f3a49f4a8c5800c47a48b0f"><li id="mrs_01_0856__l43b8819497594710ae09d2d22a1f8397">Change the storage directory of the NodeManager role. In this way, the storage directories of all NodeManager instances are changed.</li><li id="mrs_01_0856__l3a628bfd1ad54ead9513dba78aad7612">Change the storage directory of a single NodeManager instance. In this way, only the storage directory of this instance is changed, and the storage directories of other instances remain the same.</li></ul>
</div>
<div class="section" id="mrs_01_0856__s30e2de7a0c6242a58ebcfc816d240a5b"><h4 class="sectiontitle">Impact on the System</h4><ul id="mrs_01_0856__u7edec2b31e3549a2947749f8002ba36b"><li id="mrs_01_0856__l6ad72abaeb014977b704795807545567">The cluster needs to stopped and restarted during the process of changing the storage directory of the NodeManager role, and the cluster cannot provide services before started.</li><li id="mrs_01_0856__lf81bdded3bd142128db3edb73f2dcc0f">The NodeManager instance needs to stopped and restarted during the process of changing the storage directory of the instance, and the instance at this node cannot provide services before it is started.</li><li id="mrs_01_0856__l636eb097d38c4fda92cf8e536450d1b6">The directory for storing service parameter configurations must also be updated.</li><li id="mrs_01_0856__l8456b2bd4a7042d6b96239b2f39be4c2">After the storage directories of NodeManager are changed, you need to download and install the client again.</li></ul>
</div>
<div class="section" id="mrs_01_0856__s5e36467c58a843c0b4b9ee2541fc115c"><h4 class="sectiontitle">Prerequisites</h4><ul id="mrs_01_0856__u308972d1477d451789255e10109c5c14"><li id="mrs_01_0856__l2c4b2d7f534d4dd2a6df448ca0161680">New disks have been prepared and installed on each data node, and the disks are formatted.</li><li id="mrs_01_0856__l821426bc14b9432ab73a795a87bf0048">New directories have been planned for storing data in the original directories.</li><li id="mrs_01_0856__l4549b9617d3c4a3692af18f396842639">The system administrator account <strong id="mrs_01_0856__a4dbbb217424347e99c8f9be7beb80db0">admin</strong> has been prepared.</li></ul>
</div>
<div class="section" id="mrs_01_0856__se70ae56167c04d99ba599d31d74bc261"><h4 class="sectiontitle">Procedure</h4><p id="mrs_01_0856__p1856245413499">For versions earlier than MRS 1.9.2, perform the following operations:</p>
<ol id="mrs_01_0856__ol2040185714498"><li id="mrs_01_0856__li15401557164917"><span>Check the environment.</span><p><ol type="a" id="mrs_01_0856__ol10409573491"><li id="mrs_01_0856__li54005774918">Log in to MRS Manager and click the cluster name. Choose <strong id="mrs_01_0856__b49291242124717">Services</strong> and check whether health status of Yarn is <strong id="mrs_01_0856__b9935134218473">Good</strong>.<ul id="mrs_01_0856__ul24085714919"><li id="mrs_01_0856__li194018573498">If yes, go to <a href="#mrs_01_0856__li64045734911">1.c</a>.</li><li id="mrs_01_0856__li540157174912">If no, go to <a href="#mrs_01_0856__li174035711490">1.b</a>.</li></ul>
</li><li id="mrs_01_0856__li174035711490"><a name="mrs_01_0856__li174035711490"></a><a name="li174035711490"></a>Rectify the Yarn fault. No further action is required.</li><li id="mrs_01_0856__li64045734911"><a name="mrs_01_0856__li64045734911"></a><a name="li64045734911"></a>Determine whether to change the storage directory of the NodeManager role or that of a single NodeManager instance:<ul id="mrs_01_0856__ul64075714912"><li id="mrs_01_0856__li640185710497">To change the storage directory of the NodeManager role, go to <a href="#mrs_01_0856__li104015571499">2</a>.</li><li id="mrs_01_0856__li04035717491">To change the storage directory of a single NodeManager instance, go to <a href="#mrs_01_0856__li1041165717494">3</a>.</li></ul>
</li></ol>
</p></li><li id="mrs_01_0856__li104015571499"><a name="mrs_01_0856__li104015571499"></a><a name="li104015571499"></a><span>Change the storage directory of the NodeManager role.</span><p><ol type="a" id="mrs_01_0856__ol19408577499"><li id="mrs_01_0856__li174015734917">Click the cluster name and choose <strong id="mrs_01_0856__b919353010494">Services</strong> &gt; <strong id="mrs_01_0856__b125561032124911">Yarn</strong> &gt; <strong id="mrs_01_0856__b2546133684912">Stop</strong> to stop the Yarn service.</li><li id="mrs_01_0856__li27189471579">Log in as user <strong id="mrs_01_0856__b118941638204918">root</strong> to each node on which the Yarn service is installed, and perform the following operations:<ol class="substepthirdol" id="mrs_01_0856__ol2718174735710"><li id="mrs_01_0856__li1771818479573">Create a target directory.<p id="mrs_01_0856__p177181947125719"><a name="mrs_01_0856__li1771818479573"></a><a name="li1771818479573"></a>For example, to create the target directory <strong id="mrs_01_0856__b16711847694139">${BIGDATA_DATA_HOME}/data2</strong>, run the following command:</p>
<p id="mrs_01_0856__p371816479576"><strong id="mrs_01_0856__a3978467248324329b61657ff473d7f71">mkdir ${BIGDATA_DATA_HOME}/data2</strong></p>
</li><li id="mrs_01_0856__li12718147105717">Mount the target directory to the new disk.<p id="mrs_01_0856__p471811477573"><a name="mrs_01_0856__li12718147105717"></a><a name="li12718147105717"></a>For example, mount <strong id="mrs_01_0856__b5012463564139">${BIGDATA_DATA_HOME}/data2</strong> to the new disk.</p>
</li><li id="mrs_01_0856__li17718174725718">Modify permissions on the new directory.<p id="mrs_01_0856__p971814795716"><a name="mrs_01_0856__li17718174725718"></a><a name="li17718174725718"></a>For example, to modify permissions on the <strong id="mrs_01_0856__b17504250604139">${BIGDATA_DATA_HOME}/data2</strong> directory, run the following commands:</p>
<p id="mrs_01_0856__p571816475579"><strong id="mrs_01_0856__b9718114714579">chmod 750 ${BIGDATA_DATA_HOME}/data2 -R</strong> and <strong id="mrs_01_0856__b271817478572">chown omm:wheel ${BIGDATA_DATA_HOME}/data2 -R</strong></p>
</li></ol>
</li><li id="mrs_01_0856__li7401957134914">On MRS Manager, click the cluster name. Choose <strong id="mrs_01_0856__b55877312509">Services </strong>&gt; <strong id="mrs_01_0856__b059373165014">Yarn </strong>&gt; <strong id="mrs_01_0856__b18594113165017">Instance</strong>. Select the NodeManager instance of the corresponding host. Choose <span class="filepath" id="mrs_01_0856__filepath2594631125016"><b>Instance Configuration</b></span> &gt; <span class="filepath" id="mrs_01_0856__filepath55951231115012"><b>All Configurations</b></span>.<p id="mrs_01_0856__p341185744917">Change the value of <strong id="mrs_01_0856__b10230539195115">yarn.nodemanager.local-dirs</strong> or <strong id="mrs_01_0856__b14235739145113">yarn.nodemanager.log-dirs</strong> to the new target directory.</p>
<p id="mrs_01_0856__p29361438114518">For example, change the value of <strong id="mrs_01_0856__b212911314375">yarn.nodemanager.local-dirs</strong> or <strong id="mrs_01_0856__b31135018389">yarn.nodemanager.log-dirs</strong> to <strong id="mrs_01_0856__b16121613113810">/srv/BigData/data2/nm/containerlogs</strong>.</p>
</li><li id="mrs_01_0856__li941155715491">Click <strong id="mrs_01_0856__b6320058144139">Save Configuration</strong>, select <strong id="mrs_01_0856__b16063616314139">Restart the affected services or instances</strong>, and click <strong id="mrs_01_0856__b12871832354139">OK</strong> Restart the Yarn service.<p id="mrs_01_0856__p174119572494">Click <strong id="mrs_01_0856__b9371105343918">Finish</strong> when the system displays "Operation successful". Yarn is successfully started. No further action is required.</p>
</li></ol>
</p></li><li id="mrs_01_0856__li1041165717494"><a name="mrs_01_0856__li1041165717494"></a><a name="li1041165717494"></a><span>Change the storage directory of a single NodeManager instance.</span><p><ol type="a" id="mrs_01_0856__ol8411557124910"><li id="mrs_01_0856__li9411572493">Click the cluster name. Choose <strong id="mrs_01_0856__b12363250145110">Services </strong>&gt; <strong id="mrs_01_0856__b14368750125110">Yarn </strong>&gt; <strong id="mrs_01_0856__b183681550125117">Instance</strong>. Select the NodeManager instance whose storage directory needs to be modified, and choose <strong id="mrs_01_0856__b103681150185111">More </strong>&gt; <strong id="mrs_01_0856__b1369175017513">Stop Instance</strong>.</li><li id="mrs_01_0856__li776344315812">Log in to the NodeManager node as user <strong id="mrs_01_0856__b1697931175214">root</strong> and perform the following operations:<ol class="substepthirdol" id="mrs_01_0856__ol77630432588"><li id="mrs_01_0856__li16763243205812">Create a target directory.<p id="mrs_01_0856__p7763343205812"><a name="mrs_01_0856__li16763243205812"></a><a name="li16763243205812"></a>For example, to create the target directory <strong id="mrs_01_0856__b31998548387">${BIGDATA_DATA_HOME}/data2</strong>, run the following command:</p>
<p id="mrs_01_0856__p3763114385814"><strong id="mrs_01_0856__b183527719392">mkdir ${BIGDATA_DATA_HOME}/data2</strong></p>
</li><li id="mrs_01_0856__li27638433587">Mount the target directory to the new disk.<p id="mrs_01_0856__p137636433588"><a name="mrs_01_0856__li27638433587"></a><a name="li27638433587"></a>For example, mount <strong id="mrs_01_0856__b1070618133910">${BIGDATA_DATA_HOME}/data2</strong> to the new disk.</p>
</li><li id="mrs_01_0856__li15763643125811">Modify permissions on the new directory.<p id="mrs_01_0856__p476324325811"><a name="mrs_01_0856__li15763643125811"></a><a name="li15763643125811"></a>For example, to modify permissions on the <strong id="mrs_01_0856__b551916279398">${BIGDATA_DATA_HOME}/data2</strong> directory, run the following commands:</p>
<p id="mrs_01_0856__p1676344325813"><strong id="mrs_01_0856__b15326103113918">chmod 750 ${BIGDATA_DATA_HOME}/data2 -R</strong> and <strong id="mrs_01_0856__b113321631103915">chown omm:wheel ${BIGDATA_DATA_HOME}/data2 -R</strong></p>
</li></ol>
</li><li id="mrs_01_0856__li10411457174919">On MRS Manager, click the specified NodeManager instance and switch to the <strong id="mrs_01_0856__b434926115215">Instance Configuration</strong> tab page.<p id="mrs_01_0856__p16411357124914">Change the value of <strong id="mrs_01_0856__b20152153663911">yarn.nodemanager.local-dirs</strong> or <strong id="mrs_01_0856__b1152836183916">yarn.nodemanager.log-dirs</strong> to the new target directory.</p>
<p id="mrs_01_0856__p470116246463">For example, change the value of <strong id="mrs_01_0856__b13122182014216">yarn.nodemanager.local-dirs</strong> or <strong id="mrs_01_0856__b1012219200213">yarn.nodemanager.log-dirs</strong> to <strong id="mrs_01_0856__b1312322014213">/srv/BigData/data2/nm/containerlogs</strong>.</p>
</li><li id="mrs_01_0856__li74145714914">Click <strong id="mrs_01_0856__b8271132324139">Save Configuration</strong> and select <strong id="mrs_01_0856__b17469281134139">Restart the affected services or instances</strong>. Click <strong id="mrs_01_0856__b1210402694139">OK</strong> to restart the NodeManager instance.<p id="mrs_01_0856__p6411657104910">Click <strong id="mrs_01_0856__b23803473525">Finish</strong> when the system displays "Operation successful". The NodeManager instance is successfully started.</p>
</li></ol>
</p></li></ol>
<p id="mrs_01_0856__p629812359430">For versions earlier than MRS 3.<em id="mrs_01_0856__i198331446112318">x</em>, perform the following operations:</p>
<ol id="mrs_01_0856__o0c10229936384fd5b532087fbfcd094f"><li id="mrs_01_0856__l2aa0be5a3d764e51a3ce8100f4099765"><span>Check the environment.</span><p><ol type="a" id="mrs_01_0856__oaa5de429352e403293c7c36b07055fe0"><li id="mrs_01_0856__lbe4e5d3377974790a902825e246149a0">Log in to the MRS console. In the left navigation pane, choose <strong id="mrs_01_0856__b14899092024139">Clusters</strong> &gt; <strong id="mrs_01_0856__b1326027754139">Active Clusters</strong>, and click a cluster name. Choose <strong id="mrs_01_0856__b696343016271">Components </strong>and check whether health status of Yarn is <strong id="mrs_01_0856__b69711941162710">Good</strong>.<ul id="mrs_01_0856__uaff95dbb40df4a62b570a5a80942feab"><li id="mrs_01_0856__l19ed5e6880194574a9c0baae72fa5f81">If yes, go to <a href="#mrs_01_0856__la5078ba0645147aba6b90f071779368f">1.c</a>.</li><li id="mrs_01_0856__lc13dcd572de3432f9dd9e896c69fc110">If no, the Yarn status is unhealthy. Go to <a href="#mrs_01_0856__le3afaf4553c243db9a4849977eadb16f">1.b</a>.</li></ul>
</li><li id="mrs_01_0856__le3afaf4553c243db9a4849977eadb16f"><a name="mrs_01_0856__le3afaf4553c243db9a4849977eadb16f"></a><a name="le3afaf4553c243db9a4849977eadb16f"></a>Rectify the Yarn fault. No further action is required.</li><li id="mrs_01_0856__la5078ba0645147aba6b90f071779368f"><a name="mrs_01_0856__la5078ba0645147aba6b90f071779368f"></a><a name="la5078ba0645147aba6b90f071779368f"></a>Determine whether to change the storage directory of the NodeManager role or that of a single NodeManager instance:<ul id="mrs_01_0856__u6f5df9891a78463da9ec21f68951021b"><li id="mrs_01_0856__l4537604eb857471a9d9008c453936c20">To change the storage directory of the NodeManager role, go to <a href="#mrs_01_0856__le6194cc33c3d4e1f8c058a988180165c">2</a>.</li><li id="mrs_01_0856__l7fbdf9f02821422ba6ce5b84fe8ecdf1">To change the storage directory of a single NodeManager instance, go to <a href="#mrs_01_0856__l74bdf880464b4eb18f01531e8355e3c4">3</a>.</li></ul>
</li></ol>
</p></li><li id="mrs_01_0856__le6194cc33c3d4e1f8c058a988180165c"><a name="mrs_01_0856__le6194cc33c3d4e1f8c058a988180165c"></a><a name="le6194cc33c3d4e1f8c058a988180165c"></a><span>Change the storage directory of the NodeManager role.</span><p><ol type="a" id="mrs_01_0856__oab28ece3185344439ac71aa53f17db01"><li id="mrs_01_0856__l5c3da02f875d4c50969afa1aef1fb861">Choose <strong id="mrs_01_0856__b1412364514139">Clusters</strong> &gt; <strong id="mrs_01_0856__b1381252324139">Active Clusters</strong>, and click a cluster name. Choose <strong id="mrs_01_0856__b1342782111288">Components </strong>&gt; <strong id="mrs_01_0856__b69202382816">Yarn </strong>&gt; <strong id="mrs_01_0856__b1351514361287">Stop </strong>to stop the Yarn service.</li><li id="mrs_01_0856__l49f341258e344f1db4d9e70f86371e0b">Log in to the ECS server and go to each node where Yarn is installed as user <strong id="mrs_01_0856__b14620101317292">root</strong>. Perform the following operations:<ol class="substepthirdol" id="mrs_01_0856__o3348a30251604c20867497d0a1272f96"><li id="mrs_01_0856__l50007476d1c743ee8aa5341af59ca77d">Create a target directory.<p id="mrs_01_0856__a1d5d814e2ed04371afa4611a3c9fb69f"><a name="mrs_01_0856__l50007476d1c743ee8aa5341af59ca77d"></a><a name="l50007476d1c743ee8aa5341af59ca77d"></a>For example, to create the target directory <strong id="mrs_01_0856__b166155612393">${BIGDATA_DATA_HOME}/data2</strong>, run the following command:</p>
<p id="mrs_01_0856__afaf739dc12e84171a7e36686e93f8280"><strong id="mrs_01_0856__b3375175893910">mkdir ${BIGDATA_DATA_HOME}/data2</strong></p>
</li><li id="mrs_01_0856__l5b1ac5e5dd6c4f16bf6b91d2ca68baa2">Mount the target directory to the new disk.<p id="mrs_01_0856__ae428a635854747b080d3b5ae2f85f227"><a name="mrs_01_0856__l5b1ac5e5dd6c4f16bf6b91d2ca68baa2"></a><a name="l5b1ac5e5dd6c4f16bf6b91d2ca68baa2"></a>For example, mount <strong id="mrs_01_0856__b1049627104012">${BIGDATA_DATA_HOME}/data2</strong> to the new disk.</p>
</li><li id="mrs_01_0856__lc8c79f0ebe6a4e1186ed8c42c8139355">Modify permissions on the new directory.<p id="mrs_01_0856__a3623d170e7074e448901db2fb8c1b489"><a name="mrs_01_0856__lc8c79f0ebe6a4e1186ed8c42c8139355"></a><a name="lc8c79f0ebe6a4e1186ed8c42c8139355"></a>For example, to modify permissions on the <strong id="mrs_01_0856__b1928818139402">${BIGDATA_DATA_HOME}/data2</strong> directory, run the following commands:</p>
<p id="mrs_01_0856__a5b2727c0f7d14c6e933d4f5bcc6de8d4"><strong id="mrs_01_0856__b2084411718403">chmod 750 ${BIGDATA_DATA_HOME}/data2 -R</strong> and <strong id="mrs_01_0856__b158455178409">chown omm:wheel ${BIGDATA_DATA_HOME}/data2 -R</strong></p>
</li></ol>
</li><li id="mrs_01_0856__la39c731018f34139ad19c5f3e05f8366">On the MRS console, choose <strong id="mrs_01_0856__b14592111219306">Clusters</strong> &gt; <strong id="mrs_01_0856__b4592101213309">Active Clusters</strong> and click a cluster name. Choose <strong id="mrs_01_0856__b1750164163411">Components </strong>&gt; <strong id="mrs_01_0856__b672794263418">Yarn </strong>&gt; <strong id="mrs_01_0856__b174944153410">Instances</strong>. Select the NodeManager instance of the corresponding host. Choose <span class="filepath" id="mrs_01_0856__filepath5699646219400"><b>Instance Configuration</b></span> &gt; <span class="filepath" id="mrs_01_0856__filepath39859704202315"><b>All Configurations</b></span>.<p id="mrs_01_0856__a505008200726478a80afa5a0232f1d13">Change the value of <strong id="mrs_01_0856__b362516254403">yarn.nodemanager.local-dirs</strong> or <strong id="mrs_01_0856__b17625825184011">yarn.nodemanager.log-dirs</strong> to the new target directory.</p>
<p id="mrs_01_0856__p525812174618">For example, change the value of <strong id="mrs_01_0856__b9490182813218">yarn.nodemanager.local-dirs</strong> or <strong id="mrs_01_0856__b949052814214">yarn.nodemanager.log-dirs</strong> to <strong id="mrs_01_0856__b18491122813215">/srv/BigData/data2/nm/containerlogs</strong>.</p>
</li><li id="mrs_01_0856__l4bd3353c56fd45d2a9809d97733985c0">Click <strong id="mrs_01_0856__b2109654317">Save Configuration</strong>, select <strong id="mrs_01_0856__b952111815">Restart the affected services or instances</strong>, and click <strong id="mrs_01_0856__b1888694244">OK</strong> Restart the Yarn service.<p id="mrs_01_0856__a67032b56be884d318c95bc29bbc6366c">Click <strong id="mrs_01_0856__b755257849">Finish</strong> when the system displays "Operation successful". Yarn is successfully started. No further action is required.</p>
</li></ol>
</p></li><li id="mrs_01_0856__l74bdf880464b4eb18f01531e8355e3c4"><a name="mrs_01_0856__l74bdf880464b4eb18f01531e8355e3c4"></a><a name="l74bdf880464b4eb18f01531e8355e3c4"></a><span>Change the storage directory of a single NodeManager instance.</span><p><ol type="a" id="mrs_01_0856__ocf1f1cf1f98a4436b3210dd100b92619"><li id="mrs_01_0856__l42e6d4f1531e49e6a48f773075d0f325">Choose <strong id="mrs_01_0856__b20394221834139">Clusters</strong> &gt; <strong id="mrs_01_0856__b17709691224139">Active Clusters</strong>, and click a cluster name. Choose <strong id="mrs_01_0856__b166296233409">Components </strong>&gt; <strong id="mrs_01_0856__b19147725204017">Yarn </strong>&gt; <strong id="mrs_01_0856__b105421626104013">Instances</strong>. Select the NodeManager instance whose storage directory needs to be modified, and choose <strong id="mrs_01_0856__b15811183844016">More </strong>&gt; <strong id="mrs_01_0856__b98598442401">Stop Instance</strong>.</li><li id="mrs_01_0856__le351b2f6548f49f8bf988097ff0c2b53">Log in to the ECS and go to the NodeManager node as user <strong id="mrs_01_0856__b10986554111">root</strong>. Perform the following operations:<ol class="substepthirdol" id="mrs_01_0856__o59c6a7216524417a8e52fc7f39933e46"><li id="mrs_01_0856__l864c79b2815a47df8f5cc866aee309fe">Create a target directory.<p id="mrs_01_0856__ac72e893e8148412f9d2b24ac5f237d55"><a name="mrs_01_0856__l864c79b2815a47df8f5cc866aee309fe"></a><a name="l864c79b2815a47df8f5cc866aee309fe"></a>For example, to create the target directory <strong id="mrs_01_0856__b144621744164011">${BIGDATA_DATA_HOME}/data2</strong>, run the following command:</p>
<p id="mrs_01_0856__a6a6a32c4fb0e45a1988c5134ba21e0bd"><strong id="mrs_01_0856__b571013465400">mkdir ${BIGDATA_DATA_HOME}/data2</strong></p>
</li><li id="mrs_01_0856__l95a6f76050c14db3bb0d58bc177e5790">Mount the target directory to the new disk.<p id="mrs_01_0856__abe1e04563143494ca267c248416592ce"><a name="mrs_01_0856__l95a6f76050c14db3bb0d58bc177e5790"></a><a name="l95a6f76050c14db3bb0d58bc177e5790"></a>For example, mount <strong id="mrs_01_0856__b104395508400">${BIGDATA_DATA_HOME}/data2</strong> to the new disk.</p>
</li><li id="mrs_01_0856__lc959872dd69d4fa08d127e4c74311f16">Modify permissions on the new directory.<p id="mrs_01_0856__a2468dae5477647bd80edb78d067f46de"><a name="mrs_01_0856__lc959872dd69d4fa08d127e4c74311f16"></a><a name="lc959872dd69d4fa08d127e4c74311f16"></a>For example, to modify permissions on the <strong id="mrs_01_0856__b155758533406">${BIGDATA_DATA_HOME}/data2</strong> directory, run the following commands:</p>
<p id="mrs_01_0856__a4fa981be7f2a461985db497783cdaddd"><strong id="mrs_01_0856__b1257485812408">chmod 750 ${BIGDATA_DATA_HOME}/data2 -R</strong> and <strong id="mrs_01_0856__b6575458184015">chown omm:wheel ${BIGDATA_DATA_HOME}/data2 -R</strong></p>
</li></ol>
</li><li id="mrs_01_0856__l8189d641da72477395cc085c2fc92cca">On the MRS console, click the specified NodeManager instance and switch to the <strong id="mrs_01_0856__b12651035194119">Instance Configuration</strong> tab page.<p id="mrs_01_0856__a7cb69490d77a4a9ab17d7423db42e9f1">Change the value of <strong id="mrs_01_0856__b3489183164117">yarn.nodemanager.local-dirs</strong> or <strong id="mrs_01_0856__b1148915304110">yarn.nodemanager.log-dirs</strong> to the new target directory.</p>
<p id="mrs_01_0856__p925001364712">For example, change the value of <strong id="mrs_01_0856__b1560233015216">yarn.nodemanager.local-dirs</strong> or <strong id="mrs_01_0856__b156039301726">yarn.nodemanager.log-dirs</strong> to <strong id="mrs_01_0856__b1560473010214">/srv/BigData/data2/nm/containerlogs</strong>.</p>
</li><li id="mrs_01_0856__l472e9609e9894e5ca327f54aac8ae272">Click <strong id="mrs_01_0856__b317152667">Save Configuration</strong> and select <strong id="mrs_01_0856__b2081007464">Restart the affected services or instances</strong>. Click <strong id="mrs_01_0856__b810696515">OK</strong> to restart the NodeManager instance.<p id="mrs_01_0856__ac3e9f8c3ffb04b82a325b46515161fe9">Click <strong id="mrs_01_0856__b16721637084139">Finish</strong> when the system displays "Operation successful". The NodeManager instance is successfully started.</p>
</li></ol>
</p></li></ol>
<p id="mrs_01_0856__p1277805516506">For MRS 3.<em id="mrs_01_0856__i132342012233">x</em> or later, perform the following operations:</p>
<ol id="mrs_01_0856__ol1288412182514"><li id="mrs_01_0856__li198840183518"><span>Check the environment.</span><p><ol type="a" id="mrs_01_0856__ol118842186511"><li id="mrs_01_0856__li18884918185119">Log in to Manager, choose <strong id="mrs_01_0856__b16956584214">Cluster</strong> &gt; <em id="mrs_01_0856__i310018554212">Name of the desired cluster</em> &gt; <strong id="mrs_01_0856__b310010514210">Service</strong> to check whether <strong id="mrs_01_0856__b1110014594214">Running Status</strong> of Yarn is <strong id="mrs_01_0856__b131006584215">Normal</strong>.<ul id="mrs_01_0856__ul1888451845111"><li id="mrs_01_0856__li198841418145111">If yes, go to <a href="#mrs_01_0856__li988561895113">1.c</a>.</li><li id="mrs_01_0856__li388481810519">If no, the Yarn status is unhealthy. In this case, go to <a href="#mrs_01_0856__li18885518135118">1.b</a>.</li></ul>
</li><li id="mrs_01_0856__li18885518135118"><a name="mrs_01_0856__li18885518135118"></a><a name="li18885518135118"></a>Rectify faults of Yarn. No further action is required.</li><li id="mrs_01_0856__li988561895113"><a name="mrs_01_0856__li988561895113"></a><a name="li988561895113"></a>Determine whether to change the storage directory of the NodeManager role or that of a single NodeManager instance:<ul id="mrs_01_0856__ul158851018195120"><li id="mrs_01_0856__li5885171817511">To change the storage directory of the NodeManager role, go to <a href="#mrs_01_0856__li2885101825117">2</a>.</li><li id="mrs_01_0856__li288571875111">To change the storage directory of a single NodeManager instance, go to <a href="#mrs_01_0856__li1288531845117">3</a>.</li></ul>
</li></ol>
</p></li><li id="mrs_01_0856__li2885101825117"><a name="mrs_01_0856__li2885101825117"></a><a name="li2885101825117"></a><span>Change the storage directory of the NodeManager role.</span><p><ol type="a" id="mrs_01_0856__ol3885318205117"><li id="mrs_01_0856__li17885818195115">Choose <strong id="mrs_01_0856__b19051336205414">Cluster</strong> &gt; <em id="mrs_01_0856__i169051360543">Name of the desired cluster</em> &gt; <strong id="mrs_01_0856__b12906193611541">Service</strong> &gt; <strong id="mrs_01_0856__b290643645417">Yarn</strong> &gt; <strong id="mrs_01_0856__b7906536125419">Stop</strong> to stop the Yarn service.</li><li id="mrs_01_0856__li4885818135119">Log in to each data node where the Yarn service is installed as user <strong id="mrs_01_0856__b1088516183519">root</strong> and perform the following operations:<ol class="substepthirdol" id="mrs_01_0856__ol6885121845110"><li id="mrs_01_0856__li5885918105120">Create a target directory.<p id="mrs_01_0856__p1988551812518"><a name="mrs_01_0856__li5885918105120"></a><a name="li5885918105120"></a>For example, to create the target directory <strong id="mrs_01_0856__b110419184112">${BIGDATA_DATA_HOME}/data2</strong>, run the following command:</p>
<p id="mrs_01_0856__p1188561814519"><strong id="mrs_01_0856__b1481521104116">mkdir ${BIGDATA_DATA_HOME}/data2</strong></p>
</li><li id="mrs_01_0856__li13885161819514">Mount the target directory to the new disk.<p id="mrs_01_0856__p1088541815119"><a name="mrs_01_0856__li13885161819514"></a><a name="li13885161819514"></a>For example, mount <strong id="mrs_01_0856__b296072417414">${BIGDATA_DATA_HOME}/data2</strong> to the new disk.</p>
</li><li id="mrs_01_0856__li2885318155110">Modify permissions on the new directory.<p id="mrs_01_0856__p16885171811519"><a name="mrs_01_0856__li2885318155110"></a><a name="li2885318155110"></a>For example, to modify permissions on the <strong id="mrs_01_0856__b1439152915412">${BIGDATA_DATA_HOME}/data2</strong> directory, run the following commands:</p>
<p id="mrs_01_0856__p18851218145113"><strong id="mrs_01_0856__b13481153274111">chmod 750 ${BIGDATA_DATA_HOME}/data2 -R</strong> and <strong id="mrs_01_0856__b348143217412">chown omm:wheel ${BIGDATA_DATA_HOME}/data2 -R</strong></p>
</li></ol>
</li><li id="mrs_01_0856__li188531855110">On the Manager portal, choose <strong id="mrs_01_0856__b15561852153816">Cluster</strong> &gt; <em id="mrs_01_0856__i142113853919">Name of the desired cluster</em> &gt; <strong id="mrs_01_0856__b9258171763910">Services</strong> &gt; <strong id="mrs_01_0856__b9687202012391">Yarn</strong> &gt; <strong id="mrs_01_0856__b19626522123918">Instance</strong>. Select the NodeManager instance of the corresponding host, click <span class="filepath" id="mrs_01_0856__filepath188561816513"><b>Instance Configuration</b></span>, <span id="mrs_01_0856__text761292391813">and select </span><span class="filepath" id="mrs_01_0856__filepath1488501818518"><b>All Configurations</b></span>.<p id="mrs_01_0856__p488591885110">Change the value of <strong id="mrs_01_0856__b1423215381413">yarn.nodemanager.local-dirs</strong> or <strong id="mrs_01_0856__b102325388413">yarn.nodemanager.log-dirs</strong> to the new target directory.</p>
<p id="mrs_01_0856__p12526124615477">For example, change the value of <strong id="mrs_01_0856__b57702341021">yarn.nodemanager.local-dirs</strong> or <strong id="mrs_01_0856__b1777117342026">yarn.nodemanager.log-dirs</strong> to <strong id="mrs_01_0856__b37721134928">/srv/BigData/data2/nm/containerlogs</strong>.</p>
</li><li id="mrs_01_0856__li8885418125116">Click <strong id="mrs_01_0856__b9299268344139">Save</strong>, and then click <strong id="mrs_01_0856__b19327434294139">OK</strong>. Restart the Yarn service.<p id="mrs_01_0856__p1988514186518">Click <strong id="mrs_01_0856__b246015229556">Finish</strong> when the system displays "Operation successful". Yarn is successfully started. No further action is required.</p>
</li></ol>
</p></li><li id="mrs_01_0856__li1288531845117"><a name="mrs_01_0856__li1288531845117"></a><a name="li1288531845117"></a><span>Change the storage directory of a single NodeManager instance.</span><p><ol type="a" id="mrs_01_0856__ol8886118175112"><li id="mrs_01_0856__li1188611885113">Choose <strong id="mrs_01_0856__b356412517550">Cluster</strong> &gt; <em id="mrs_01_0856__i1456452545518">Name of the desired cluster</em> &gt; <strong id="mrs_01_0856__b956412512554">Service</strong> &gt; <strong id="mrs_01_0856__b15641725145516">Yarn</strong> &gt; <strong id="mrs_01_0856__b15565142510550">Instance</strong>, select the NodeManager instance whose storage directory needs to be modified, and choose <strong id="mrs_01_0856__b45658255552">More</strong> &gt; <strong id="mrs_01_0856__b1565025155516">Stop</strong>.</li><li id="mrs_01_0856__li68861418145112">Log in to the NodeManager node as user <strong id="mrs_01_0856__b188866180518">root</strong>, and perform the following operations:<ol class="substepthirdol" id="mrs_01_0856__ol1588612180514"><li id="mrs_01_0856__li188861218115120">Create a target directory.<p id="mrs_01_0856__p3886618105116"><a name="mrs_01_0856__li188861218115120"></a><a name="li188861218115120"></a>For example, to create the target directory <strong id="mrs_01_0856__b27591952204118">${BIGDATA_DATA_HOME}/data2</strong>, run the following command:</p>
<p id="mrs_01_0856__p58869186518"><strong id="mrs_01_0856__b2512175416413">mkdir ${BIGDATA_DATA_HOME}/data2</strong></p>
</li><li id="mrs_01_0856__li108863182513">Mount the target directory to the new disk.<p id="mrs_01_0856__p18886218155110"><a name="mrs_01_0856__li108863182513"></a><a name="li108863182513"></a>For example, mount <strong id="mrs_01_0856__b15655195784113">${BIGDATA_DATA_HOME}/data2</strong> to the new disk.</p>
</li><li id="mrs_01_0856__li1388691895120">Modify permissions on the new directory.<p id="mrs_01_0856__p5886218105113"><a name="mrs_01_0856__li1388691895120"></a><a name="li1388691895120"></a>For example, to modify permissions on the <strong id="mrs_01_0856__b33426119426">${BIGDATA_DATA_HOME}/data2</strong> directory, run the following commands:</p>
<p id="mrs_01_0856__p888612185513"><strong id="mrs_01_0856__b12983113164211">chmod 750 ${BIGDATA_DATA_HOME}/data2 -R</strong> and <strong id="mrs_01_0856__b129839315426">chown omm:wheel ${BIGDATA_DATA_HOME}/data2 -R</strong></p>
</li></ol>
</li><li id="mrs_01_0856__li1788612181511">On Manager, click the specified NodeManager instance, and switch to the <strong id="mrs_01_0856__b345215122716">Instance Configuration</strong> page.<p id="mrs_01_0856__p1488611817510">Change the value of <strong id="mrs_01_0856__b14962082422">yarn.nodemanager.local-dirs</strong> or <strong id="mrs_01_0856__b19719874215">yarn.nodemanager.log-dirs</strong> to the new target directory.</p>
<p id="mrs_01_0856__p139911324194812">For example, change the value of <strong id="mrs_01_0856__b113810388218">yarn.nodemanager.local-dirs</strong> or <strong id="mrs_01_0856__b1413812387214">yarn.nodemanager.log-dirs</strong> to <strong id="mrs_01_0856__b81395380217">/srv/BigData/data2/nm/containerlogs</strong>.</p>
</li><li id="mrs_01_0856__li1288614189518">Click <strong id="mrs_01_0856__b15192087104139">Save</strong>, and then click <strong id="mrs_01_0856__b13788783014139">OK</strong> to restart the NodeManager instance.<p id="mrs_01_0856__p6886101812514">Click <strong id="mrs_01_0856__b27617145619">Finish</strong> when the system displays "Operation successful". The NodeManager instance is successfully started.</p>
</li></ol>
</p></li></ol>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="mrs_01_0851.html">Using Yarn</a></div>
</div>
</div>