Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Why CH always restart automatically after killing it? #16254

Closed
y45398jp123 opened this issue Oct 22, 2020 · 4 comments
Closed

Why CH always restart automatically after killing it? #16254

y45398jp123 opened this issue Oct 22, 2020 · 4 comments
Labels
question Question?

Comments

@y45398jp123
Copy link

I found that CH server can always restart itself in about half a minute after stopping it, or killing it.
Is there any backgound process to keep the CH server alive?
I tried to remove the file from /etc/init.d/clickhouse-server, but the problem occurs.
Actually, It's not a problem, just wondering why...
Thanks.

@y45398jp123 y45398jp123 added the question Question? label Oct 22, 2020
@MeteHanC
Copy link
Contributor

I think this is about the unit file of ClickHouse (for ubuntu, filepath is : /etc/systemd/system/clickhouse-server.service)

Under the Service section you can see the following lines ;

Restart=always
RestartSec=30

So this is not actually a ClickHouse specific thing

@Inasayang
Copy link

systemd

@y45398jp123
Copy link
Author

Got it, thanks a lot.

@den-crane
Copy link
Contributor

for initV systems it's a cron-job.

# cat /etc/cron.d/clickhouse-server
*/10 * * * * root (which service > /dev/null 2>&1 && (service clickhouse-server condstart ||:)) || /etc/init.d/clickhouse-server condstart > /dev/null 2>&1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Question?
Projects
None yet
Development

No branches or pull requests

4 participants