What is the proper way to shut down sentinel

1,702 views
Skip to first unread message

nfwlpw

unread,
Nov 1, 2013, 1:32:48 PM11/1/13
to redi...@googlegroups.com
For regular redis-server you can shut it down with 'redis-cli -p 6379 shutdown'.  But when I tried that with the sentinel it complained that there's no such command:

# redis-cli -h localhost -p 26379 shutdown
(error) ERR unknown command 'shutdown'

Josiah Carlson

unread,
Nov 5, 2013, 5:50:15 PM11/5/13
to redi...@googlegroups.com
Because Redis Sentinel is not storing any data that really needs, you should be able to kill it without worry.

 - Josiah


--
You received this message because you are subscribed to the Google Groups "Redis DB" group.
To unsubscribe from this group and stop receiving emails from it, send an email to redis-db+u...@googlegroups.com.
To post to this group, send email to redi...@googlegroups.com.
Visit this group at http://groups.google.com/group/redis-db.
For more options, visit https://groups.google.com/groups/opt_out.

Andy Bowes

unread,
Feb 7, 2014, 5:10:41 AM2/7/14
to redi...@googlegroups.com
Even though Sentinel doesn't actually store any data it could be part way through a failover process which is updating configuration files.
Is there a more elegant way of requesting a shutdown without forceably killing the Sentinel process?  Ideally I would like something similar to the 'shutdown' command which can be executed via the client.

- Andy

Salvatore Sanfilippo

unread,
Feb 7, 2014, 5:23:12 AM2/7/14
to Redis DB
Hello Andy, I just added SHUTDOWN to Sentinel (unstable/2.8 branch, so
you'll find it in 2.8.6).
Thanks for the feedback.

Salvatore
--
Salvatore 'antirez' Sanfilippo
open source developer - GoPivotal
http://invece.org

To "attack a straw man" is to create the illusion of having refuted a
proposition by replacing it with a superficially similar yet
unequivalent proposition (the "straw man"), and to refute it
-- Wikipedia (Straw man page)

Andy Bowes

unread,
Feb 7, 2014, 5:35:25 AM2/7/14
to redi...@googlegroups.com
Thanks Salvatore,  that's what I call service :)



--
You received this message because you are subscribed to a topic in the Google Groups "Redis DB" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/redis-db/IJrkpfq8nG0/unsubscribe.
To unsubscribe from this group and all its topics, send an email to redis-db+u...@googlegroups.com.

Andy Bowes

unread,
Feb 12, 2014, 6:39:21 AM2/12/14
to redi...@googlegroups.com
Is it possible to specify a PID file when starting the Redis Server in Sentinel mode?

I tried using the standard config option in the sentinel.conf file but it seems to be ignored.
pidfile /var/run/redis_sentinel_26379.pid

Is there any other way to do this?  The availability of the PID file would enable us to slot Sentinel into our existing automated management process with scripts that are v similar to thoise used to manage Redis.

Thanks
Andy
Reply all
Reply to author
Forward
0 new messages