当前位置:网站首页>linux install redis using script
linux install redis using script
2022-07-29 22:15:00 【little brother】
1. If you have installed it, please uninstall it first
1. Check if redis is running
ps aux | grep redis
2. If redis is running, remove it by killing the reids processClose, you can see from the red box above that the redis process PID is 1112
# kill -9 PIDkill -9 1112After closing the process, check again, redis has stopped running
3. Enter the following command to stop the redis-server service
redis-cli shutdown4. View the redis installation directory
whereis redis
5. Delete the redis installation package
rm -rf /usr/bin/redisrm -rf /usr/local/redis
6. Check if redis is deleted

2. Install
This time I use redis script to install redis
1. First upload the redis installation package and installation script to the specified location, and give executable permission to the script file
chmod 777 -R Redis_Install.sh
2. Run the script and wait for installation
./Redis_Install.shSuccessful installation
3. Error (error) NOAUTH Authentication required
When we operate on the redis client in the virtual machine, the following error (error) NOAUTH Authentication required occurs, because redis sets a password, we needUse the password to authenticate and then operate the redis client, otherwise we do not have permission to operate the redis cache database.
auth 'your password'
3. Test external connection
When trying to connect externally to the redis server just installed, we found that the connection timed out.We can end by closing the Linux firewall or specifying port 6379 for development.
3.1, close the firewall
1. Check the firewalld status. If it is in the dead status, the firewall is not enabled.If it is active, it is on.
systemctl status firewalld
2. Turn off firewall
#Close the firewallsystemctl stop firewalld#Open firewall commandsystemctl start firewalld3.2. When the firewall is turned on, develop the specified port 6379
firewall-cmd --permanent --zone=public --add-port=6379/tcp
边栏推荐
猜你喜欢

全景教程丨VR全景拍摄如何拍摄日出和日落的场景?

高通WLAN框架学习(31)-- Power save

给图片左上角加logo标识、左下角加时间和地址、地址到达指定长度换行

爽朗的一天

378. The Kth Smallest Element in an Ordered Matrix

一文理解分布式开发中的服务治理

In 2022, you still can't "low code"?Data science can also play with Low-Code!

Dry goods!Cooperative Balance in Federated Learning

程序员自由工作的三大痛点?一文教你统统解决

MySQL Data Query - Simple Query
随机推荐
HMS Core音频编辑服务音源分离与空间音频渲染,助力快速进入3D音频的世界
转:idea中language level设置
AI全流程开发难题破解之钥
4. Implementation Guide for GET_ENTITYSET Method of SAP ABAP OData Service Data Provider Class
940. 不同的子序列 II
MySQL - 设计游戏用户信息表
In 2022, you still can't "low code"?Data science can also play with Low-Code!
The cornerstone of distributed: reliability - What a tangled web we weave
240. 搜索二维矩阵 II
MySQL数据查询 - 简单查询
爽朗的一天
对不起,你很难赚到中年人的钱
笔记:fgets函数详解
336. 回文对
给图片左上角加logo标识、左下角加时间和地址、地址到达指定长度换行
赶紧进来!!!带你认识C语言基本数据类型
OneNote 教程,如何在 OneNote 中做笔记?
Verilog 加法器设计
华为畅享50 Pro评测:HarmonyOS加持 更流畅更安全
仿Modbus消息帧进行通信