当前位置:网站首页>基于CenterOS7安装Redis及常见问题解决(带图讲解)
基于CenterOS7安装Redis及常见问题解决(带图讲解)
2022-06-10 22:29:00 【小钟要学习!!!】
基于CenterOS7安装Redis及常见问题解决
创建的两个安装问题请完下面看
1、下载安装包与安装
官方下载地址:https://redis.io/download/
直接在win平台上下载解压包然后上传到虚拟机再安装
直接点击版本进行下载压缩文件
在虚拟机上通过命令执行远程下载安装redis安装包
远程安装地址(版本自己选择)
wget http://download.redis.io/releases/redis-?.?.?.tar.gz如果提示
wget未找到命令的先执行下面的代码进行插件安装,安装完成会有提示,再次允许上面的下载地址yum -y install wget下载之后可以通过
ll命令查看当前目录的文件是否存在,这里是win下载上传的,然后解压文件定位到上传的文件夹,然后解压redis压缩包
tar –xvf 文件名.tar.gz解压文件之后,再次cd进入到解压的文件中查看文件目录,使用
ll目录![[外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传(img-6G0zeAE0-1654870578779)(images/image-20220610211618336.png)]](/img/cb/a5fc73f9789082590b51c493175211.png)
cat Makefile // 可以查看安装的位置如下 # Top level makefile, the real shit is at src/Makefile default: all .DEFAULT: cd src && $(MAKE) [email protected] install: cd src && $(MAKE) [email protected] .PHONY: install通过下面的语句编译安装(编译需要时间耐心等待,如果出现安装错误按照下面的步骤走)
make install如果按照成功,使用cd命令进入到安装目录src中,然后通过
ll命令查看是否安装成功,出现如下代表成功了![[外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传(img-c2LLk89B-1654870578780)(images/image-20220610212021820.png)]](/img/9d/99bbd3ef10c622e7abd22c4d4eef64.png)
安装报错请往下看
第一个错误就是上面提到的
-bash: wget: 未找到命令,已经解决第二个编译报错
gcc:命令未找到,执行下面的语句解决问题yum -y install gcc automake autoconf libtool make![[外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传(img-WlxMmi2W-1654870578780)(images/image-20220610212509954.png)]](/img/bd/d419af3d351e3e2b71781f5861d8f4.png)
第三个编译错误
zmalloc.h:50:31: 致命错误:jemalloc/jemalloc.h:没有那个文件或目录,执行下面的语句解决问题![[外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传(img-EeOIoN7r-1654870578781)(images/image-20220610212727871.png)]](/img/99/62de5b845664ba1ca3f5088f44a8f7.png)
注意:下面的语句需要在解压包的文件下执行(等于编译,需要花点时间)
make MALLOC=libc![[外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传(img-9LoxjKH2-1654870578782)(images/image-20220610213013211.png)]](/img/f9/e13dc79799f6f6e47913ba4db6d5d0.png)
启动src目录的
redis-server服务![[外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传(img-dKyicw2t-1654870578782)(images/image-20220610213130018.png)]](/img/19/5d804f2f376af356c338fdcfad6a82.png)
由于当前页面用来启动了redis服务器,所以不能执行命令了,需要复制一个标签
进入安装目录,然后启动
redis-cli,就可以操作了![[外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传(img-xpJeiv7o-1654870578783)(images/image-20220610213309106.png)]](/img/d3/8520dbf94c6e75414f42d043e557cd.png)
2、修改Redis端口
使用如下命令修改端口可以启动多个redis服务
redis-server --port 6380
启动客户端的时候也需要指定端口
redis-cli -p 6380
边栏推荐
- 上海证券开户是安全的吗?
- Wireshark抓取rtp负载ts流介绍(UDP组播)
- 300题 线代第一讲行列式
- Ma8601 pin √ pin replaces Tang Ming fe1.1s without changing the circuit board | perfectly replaces fe1.1s scheme
- Sealem Finance - a new decentralized financial platform based on Web3
- Is it safe to open an account in Shanghai Stock Exchange?
- Ride the storm and explore the secret behind the open source of flyfish, a data visualization development platform!
- [gmm+kde] target tracking simulation based on GMM and KDE kernel estimation of MATLAB
- [QPSK if] Verilog design of QPSK IF signal generation module based on FPGA
- Fiddler creates an autoresponder
猜你喜欢

Example analysis of SQL query optimization principle

Introduction to software testing: the concept and process of software testing (brilliant content)

PwnTheBox,Pwn:tutorial1

Prefer "big and small weeks", only write 200 lines of code every day, and the monthly salary of 8k-17k people will rise again

Is it too late to teach yourself programming at 28? Is it reliable?
![[QPSK if] Verilog design of QPSK IF signal generation module based on FPGA](/img/7d/b021790f1fde266ff9aa360261d581.png)
[QPSK if] Verilog design of QPSK IF signal generation module based on FPGA

已知某种木材的横纹抗压力服从N(x,d2),现对十个试件作横纹抗压力试验,得数据如下:(单位:kg/cm2)
![The shell script of pagoda plan task regularly deletes all files under a directory [record]](/img/dc/cfd449bf14c4545cd2e52bda4ab31e.png)
The shell script of pagoda plan task regularly deletes all files under a directory [record]

Laravel8 enables alicloud file upload

判等问题:如何确定程序的判断是正确的?
随机推荐
关于嵌入式音频开发需要注意的两个方面
【Flutter 问题系列第 6 篇】如何在 Flutter 中实现列表消息的滚动效果
执行Oracle的SQL语句报错【ORA-00904: “CREATETIME“: 标识符无效】、【ORA-00913: 值过多】解决办法
Build TAR model using beersales data set in TSA package
Openvp* integrated LDAP authentication
苹果CMS采集站源码-搭建教程-附带源码-全新源码-开发文档
mysql 表机制
PwnTheBox,Pwn:tutorial1
Is it safe for CICC Fortune Securities to open an account? Is it reliable?
Creation of thread pool
Is it safe to open an account for tongdaxin stock? How to open an account?
Solutions to the error reported by executing Oracle SQL statement [ora-00904: "createtime": invalid identifier] and [ora-00913: too many values]
Font spider Teaching -- ttf/otf font file compression
Two debugging techniques in embedded software development
Data and information resource sharing platform (VII)
【视频】KMEANS均值聚类和层次聚类:R语言分析生活幸福指数可视化|数据分享
Why is the video fusion cloud service easycvr cluster video event query invalid?
Postgraduate entrance examination English vocabulary unit1
LeetCode 501 :二叉搜索树中的众数
Exécuteur - shutdown, shutdown Now, awaittermination details and actual Fighting