-
Hi All, I am getting the following error when performing a restore operation:
We are running 'clickhouse' on physical linux machines. The clickhouse is running under the 'clickhouse' user. I downloaded clickhouse-backup from the releases page and extracted the tar.gz file. These are the steps I took to perform a restore operation manually via the cli interface (config file is set via environment variable):
I found another similar discussion here, however it looks like there they were running both clickhouse and clickhouse-backup as docker containers. The issue seems to be similar however. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
sorry for late reply which is your environment? |
Beta Was this translation helpful? Give feedback.
-
I found the root cause of the issue. I was running 'clickhouse-backup' tool under the In order to successfully run under the
Now restore works properly and I no longer get the permission denied error. PS: Thank you @hodgesrm for your clue/suggestion which helped me narrow down my search. The thread that helped me debug this was ClickHouse/ClickHouse#20280. |
Beta Was this translation helpful? Give feedback.
I found the root cause of the issue. I was running 'clickhouse-backup' tool under the
root
user in our standalone Linux machines. As a result ClickHouse did not have the correct permissions to the parts file to re-attach them during restore process.In order to successfully run under the
clickhouse
user (used byclickhouse-server
process) I had to make the following modifications:sudo su
(I had root access to our Linux server)vim /etc/passwd
- This is the Linux file containing all the user accounts and their defaults.clickhouse
user details. Modify\bin\false
to\bin\bash
. This allowed me to execute thesudo su - clickhouse
command in bash (allows logging in asclickhouse
u…