Frank
Frank

Reputation: 97

Connection refused after installing clickhouse on Ubuntu 16.04

I installed clickhouse per the instructions on the clickhouse site, but when I run clickhouse-client I get connection refused:

root@guest:~# clickhouse-client
ClickHouse client version 1.1.54198.
Connecting to localhost:9000.
Code: 210. DB::NetException: Connection refused: (localhost:9000, 127.0.0.1)

The server appears to be running:

root@guest:~# systemctl status clickhouse-server.service 
● clickhouse-server.service - LSB: Yandex clickhouse-server daemon
   Loaded: loaded (/etc/init.d/clickhouse-server; bad; vendor preset: enabled)
   Active: active (exited) since Tue 2017-04-04 01:41:48 EDT; 28min ago
     Docs: man:systemd-sysv-generator(8)

Update: it seems the clickhouse server can't find everything it needs:

root@guest:~# /etc/init.d/clickhouse-server condstart
Start clickhouse-server service: Include not found: clickhouse_remote_servers
Include not found: clickhouse_compression
Path to data directory in /etc/clickhouse-server/config.xml: /var/lib/clickhouse/
No directory, logging in with HOME=/
DONE

Is there a problem with the Ubuntu 16.04 packages?

Upvotes: 2

Views: 7919

Answers (1)

Frank
Frank

Reputation: 97

Turns out the default config tries to bind to ipv6 address [::1]:

<Error> Application: Net Exception: Cannot assign requested address: [::1]:8123

Removing the relevant line from /etc/clickhouse-server/config.xml fixed it.

Upvotes: 6

Related Questions