1. Home
  2. Knowledge Base
  3. ClickHouse DBA
  4. Troubleshooting issues while starting the clickhouse-server
  1. Home
  2. Knowledge Base
  3. ClickHouse Troubleshooting
  4. Troubleshooting issues while starting the clickhouse-server

Troubleshooting issues while starting the clickhouse-server

Host OS: Ubuntu 22.04

ClickHouse version:


Using the pre-compiled packages is the recommended way for installing ClickHouse. The ClickHouse Server is configured to run as a systemd service and it will automatically start with every host OS reboot. Failures can happen while starting the ClickHouse as systemd service or after a reboot. Possible solutions for such scenarios are discussed in this article.

Scenario 1:

ClickHouse server won’t start as a service (even by manually executing sudo service clickhouse-server start) but can be run by invoking clickhouse-server from the terminal.

Possible Root Cause: ClickHouse folders have incorrect permissions

Steps to troubleshoot:

  • Check the systemd logs using the below command ina terminal window
sudo journalctl -u clickhouse-server


  • Check if a similar error message is displayed (Access to file denied: /var/lib/clickhouse*)


  • Change the ownership of the following directories to Clickhouse user instead of other users (root)
sudo chown -R clickhouse /var/lib/clickhouse /var/log/clickhouse-server /etc/clickhouse-server /etc/clickhouse-client


  • Start the server and verify the status using the below commands
sudo service clickhouse-server start
sudo service clickhouse-server status


  • Now, the server should be started as a service. The expected output is below.


Scenario 2:

ClickHouse server is not started automatically after every reboot, but the service can be started manually using sudo service clickhouse-server start command.

Possible Root Cause: ClickHouse service is disabled

Steps to Troubleshoot

  • Run the following command after the host OS reboot
sudo service clickhouse-server status


  • The service status is shown as disabled (similar to below).


  • Re-enable Clickhouse systems service
sudo systemctl enable clickhouse-server.service


  • Reload systemd services
sudo systemctl daemon-reload service


  • Reload the clickhouse server and the service should run even after reboot.
sudo clickhouse-server restart



This article will be updated as and when new issues are encountered and solved.




Was this article helpful?

Related Articles


In the spirit of freedom, independence and innovation. ChistaDATA Corporation is not affiliated with ClickHouse Corporation 

Need Support?

Can't find the answer you're looking for?
Contact Support

ChistaDATA Inc. Knowledge base is licensed under the Apache License, Version 2.0 (the “License”)

Copyright 2022 ChistaDATA Inc

Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at


Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.