Redis異常總結(持續收集中)

  1. telnet: connect to address 192.168.240.131: Connection refused解決:關閉linux防火牆,記得要關閉開機啓動,如何關閉請參考,配置:-bash : xxx : command not found 新安裝Linux後,安裝一些必須軟件(持續更新……)

  2. Could not connect to Redis at 192.168.240.131:6379: Connection refused解決:需要將redis.conf中的bind 127.0.0.1註釋掉,這樣纔不是唯一隻綁定本地訪問。

  3. 成功連接後,操作時會報錯:
    (error) DENIED Redis is running in protected mode because protected mode is enabled, no bind address 
    was specified, no authentication password is requested to clients. In this mode connections are only 
    accepted from the loopback interface. If you want to connect from external computers to Redis you may 
    adopt one of the following solutions: 1) Just disable protected mode sending the command 
    'CONFIG SET protected-mode no' from the loopback interface by connecting to Redis from the same host 
    the server is running, however MAKE SURE Redis is not publicly accessible from internet if you do so. 
    Use CONFIG REWRITE to make this change permanent. 2) Alternatively you can just disable the protected 
    mode by editing the Redis configuration file, and setting the protected mode option to 'no', and then 
    restarting the server. 3) If you started the server manually just for testing, restart it with the 
    '--protected-mode no' option. 4) Setup a bind address or an authentication password. NOTE: You only need 
    to do one of the above things in order for the server to start accepting connections from the outside.
    解決:'CONFIG SET protected-mode no'這句很明顯,我們需要將redis.conf中的protected-mode改爲no



  4. Cannot deserialize; nested exception is org.springframework.core.serializer.support.SerializationFailedException: 
    Failed to deserialize payload. Is the byte array a result of corresponding serialization for DefaultDeserializer?; 
    nested exception is java.io.EOFException

    解決:這個異常是因爲序列化和反序列化異常導致的,通常是因爲你在redis服務器上手動序列化存儲了一個值,然後在代理中進行反序列化獲取時報錯了。最好就是存取都在代碼中完成。
  5. ……

  6. ……

  7. ……

  8. ……

發佈了85 篇原創文章 · 獲贊 102 · 訪問量 94萬+
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章