0

Not able to login to clickhouse.Can any one please look into it.

root@ubuntu:~# clickhouse-client ClickHouse client version 20.8.2.3 (official build). Connecting to localhost:9000 as user default. Code: 516. DB::Exception: Received from localhost:9000. DB::Exception: default: Authentication failed: password is incorrect or there is no user with such name.

Aneesh Babu
  • 91
  • 1
  • 2
  • 4
  • Does this answer your question? [New to ClickHouse, can't create local host](https://stackoverflow.com/questions/60864973/new-to-clickhouse-cant-create-local-host) – vladimir Sep 15 '20 at 17:12

2 Answers2

2

there are 3 possible reasons:

  1. network restriction (in CH auth for this user).
  2. no user with such name
  3. password is incorrect

If you just installed CH , then you can edit/remove /etc/clickhouse-server/users.d/default-password.xml . This file stores the password you entered during CH installation.

Denny Crane
  • 11,574
  • 2
  • 19
  • 30
  • I voted for this one but its also helpful to read [Vladimir's comment](https://stackoverflow.com/questions/60864973/new-to-clickhouse-cant-create-local-host) Removing the file does no harm. On WSL2 I had to log in as the root user to do so. – MilleCodex Mar 24 '22 at 03:19
-3

It's simple: do not use localhost / 127.0.0.1 but use external address

0ri0n
  • 1
  • the problem Aneesh Babu is describing is related to to authentication, not to the TCP connection. Notice the "DB::Exception: Received from localhost:9000.", this means the server was started OK. – Tzach Solomon Nov 15 '20 at 11:04