Connecting to Clusters Using Visualization Tools
UClickhouse can connect to instances through third-party client tools. For scenarios requiring data visualization operations, you can use the commonly used DataGrip tool to connect to the cluster for data operations. Below are the steps and examples for connecting to a cluster using the DataGrip tool.
Introduction to DataGrip
DataGrip is JetBrains’ database IDE, which supports connections to Clickhouse. This tool offers ClickHouse syntax highlighting, supports ClickHouse-specific features such as nested columns and table engines, and allows data editing.
Introduction to Connecting Cluster Database via SSH Tunnel
Note:
1: A Linux host that can be directly connected via SSH is required, and the network of this host and the UClickhouse instance must be mutually accessible.
2: Log in to the UCloud Global console and view the Data Warehouse UClickhouse List . Click on details to see the node information of the target instance.
Steps
-
Download the DataGrip tool according to your local operating system type. Official download address: Download DataGrip . Install it after downloading.
-
Open DataGrip and create a ClickHouse data source, as shown below.
-
Download the system’s default driver before filling in connection information, as shown below.
-
For security reasons, UClickHouse instances do not support direct public network connections, so DataGrip needs to connect to UClickHouse instance nodes via an SSH channel. The way DataGrip connects to UClickHouse nodes via SSH is shown below.
(1) First, switch to the “SSH/SSL” page, use SSH to connect to the prepared cloud host. If a private key file is used to log in to the cloud host, select Key pair (OpenSSH or PuTTY) for Auth type.
(2) Switch back to the “General” page and enter the corresponding information of the cluster node on this page. (Click Test Connection) as shown below.
Node information acquisition: Log in to the UCloud Global console and view the Data Warehouse UClickhouse List . Click on details to see the node information of the target instance.
-
Once connected, you can use this database in the connection list for the operations you need.
Field Descriptions:
1: General page parameter description
Parameter | Description |
---|---|
host | IP address of the UClickhouse cluster node |
port | 8123 |
user | Admin username, default is admin |
password | The admin password set when creating the cluster |
2: SSH/SSL page parameter description
Parameter | Description |
---|---|
host | Linux host that can be directly connected via SSH, and the network of this host and the UClickhouse instance is mutually accessible |
port | 22 |
user | Login username, default is root |
Authentication type | If logging into the cloud host with a private key file, select Key pair (OpenSSH or PuTTY) for Auth type. If logging into the cloud host with a password, select Password for Auth type |