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>
84 lines
14 KiB
HTML
84 lines
14 KiB
HTML
<a name="mrs_01_0853"></a><a name="mrs_01_0853"></a>
|
|
|
|
<h1 class="topictitle1">Creating Yarn Roles</h1>
|
|
<div id="body1590130746678"><div class="section" id="mrs_01_0853__sefb5491eb22b46b7ae6dcda52045fda3"><h4 class="sectiontitle">Scenario</h4><p id="mrs_01_0853__a8e029b35af464590ae99fad252f1aee9">This section describes how to create and configure a Yarn role. The Yarn role can be assigned with Yarn administrator permission and manage Yarn queue resources.</p>
|
|
<div class="note" id="mrs_01_0853__note497615453293"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="mrs_01_0853__p473939559">If the current component uses Ranger for permission control, you need to configure permission management policies based on Ranger. Refer to <a href="mrs_01_1859.html">Adding a Ranger Access Permission Policy for Yarn</a> for clusters of MRS 3.<em id="mrs_01_0853__i8529202519346">x</em> or later.</p>
|
|
</div></div>
|
|
</div>
|
|
<div class="section" id="mrs_01_0853__s9109011a40114834ab799887a7f9458b"><h4 class="sectiontitle">Prerequisites</h4><ul id="mrs_01_0853__ucce2c3562cf542d8bd7c6d4b86b5867b"><li id="mrs_01_0853__l1482596053a9478ca1437dc98de5bfae">The system administrator has understood the service requirements.</li><li id="mrs_01_0853__ldb37f3e226d94f048948d9d0ec99a32a">You have logged in to Manager.</li></ul>
|
|
</div>
|
|
<div class="section" id="mrs_01_0853__s6edf1022fe2241b2b83cddecf9d0e1e9"><h4 class="sectiontitle">Procedure</h4><p id="mrs_01_0853__p9259949998">For versions earlier than MRS 3.x, perform the following operations:</p>
|
|
<ol id="mrs_01_0853__od6201022c3414c8692ceac861d6ed6fa"><li id="mrs_01_0853__l7182476544614b9d97f84c0425555e18"><span>Choose <strong id="mrs_01_0853__b4824739125518">System</strong> > <strong id="mrs_01_0853__b148301739105511">Manage Role</strong> > <strong id="mrs_01_0853__b108311639105513">Create Role</strong>.</span></li><li id="mrs_01_0853__l98216fd9bd9c48c09cb042994c474d5e"><span>Click <strong id="mrs_01_0853__b94985814569">Create Role</strong> and fill in <strong id="mrs_01_0853__b145032895613">Role Name</strong> and <strong id="mrs_01_0853__b750312812564">Description</strong>.</span></li><li id="mrs_01_0853__l7ac2f61358d64c16a84bb18e5aaea518"><span>Set permissions. For details, see <a href="#mrs_01_0853__t5453ec62e4fa409ab89e13e8c65f7f7b">Table 1</a>.</span><p><p id="mrs_01_0853__a320314e7901e4063bd465e83f55e0003">Yarn permissions:</p>
|
|
<ul id="mrs_01_0853__ue9b498ff376248ab8bb108b9fbcf8755"><li id="mrs_01_0853__lf4bd3812a067449aac091f4f1f3b13f0"><strong id="mrs_01_0853__b727754518568">Cluster Admin Operations</strong>: Yarn administrator permissions.</li><li id="mrs_01_0853__l8526fa23f9dc4b61a359f750f2e47e3d"><strong id="mrs_01_0853__b19408168135710">Scheduler Queue</strong>: queue resources management .
|
|
<div class="tablenoborder"><a name="mrs_01_0853__t5453ec62e4fa409ab89e13e8c65f7f7b"></a><a name="t5453ec62e4fa409ab89e13e8c65f7f7b"></a><table cellpadding="4" cellspacing="0" summary="" id="mrs_01_0853__t5453ec62e4fa409ab89e13e8c65f7f7b" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Setting a role</caption><thead align="left"><tr id="mrs_01_0853__r1b483aabcac2421b9e5c5dd1cd737521"><th align="left" class="cellrowborder" valign="top" width="26.26%" id="mcps1.3.3.3.3.2.2.2.2.2.3.1.1"><p id="mrs_01_0853__a28a08feb938144c698eb23b16aa72258">Task</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="73.74000000000001%" id="mcps1.3.3.3.3.2.2.2.2.2.3.1.2"><p id="mrs_01_0853__ad444bcbe25e84f17a7ebe278a43a323f">Operation</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="mrs_01_0853__rb7a95f62aa9d4cc1bfbdf54340c3997d"><td class="cellrowborder" valign="top" width="26.26%" headers="mcps1.3.3.3.3.2.2.2.2.2.3.1.1 "><p id="mrs_01_0853__ae0370d9982834c21bd3fd01d37e8e519">Setting the Yarn administrator permission</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="73.74000000000001%" headers="mcps1.3.3.3.3.2.2.2.2.2.3.1.2 "><p id="mrs_01_0853__a62f81c5410ee4308a7e35477df827957">In the <strong id="mrs_01_0853__b233833214571">Permission</strong> table, click <strong id="mrs_01_0853__b43431327575">Yarn</strong> and select <strong id="mrs_01_0853__b13343163275718">Cluster Admin Operations</strong>.</p>
|
|
<div class="note" id="mrs_01_0853__nfc66ef39a6af41759a6fd817585c2641"><span class="notetitle"> NOTE: </span><div class="notebody"><p id="mrs_01_0853__a5ea050d3cb25478d8f3ef657dd4c4db7">The Yarn service needs to be restarted to set the Yarn administrator permission so that the saved role configuration can take effect.</p>
|
|
</div></div>
|
|
</td>
|
|
</tr>
|
|
<tr id="mrs_01_0853__r22bbd4ec3d1b4ad8b6bfc60fd3fc61e1"><td class="cellrowborder" valign="top" width="26.26%" headers="mcps1.3.3.3.3.2.2.2.2.2.3.1.1 "><p id="mrs_01_0853__a1cdc441186674095ab125a083daa694d">Setting the permission for a user to submit tasks in a specified Yarn queue</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="73.74000000000001%" headers="mcps1.3.3.3.3.2.2.2.2.2.3.1.2 "><ol type="a" id="mrs_01_0853__o30e243cdf97449148c36d93dc1a03a37"><li id="mrs_01_0853__l1c2a51286aec453ca3e9493b64fcf22d">In the <strong id="mrs_01_0853__b192021806581">Permission</strong> table, choose <strong id="mrs_01_0853__b820720025817">Yarn</strong> > <strong id="mrs_01_0853__b1520710017587">Scheduler Queue</strong>.</li><li id="mrs_01_0853__lf5abf3930e0743339a133949b7c9ac3b">In the <strong id="mrs_01_0853__b76431312145812">Permission</strong> column of the specified queue, select <strong id="mrs_01_0853__b16648512105815">Submit</strong>.</li></ol>
|
|
</td>
|
|
</tr>
|
|
<tr id="mrs_01_0853__r3297e0a39f084a7ca7b97fda8d77b4f1"><td class="cellrowborder" valign="top" width="26.26%" headers="mcps1.3.3.3.3.2.2.2.2.2.3.1.1 "><p id="mrs_01_0853__af0e7fec78a8d49c4ad2c94f35ff679f9">Setting the permission for a user to manage tasks in a specified Yarn queue</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="73.74000000000001%" headers="mcps1.3.3.3.3.2.2.2.2.2.3.1.2 "><ol type="a" id="mrs_01_0853__ob76d86eb5b2d489f9518f378477e71e1"><li id="mrs_01_0853__l94826ae0e275488ca2e717890737037a">In the <strong id="mrs_01_0853__b82223145818">Permission</strong> table, choose <strong id="mrs_01_0853__b1852320587">Yarn</strong> > <strong id="mrs_01_0853__b3862345815">Scheduler Queue</strong>.</li><li id="mrs_01_0853__l1b279b06224b4d1c979bebcecf12c436">In the <strong id="mrs_01_0853__b1476212254587">Permission</strong> column of the specified queue, select <strong id="mrs_01_0853__b167671725115810">Admin</strong>.</li></ol>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</li></ul>
|
|
<p id="mrs_01_0853__p1766875511475">If the Yarn role contains the <strong id="mrs_01_0853__b117294294542643">Submit</strong> or <strong id="mrs_01_0853__b85749208142643">Manage</strong> permission of a parent queue, the sub-queue inherits the permission by default, that is, the <strong id="mrs_01_0853__b91224021342643">Submit</strong> or <strong id="mrs_01_0853__b182788743642643">Manage</strong> permission is automatically added for the sub-queue. Permissions inherited by sub-queues will not be displayed as selected in the <strong id="mrs_01_0853__b771613413196">Configure Resource Permission</strong> table.</p>
|
|
<p id="mrs_01_0853__p15600153013810">If you select only the <strong id="mrs_01_0853__b65964157342643">Submit</strong> permission of a parent queue when setting the Yarn role, you need to manually specify the queue name when submitting tasks as a user with the permission of this role. Otherwise, when the parent queue has multiple sub-queues, the system does not automatically determine the queue to which the task is submitted and therefore submits the task to the <strong id="mrs_01_0853__b13234064742643">default</strong> queue.</p>
|
|
</p></li><li id="mrs_01_0853__l0a7e37e1d8354b7a8d7a468e78556f05"><span>Click <strong id="mrs_01_0853__b193289715942643">OK</strong>.</span></li></ol>
|
|
<p id="mrs_01_0853__p54461939171011">For MRS 3.<em id="mrs_01_0853__i3420144517584">x</em> or later, perform the following operations:</p>
|
|
<ol id="mrs_01_0853__ol14354162191110"><li id="mrs_01_0853__li335411211115"><span>Choose System > Permission > Role.</span></li><li id="mrs_01_0853__li735417212111"><span>Click <strong id="mrs_01_0853__b15821117642643">Create Role</strong> and set a role name and enter description.</span></li><li id="mrs_01_0853__li9354152191119"><span>Refer <a href="#mrs_01_0853__table16354521181114">Table 2</a> to configure resource permissions for roles.</span><p><p id="mrs_01_0853__p1435432141118">Yarn permissions:</p>
|
|
<ul id="mrs_01_0853__ul6354321201115"><li id="mrs_01_0853__li1035462161114">Cluster management: Yarn administrator permissions.</li><li id="mrs_01_0853__li173541321101113">Queue scheduling: queue resource management.
|
|
<div class="tablenoborder"><a name="mrs_01_0853__table16354521181114"></a><a name="table16354521181114"></a><table cellpadding="4" cellspacing="0" summary="" id="mrs_01_0853__table16354521181114" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Setting a role</caption><thead align="left"><tr id="mrs_01_0853__row23541921121117"><th align="left" class="cellrowborder" valign="top" width="26.26%" id="mcps1.3.3.5.3.2.2.2.1.2.3.1.1"><p id="mrs_01_0853__p63541921131118">Task</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="73.74000000000001%" id="mcps1.3.3.5.3.2.2.2.1.2.3.1.2"><p id="mrs_01_0853__p103541821171118">Operation</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="mrs_01_0853__row7355112171119"><td class="cellrowborder" valign="top" width="26.26%" headers="mcps1.3.3.5.3.2.2.2.1.2.3.1.1 "><p id="mrs_01_0853__p035562161115">Setting the Yarn administrator permission</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="73.74000000000001%" headers="mcps1.3.3.5.3.2.2.2.1.2.3.1.2 "><p id="mrs_01_0853__p19355621191118">In the <strong id="mrs_01_0853__b114798420042643">Configure Resource Permission</strong> table, choose <em id="mrs_01_0853__i48244243942643">Name of the desired cluster</em> > <strong id="mrs_01_0853__b43185574042643">Yarn</strong> > <strong id="mrs_01_0853__b162598795742643">Cluster Management</strong>.</p>
|
|
<div class="note" id="mrs_01_0853__note23551212116"><span class="notetitle"> NOTE: </span><div class="notebody"><p id="mrs_01_0853__p173551521111110">The Yarn service needs to be restarted to set the Yarn administrator permission so that the saved role configuration can take effect.</p>
|
|
</div></div>
|
|
</td>
|
|
</tr>
|
|
<tr id="mrs_01_0853__row20355192131110"><td class="cellrowborder" valign="top" width="26.26%" headers="mcps1.3.3.5.3.2.2.2.1.2.3.1.1 "><p id="mrs_01_0853__p12355172191115">Setting the permission for a user to submit tasks in a specified Yarn queue</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="73.74000000000001%" headers="mcps1.3.3.5.3.2.2.2.1.2.3.1.2 "><ol type="a" id="mrs_01_0853__ol235562101118"><li id="mrs_01_0853__li173557213118">In the <strong id="mrs_01_0853__b74669424842643">Configure Resource Permission</strong> table, choose <em id="mrs_01_0853__i103931464542643">Name of the desired cluster</em> > <strong id="mrs_01_0853__b134418330242643">Yarn</strong> > <strong id="mrs_01_0853__b64483984442643">Scheduling Queue</strong> > <strong id="mrs_01_0853__b12558179942643">root</strong>.</li><li id="mrs_01_0853__li1935582151114">In the <strong id="mrs_01_0853__b145147948942643">Permission</strong> column of the specified queue, select <strong id="mrs_01_0853__b58870693442643">Submit</strong>.</li></ol>
|
|
</td>
|
|
</tr>
|
|
<tr id="mrs_01_0853__row1235592111111"><td class="cellrowborder" valign="top" width="26.26%" headers="mcps1.3.3.5.3.2.2.2.1.2.3.1.1 "><p id="mrs_01_0853__p6355192119111">Setting the permission for a user to manage tasks in a specified Yarn queue</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="73.74000000000001%" headers="mcps1.3.3.5.3.2.2.2.1.2.3.1.2 "><ol type="a" id="mrs_01_0853__ol173551221111118"><li id="mrs_01_0853__li63556218111">In the <strong id="mrs_01_0853__b207217126442643">Configure Resource Permission</strong> table, choose <em id="mrs_01_0853__i100580288242643">Name of the desired cluster</em> > <strong id="mrs_01_0853__b69560254942643">Yarn</strong> > <strong id="mrs_01_0853__b18535024242643">Scheduling Queue</strong> > <strong id="mrs_01_0853__b172778312042643">root</strong>.</li><li id="mrs_01_0853__li10355321111110">In the <strong id="mrs_01_0853__b16262425642643">Permission</strong> column of the specified queue, select <strong id="mrs_01_0853__b7840339442643">Manage</strong>.</li></ol>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</li></ul>
|
|
<p id="mrs_01_0853__p135542118119">If the Yarn role contains the <strong id="mrs_01_0853__b94522093642643">Submit</strong> or <strong id="mrs_01_0853__b21838672342643">Manage</strong> permission of a parent queue, the sub-queue inherits the permission by default, that is, the <strong id="mrs_01_0853__b65341761142643">Submit</strong> or <strong id="mrs_01_0853__b209861024642643">Manage</strong> permission is automatically added for the sub-queue. Permissions inherited by sub-queues will not be displayed as selected in the <strong id="mrs_01_0853__b11444324181914">Configure Resource Permission</strong> table.</p>
|
|
<p id="mrs_01_0853__p193558212114">If you select only the <strong id="mrs_01_0853__b157676835542643">Submit</strong> permission of a parent queue when setting the Yarn role, you need to manually specify the queue name when submitting tasks as a user with the permission of this role. Otherwise, when the parent queue has multiple sub-queues, the system does not automatically determine the queue to which the task is submitted and therefore submits the task to the <strong id="mrs_01_0853__b133552998642643">default</strong> queue.</p>
|
|
</p></li><li id="mrs_01_0853__li10355162111115"><span>Click <strong id="mrs_01_0853__b195202197542643">OK</strong>.</span></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>
|
|
|