Stop redis server. Neither shutdown nor stop works

后端 未结 16 777
深忆病人
深忆病人 2021-01-31 08:43

I want to stop the redis server and it just keeps going and going. I am using redis-2.6.7

Check that it is running:

redis-server

It say

16条回答
  •  轻奢々
    轻奢々 (楼主)
    2021-01-31 08:59

    The normal way of doing this is to connect to a client like redis-cli and execute "shutdown" command. I've found some issues trying to shutdown because redis-server doesn't have right permissions to edit db dump file (RDB) prior to quit. Then redis remains started and you have to kill the process with kill -9 pid. But this is not a redis problem as you may know.

    Example of this problem:

    # User requested shutdown...
    [16560] 10 Sep 11:21:17.672 * Saving the final RDB snapshot before exiting.
    [16560] 10 Sep 11:21:17.672 # Failed opening .rdb for saving: Permission denied
    [16560] 10 Sep 11:21:17.672 # Error trying to save the DB, can't exit.
    

提交回复
热议问题