[Yandex Cloud documentation](../../index.md) > [Yandex Managed Service for ClickHouse®](../index.md) > FAQ > Connection

# Connecting to ClickHouse®

* [Can I connect to individual ClickHouse® hosts?](#connect-node)

* [Is it possible to specify any port for inter-server communication when executing distributed requests?](#connect-port)

* [Why cannot I connect to a host from the internet?](#fail-connection)

* [How do I connect to a non-public host in Yandex Cloud?](#private-host)

* [Can I connect to a public cluster without SSL?](#without-ssl)

* [Why do I get an `UNEXPECTED_PACKET_FROM_SERVER` error when trying to connect?](#unexpected-packet)

* [Can I connect to cluster hosts over SSH or get superuser privileges on hosts?](#connect-ssh)

* [What should I do if I get a revocation check error when obtaining an SSL certificate via PowerShell?](#get-ssl-error)

#### Can I connect to individual ClickHouse® hosts? {#connect-node}

Yes. You can connect to ClickHouse® cluster hosts:

* Using the [HTTPS interface](https://clickhouse.com/docs/enen/interfaces/http):
    * Via an encrypted SSL connection on port 8443.
    * Without encryption on port 8123.

* Using the [command-line client](https://clickhouse.com/docs/enen/interfaces/cli):
    * Via an encrypted SSL connection on port 9440.
    * Without encryption on port 9000.

SSH connections are not supported.

#### Can I specify a custom port for inter-server communication when running distributed queries? {#connect-port}

Managed Service for ClickHouse® uses the native/TLS protocol on port 9440 for inter-server communication when running distributed queries. There is no option to change the protocol or port.

#### Why cannot I connect to a host from the internet? {#fail-connection}

Most likely, no public access is enabled for your cluster, so you can only connect to it from a VM in Yandex Cloud. You can only request public access when [creating a new host](../concepts/network.md#public-access-to-a-host) in your cluster.

#### How do I connect to a non-public host in Yandex Cloud? {#private-host}

[Connect](../operations/connect/clients.md) to a host from a Yandex Cloud VM residing in the same cloud network, or [add](../operations/hosts.md#add-host) a new publicly accessible host to the cluster and use it to connect to the non-public host.

#### Can I connect to a public cluster without SSL? {#without-ssl}

No. You can only connect to public hosts over SSL. For more information, see [this guide](../operations/connect/index.md).

#### Why do I get an `UNEXPECTED_PACKET_FROM_SERVER` error when trying to connect? {#unexpected-packet}

Here is the full text of the error:

```text
Code: 102. DB::NetException:
Unexpected packet from server <host_FQDN>.mdb.yandexcloud.net:9440
(expected Hello or Exception, got Unknown packet)
```

This error occurs when you try to connect to a ClickHouse® host on port 9440 without encryption. You can only connect on port 9440 over an encrypted SSL connection.

Make sure to specify the `--secure` parameter when connecting on port 9440.

To learn more about connection methods, see [Connecting to a ClickHouse® cluster](../operations/connect/clients.md).

#### Can I connect to cluster hosts over SSH or get superuser privileges on them? {#connect-ssh}

You cannot connect to hosts via SSH. This is done for the sake of security and user cluster fault tolerance because direct changes inside a host can render it completely inoperable.

#### What should I do if I get a revocation check error when obtaining an SSL certificate via PowerShell? {#get-ssl-error}

Complete error message:

```text
curl: (35) schannel: next InitializeSecurityContext failed: Unknown error (0x80092012)
The revocation function was unable to check revocation for the certificate
```
This means that, when connecting to the website, the function was unable to check if its certificate was listed as revoked.

To fix this error:

* Make sure your corporate network policies are not blocking the verification.
* Run the following command with the `--ssl-no-revoke` parameter:

    ```powershell
    mkdir -Force $HOME\.yandex; `
    curl.exe https://storage.yandexcloud.net/cloud-certs/RootCA.pem `
      --ssl-no-revoke `
      --output $HOME\.yandex\RootCA.crt; `
    curl.exe https://storage.yandexcloud.net/cloud-certs/IntermediateCA.pem `
      --ssl-no-revoke `
      --output $HOME\.yandex\IntermediateCA.crt; `
    Import-Certificate `
      -FilePath $HOME\.yandex\RootCA.crt `
      -CertStoreLocation cert:\CurrentUser\Root; `
    Import-Certificate `
      -FilePath $HOME\.yandex\IntermediateCA.crt `
      -CertStoreLocation cert:\CurrentUser\Root
    ```

_ClickHouse® is a registered trademark of [ClickHouse, Inc](https://clickhouse.com)._