当前位置:网站首页>Redis cannot connect remotely.
Redis cannot connect remotely.
2022-07-03 05:34:00 【youandme520】
CentOS9 Installed on redis, And successfully started , Unable to connect on the host .
Mainly parameter setting Incorrect .
First, install by default redis after Direct command start redis-server It's not true . It will call the default parameters to start redis.
We need to use it. redis.conf File to start
redis-server /etc/redis/redis.confThere are several reasons why you can't connect .
1. bind Parameters are not set correctly
redis bind The default parameter is 127.0.0.1 This way redis Bound to local and its The external device cannot be connected
We need to comment it out directly .
# bind 127.0.0.1
then modify redis The protection mode of is no, Is not enabled
protected-mode noFor the sake of safety You need to set the password
requirepass rootthen Can Remote access to
We try to connect on the client

Still unable to connect , Think about it Should be CentOS9 Firewall does not 6379 Ports open .
[[email protected] redis]# firewall-cmd --query-port=6379/tcp
noIt really didn't open after inspection
Then we open the port .
[[email protected] redis]# firewall-cmd --add-port=6379/tcp
success
[[email protected] redis]# firewall-cmd --query-port=6379/tcp
yesAfter opening the port, we are connecting with the client

Successful connection , solve the problem .
边栏推荐
- study hard and make progress every day
- Go practice -- closures in golang (anonymous functions, closures)
- AtCoder Beginner Contest 258(A-D)
- Apache+PHP+MySQL环境搭建超详细!!!
- 小学校园IP网络广播-基于校园局域网的小学IP数字广播系统设计
- Bluebridge cup real topic 2020 palindrome date simulation construction provincial competition
- Redis使用Lua脚本简介
- Redis breakdown penetration avalanche
- 期末复习(Day2)
- kubernetes资源对象介绍及常用命令(五)-(ConfigMap)
猜你喜欢

Skip table: principle introduction, advantages and disadvantages of skiplist

Altaro set grandfather parent child (GFS) archiving

Classification and discussion of plane grab detection methods based on learning

XML Configuration File

Deep embedding and alignment of Google | protein sequences

Overview of basic knowledge of C language

Go practice -- factory mode of design patterns in golang (simple factory, factory method, abstract factory)

@Autowired 导致空指针报错 解决方式

小学校园IP网络广播-基于校园局域网的小学IP数字广播系统设计

大二困局(复盘)
随机推荐
2022.7.2day594
"250000 a year is just the price of cabbage" has become a thing of the past. The annual salary of AI posts has decreased by 8.9%, and the latest salary report has been released
Latest version of source insight
Detailed explanation of yolov5 training own data set
Interview question -- output the same characters in two character arrays
Configure and use Anaconda environment in pycharm
ROS Compilation Principle
Overview of basic knowledge of C language
Classification and discussion of plane grab detection methods based on learning
SimpleITK学习笔记
Source insight automatic installation and licensing
redis 遇到 NOAUTH Authentication required
Redis使用Lua脚本简介
Make your own dataset
ES 2022 正式发布!有哪些新特性?
6.23 warehouse operation on Thursday
"C and pointer" - Chapter 13 function of function pointer 1 - callback function 1
BIO、NIO、AIO区别
2022.DAY592
请求数据库报错:“could not extract ResultSet; SQL [n/a]; nested exception is org.hibernate.exception.SQLGram