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

18 lines
4.0 KiB
HTML

<a name="mrs_01_0967"></a><a name="mrs_01_0967"></a>
<h1 class="topictitle1">Writing a Directory into Hive with the Old Data Removed to the Recycle Bin</h1>
<div id="body1590395285087"><div class="section" id="mrs_01_0967__section115171931164213"><h4 class="sectiontitle">Scenario</h4><p id="mrs_01_0967__p1161761917420">This function applies to Hive.</p>
<p id="mrs_01_0967__p26171819447">After this function is enabled, run the following command to write a directory into Hive: <strong id="mrs_01_0967__b4747817111311">insert overwrite directory "</strong><em id="mrs_01_0967__i2499103161313">/</em><em id="mrs_01_0967__i17972691313">path1</em><strong id="mrs_01_0967__b167483176139">"</strong><strong id="mrs_01_0967__b1985314735910"> ...</strong>. After the operation is successfully performed, the old data is removed to the recycle bin, and the directory cannot be an existing database path in the Hive metastore.</p>
<ol id="mrs_01_0967__ol181811550174911"><li id="mrs_01_0967__li1658372875814"><span>The Hive service configuration page is displayed.</span><p><ul id="mrs_01_0967__ul175831228125814"><li id="mrs_01_0967__li1458392810583">For versions earlier than MRS 1.9.2, log in to MRS Manager, choose <strong id="mrs_01_0967__b7942571440">Services</strong> &gt; <strong id="mrs_01_0967__b119418572419">Hive</strong> &gt; <strong id="mrs_01_0967__b1951757549">Service Configuration</strong>, and select <strong id="mrs_01_0967__b11953571046">All</strong> from the <strong id="mrs_01_0967__b17961757542">Basic</strong> drop-down list.</li><li id="mrs_01_0967__li25841828135815">For MRS 1.9.2 or later, click the cluster name on the MRS console, choose <strong id="mrs_01_0967__b209013584417">Components</strong> &gt; <strong id="mrs_01_0967__b119024588415">Hive</strong> &gt; <strong id="mrs_01_0967__b69021458243">Service Configuration</strong>, and select <strong id="mrs_01_0967__b2903958347">All</strong> from the <strong id="mrs_01_0967__b390320583411">Basic</strong> drop-down list.<div class="note" id="mrs_01_0967__note73070488542"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="mrs_01_0967__p18867134116400">If the <strong id="mrs_01_0967__b14415171010593">Components</strong> tab is unavailable, complete IAM user synchronization first. (On the <strong id="mrs_01_0967__b1541520108590">Dashboard</strong> page, click <strong id="mrs_01_0967__b194161210205917">Synchronize</strong> on the right side of <span class="parmname" id="mrs_01_0967__parmname16416910115910"><b>IAM User Sync</b></span> to synchronize IAM users.)</p>
</div></div>
</li><li id="mrs_01_0967__li1675864017574">For MRS 3.<em id="mrs_01_0967__i18788101554">x</em> or later, log in to FusionInsight Manager. For details, see <a href="mrs_01_2124.html">Accessing FusionInsight Manager (MRS 3.x or Later)</a>. And choose <strong id="mrs_01_0967__b126298119519">Cluster</strong> &gt; <em id="mrs_01_0967__i2630711557">Name of the desired cluster</em> &gt; <strong id="mrs_01_0967__b166311911355">Services</strong> &gt; <strong id="mrs_01_0967__b1063116112511">Hive</strong> &gt; <strong id="mrs_01_0967__b19632916515">Configurations</strong> &gt; <strong id="mrs_01_0967__b96321611353">All Configurations</strong>.</li></ul>
</p></li><li id="mrs_01_0967__li051003218413"><span>Choose <strong id="mrs_01_0967__b1556544314315">HiveServer(Role)</strong> &gt; <strong id="mrs_01_0967__b1156619438439">Customization</strong>, add a customized parameter to the <strong id="mrs_01_0967__b19566134384315">hive-site.xml</strong> parameter file, set <strong id="mrs_01_0967__b9567104324315">Name</strong> to <strong id="mrs_01_0967__b205679433433">hive.overwrite.directory.move.trash</strong>, and set <strong id="mrs_01_0967__b1156734314313">Value</strong> to <strong id="mrs_01_0967__b1256844319435">true</strong>. Restart all Hive instances after the modification.</span></li></ol>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="mrs_01_0581.html">Using Hive</a></div>
</div>
</div>