Inserting Data to a Directory That Does Not Exist
Scenario
This function applies to Hive.
With this function enabled, run the insert overwrite directory /path1/path2/path3... command to write a subdirectory. The permission of the /path1/path2 directory is 700, and the owner is the current user. If the /path3 directory does not exist, it is automatically created and data is written successfully.
This function is supported when hive.server2.enable.doAs is set to true in earlier versions. This version supports the function when hive.server2.enable.doAs is set to false.
The parameter adjustment of this function is the same as that of the custom parameters added in Writing a Directory into Hive with the Old Data Removed to the Recycle Bin.
Procedure
- The Hive service configuration page is displayed.
- For versions earlier than MRS 3.x, click the cluster name. On the cluster details page that is displayed, choose Components > Hive > Service Configuration, and select All from the Basic drop-down list.
If the Components tab is unavailable, complete IAM user synchronization first. (On the Dashboard page, click Synchronize on the right side of IAM User Sync to synchronize IAM users.)
- For MRS 3.x or later, log in to FusionInsight Manager. For details, see Accessing FusionInsight Manager (MRS 3.x or Later). And choose Cluster > Name of the desired cluster > Services > Hive > Configurations > All Configurations.
- For versions earlier than MRS 3.x, click the cluster name. On the cluster details page that is displayed, choose Components > Hive > Service Configuration, and select All from the Basic drop-down list.
- Choose HiveServer(Role) > Customization, add a customized parameter to the hive-site.xml parameter file, set Name to hive.overwrite.directory.move.trash, and set Value to true. Restart all Hive instances after the modification.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot