How can I stop redis-server?

前端 未结 26 1871
清歌不尽
清歌不尽 2020-12-07 06:51

I apparently have a redis-server instance running because when I try to start a new server by entering redis-server, I\'m greeted with the followin

26条回答
  •  渐次进展
    2020-12-07 07:11

    If you know on which port(default:6379) your redis server is running you can go with option 1 or you can check your redis process and you can kill with option 2

    option 1:
    Kill process on port:

    check     : sudo lsof -t -i:6379
    kill      : sudo kill `sudo lsof -t -i:6379`
    

    option 2:
    Find the previously Running Redis Server:

     ps auxx | grep redis-server
    

    Kill the specific process by finding PID (Process ID) - Redis Sever

    kill -9 PID
    

    Now start your redis server with

    redis-server /path/to/redis.conf 
    

提交回复
热议问题