溫馨提示×

溫馨提示×

您好,登錄后才能下訂單哦!

密碼登錄×
登錄注冊×
其他方式登錄
點擊 登錄注冊 即表示同意《億速云用戶服務條款》

redis啟動,停止,及端口占用處理方法

發(fā)布時間:2020-10-10 06:30:54 來源:腳本之家 閱讀:306 作者:澄海單挑狂 欄目:數(shù)據(jù)庫

啟動

進入etc目錄下 啟動redis

sudo ../bin/redis-server ./redis.conf

停止 ./redis-cli shutdown 注釋:這里關閉默認端口號 ./redis-cli -h 127.0.0.1 -p 7001 shutdown 注釋:關閉指定端口號 實時查看日志 tail -f /usr/local/redis/log-redis.log //----------------端口占用問題處理 $ ps aux | grep redis Find the port that its running on.. In my case..

MyUser 8821 0.0 0.0 2459704 596 ?? S 4:54PM 0:03.40 redis-server *:6379

And then close the port manually

$ kill -9 8821

Re-run redis

$ redis-server
//------------------同一臺機器啟動多個實例redis
Sorry, the cluster configuration file nodes.conf is already used by a different Redis Cluster node. Please make sure that differen t nodes use different cluster configuration files.
需要在
redis.conf配置文件中配置
cluster-config-file nodes.conf
為不同名稱

以上這篇redis啟動,停止,及端口占用處理方法就是小編分享給大家的全部內容了,希望能給大家一個參考,也希望大家多多支持億速云。

向AI問一下細節(jié)

免責聲明:本站發(fā)布的內容(圖片、視頻和文字)以原創(chuàng)、轉載和分享為主,文章觀點不代表本網(wǎng)站立場,如果涉及侵權請聯(lián)系站長郵箱:is@yisu.com進行舉報,并提供相關證據(jù),一經查實,將立刻刪除涉嫌侵權內容。

AI