Skip to main content

Create a Hive data source

Add Hive to NineData for Database DevOps, backup and recovery, data replication, and database comparison workflows.

Before you begin

  • The server IP address of NineData has been added to the data source allowlist. The server IP address can be viewed by selecting the target region in Access Region on the Create Datasource page.

    server_ip_address

  • Make sure data source quota is available; otherwise, the data source cannot be added. Check the remaining quota in the NineData Console header.check_quota

Procedure

  1. Sign in to the NineData Console.

  2. On the left navigation pane, click Datasource > Datasource.

  3. Select the Datasource tab, and then select Create Datasource. In the data source type selector, choose Database > (the type of data source to be added). On the Create Datasource page, configure the parameters based on the table below.
    tip

    If you make a mistake during the operation, select the arrow_down icon at the top of the Create Datasource page and choose again.

  1. Configure the data source parameters:

    Parameter
    Description
    NameEnter a meaningful data source name for future search and management.
    ConnectionSelect how NineData connects to the data source. Options include IP Address, Gateway, and SSH Tunnel.
    • IP Address: Connect through a public network address.
    • Gateway: Connect through a NineData gateway. Connect the host where the data source runs first. For setup steps, see Add Gateway.
    • SSH Tunnel: Connect through an SSH tunnel.
    Select how NineData connects to the data source. Options include IP Address and SSH Tunnel.
    • IP Address: Connect through a public network address.
    • SSH Tunnel: Connect through an SSH tunnel.
    Configuration items when Connection is IP AddressHost: Enter the public connection address and port of the data source. Click Add HDFS Connection next to this field to open the HDFS Connection Info area, where you enter HDFS connection information. After HDFS is configured, data exchange between NineData and Hive bypasses Hive, which improves data transfer performance.
    Configuration items when Connection is Gateway
    • Gateway: Select the NineData gateway installed on the host where the data source is located.
    • Host: Use localhost if the data source is on the same host, or enter the internal IP address of the host where the data source is located. Click Add HDFS Connection next to this field to open the HDFS Connection Info area, where you enter HDFS connection information. After HDFS is configured, data exchange between NineData and Hive bypasses Hive, which improves data transfer performance.
    Configuration items when Connection is SSH Tunnel
    • SSH Host: Enter the public IP address or domain name of the server where the target data source is located, and enter the SSH port. The default SSH port is 22.
    • SSH Authentication Method: Select the SSH authentication method.
      • Password: Connect with SSH Username (server login name) and Password (server login password).
        • SSH Username: Enter the login username of the server where the target data source is located.
        • Password: Enter the login password of the server where the target data source is located.
      • Key (recommended): Connect with SSH Username and Key File.
        • SSH Username: Enter the login username of the server where the target data source is located.
        • Key File: Click Upload to upload the private key file. The private key file has no file extension. If you have not created one, see Generate SSH Tunnel Key File.
        • Password: Enter the passphrase set when the key file was generated. If no passphrase was set, leave this field blank.
    • Note: After configuring SSH, click Connection Test. The test has two possible results:
      • Connection Successfully: The SSH tunnel is connected.
      • Error message: The connection failed. Troubleshoot the issue and try again.
    • Host: Use localhost if the data source is on the same host, or enter the internal IP address of the host where the data source is located. Click Add HDFS Connection next to this field to open the HDFS Connection Info area, where you enter HDFS connection information. After HDFS is configured, data exchange between NineData and Hive bypasses Hive, which improves data transfer performance.
    Authentication MethodSelect the authentication method for Hive.
    • No Auth: Connect without authentication.
    • Kerberos: Select this option if Kerberos authentication is enabled in Hive. Then enter User and upload krb5.cnf File and Keytab File.
    • CUSTOM: Use a custom HiveServer2 authentication mechanism. When this option is selected, NineData shows account and password fields.
    Access RegionIf the selected authentication mode requires credentials, enter the credentials for HiveServer2 authentication. Select the region closest to the data source to reduce network latency.
    EnvironmentSelect the environment that matches the business purpose of the data source. NineData provides PROD and DEV by default. Custom environments are supported. For details, see create custom environments.
    Note: In organization mode, database environments can also be used for permission policy management. For example, the default Prod Admin role can access only data sources in PROD. For more information, see Manage Roles.
  2. After you configure all parameters, click Connection Test next to Create Datasource to test connectivity. When Connection Successfully is displayed, click Create Datasource to create the data source. Otherwise, review the connection settings and run the test again.

Result

The Hive data source is added to NineData and can be used by supported features such as data replication, database comparison, and Database DevOps.