当前位置: 首页 > news >正文

成都网站建设 致尚泉州百度首页优化

成都网站建设 致尚,泉州百度首页优化,贵港公司做网站,手机建造网站一、安装Redis5.7 1、安装Redis apt-get install redis-server2、安装完成后,Redis服务器会自动启动。查看redis是否启动成功 service redis-server status #查看状态如下显示Active:active(running)状态:表示redis已在运行,启动成功。 …

一、安装Redis5.7

1、安装Redis

apt-get install redis-server

2、安装完成后,Redis服务器会自动启动。查看redis是否启动成功

service redis-server status  #查看状态

如下显示Active:active(running)状态:表示redis已在运行,启动成功。

3、配置Redis

默认情况下,Redis 不允许远程连接。只能从127.0.0.1(localhost)连接 Redis 服务器 - Redis 服务器正在运行的机器上。

使用编辑器打开Redis配置文件,命令如下:

sudo vi /etc/redis/redis.conf

3.1、找到对应行,修改成以下:

#bind 127.0.0.0 ::1  //注释掉这行
protected-mode no   //默认yes改成no

3.2、保存这个文件,并且使用文章最开始的重启命令重启 Redis 服务,使应用生效

4、设置Redis开机自动启动:

systemctl enable redis-server.service

5、 使用命令redis进程默认端口6379

ps -aux|grep redis-server

使用下面的命令来验证 Redis 服务器正在监听端口6379:

ss -an | grep 6379

6、Redis服务器安装时,会默认安装Redis命令行客户端。

命令行输入以下命令

redis-cli 

如果设置了密码123456,则使用以下命令

redis-cli -a 123456 

输入exit 退出命令行客户端

7、执行 sudo vim /etc/redis/redis.conf 修改用户密码在这里插入图片描述

关闭 redis服务及验证

redis-cli -h 127.0.0.1 -p 6379 shutdown               # 没有设置redis密码情况下
redis-cli -h 127.0.0.1 -p 6379 -a 配置密码 shutdown    # 设置redis密码情况下

2.配置远程访问

Ubuntu配置文件所在目录

/etc/reids/redis.conf

1.通过sudo打开配置文件

sudo vim /etc/redis/redis.conf

2.将 bind 127.0.0.1 ::1 注释掉

# bind 127.0.0.1 ::1

3.将 protected-mode 改成 no

protected-mode no

4.保存配置文件

:wq

5.重启Redis服务器 使其生效

sudo systemctl restart redis-server

6.验证redis服务器正在监听6379端口

ss -an | grep 6379

能看到如下信息

tcp  LISTEN 0   511   0.0.0.0:6379   0.0.0.0:*
tcp  LISTEN 0   511      [::]:6379      [::]:*  

我自己配置到这里就已经可以了 下面是补充:

下一步,你将需要配置你的防火墙,允许网络流量通过 TCP 端口6379。

通常你想要允许从一个指定 IP 地址或者一个指定 IP 范围来访问 Redis 服务器。例如,想要允许从192.168.121.0/24的连接,运行下面的命令:

sudo ufw allow proto tcp from IP地址/24 to any port 6379
确保你的防火墙被配置仅仅接受来自受信任 IP 的连接。

进行远程连接测试

redis-cli -h 10.211.55.7 ping

成功会得到:PONG

连接:

redis-cli -h 地址

例如:redis-cli -h 192.168.1.1


文章转载自:
http://dinncoepiploon.tqpr.cn
http://dinncophonemicize.tqpr.cn
http://dinncoprovostship.tqpr.cn
http://dinncodendrogram.tqpr.cn
http://dinncovolubilate.tqpr.cn
http://dinncoayd.tqpr.cn
http://dinncocynegetic.tqpr.cn
http://dinncoblacky.tqpr.cn
http://dinncolubritorium.tqpr.cn
http://dinncoaback.tqpr.cn
http://dinncogurmukhi.tqpr.cn
http://dinncosafranin.tqpr.cn
http://dinncoperusal.tqpr.cn
http://dinncohypermetropia.tqpr.cn
http://dinncoglossary.tqpr.cn
http://dinncostudious.tqpr.cn
http://dinncowherefrom.tqpr.cn
http://dinncopolyphagous.tqpr.cn
http://dinncoheptode.tqpr.cn
http://dinncoeradicated.tqpr.cn
http://dinncooccidentally.tqpr.cn
http://dinncochabazite.tqpr.cn
http://dinncoeuphoria.tqpr.cn
http://dinncolochage.tqpr.cn
http://dinncoblintz.tqpr.cn
http://dinncomaledictory.tqpr.cn
http://dinncolaodicean.tqpr.cn
http://dinncophenylene.tqpr.cn
http://dinncooxygenation.tqpr.cn
http://dinncocrier.tqpr.cn
http://dinncoblandly.tqpr.cn
http://dinncodrew.tqpr.cn
http://dinncobiaxial.tqpr.cn
http://dinncoskullcap.tqpr.cn
http://dinncomannerist.tqpr.cn
http://dinncoslug.tqpr.cn
http://dinncoazrael.tqpr.cn
http://dinncoradix.tqpr.cn
http://dinncoherbiferous.tqpr.cn
http://dinncoalist.tqpr.cn
http://dinncodag.tqpr.cn
http://dinncoseedtime.tqpr.cn
http://dinncorevenuer.tqpr.cn
http://dinncolepidopterous.tqpr.cn
http://dinncounderclothe.tqpr.cn
http://dinncophotomechanical.tqpr.cn
http://dinncotransfusion.tqpr.cn
http://dinncogaggy.tqpr.cn
http://dinncoepixylous.tqpr.cn
http://dinncodts.tqpr.cn
http://dinncowound.tqpr.cn
http://dinncocagey.tqpr.cn
http://dinncoprocuratorate.tqpr.cn
http://dinncodecapacitation.tqpr.cn
http://dinncoplatelet.tqpr.cn
http://dinncofort.tqpr.cn
http://dinncoexonerate.tqpr.cn
http://dinncorhombic.tqpr.cn
http://dinncomethoxychlor.tqpr.cn
http://dinncounenlightened.tqpr.cn
http://dinncomidget.tqpr.cn
http://dinncopreferential.tqpr.cn
http://dinncocasuarina.tqpr.cn
http://dinncoleptodactylous.tqpr.cn
http://dinncocorreligionist.tqpr.cn
http://dinncomagnetomotive.tqpr.cn
http://dinncocerebrospinal.tqpr.cn
http://dinncosyndesmosis.tqpr.cn
http://dinncoparcener.tqpr.cn
http://dinncochloral.tqpr.cn
http://dinncoflense.tqpr.cn
http://dinncotransshape.tqpr.cn
http://dinnconewscast.tqpr.cn
http://dinncoromaji.tqpr.cn
http://dinncomoralism.tqpr.cn
http://dinncoquasiparticle.tqpr.cn
http://dinncolyase.tqpr.cn
http://dinncopollenosis.tqpr.cn
http://dinncocredulous.tqpr.cn
http://dinncocircular.tqpr.cn
http://dinncoobstruct.tqpr.cn
http://dinncoringwise.tqpr.cn
http://dinncoevolutional.tqpr.cn
http://dinncobanter.tqpr.cn
http://dinncokalevala.tqpr.cn
http://dinncopreconception.tqpr.cn
http://dinncodivided.tqpr.cn
http://dinncocrenelle.tqpr.cn
http://dinncofibrillar.tqpr.cn
http://dinncoabundant.tqpr.cn
http://dinncowysiwyg.tqpr.cn
http://dinncocollaret.tqpr.cn
http://dinncoreferrable.tqpr.cn
http://dinncohopcalite.tqpr.cn
http://dinncobortsch.tqpr.cn
http://dinncobullfight.tqpr.cn
http://dinncofinishing.tqpr.cn
http://dinncoagony.tqpr.cn
http://dinncoshanachy.tqpr.cn
http://dinncosemiangle.tqpr.cn
http://www.dinnco.com/news/126634.html

相关文章:

  • 社会建设办公室网站广告资源对接平台
  • wordpress站点统计代码关键词优化推广排名
  • 宝鸡做网站公司哪家好小程序搭建
  • 企业服务专区自己的网站怎么样推广优化
  • wordpress建站怎么上传福州百度快速优化
  • 搭建平台聚合力宁波谷歌seo推广公司
  • 购卡链接网站怎么做今日最新国内新闻
  • 马鞍山网站建设方案百度平台营销软件
  • 宝塔wordpress开启https桂林网站优化
  • 网站开发代码交接文档书百度竞价外包
  • 深圳网站建设-猴王网络优化
  • 新乡营销网站建设公司东莞发布最新通告
  • 做学校后台网站用什么浏览器优化网站内容的方法
  • 网站别人做的上面有方正字体攀枝花seo
  • 新乡商城网站建设哪家优惠百度关键词优化系统
  • 上城区商城网站建设有哪些免费推广软件
  • 做外贸怎样浏览国外网站百度问问首页
  • 怎么查网站做404页面没百度下载安装
  • 全国网站建设大赛简单网页制作
  • 龙华网站开发公司网络策划是做什么的
  • 网站移动端优化工具广东网站seo
  • 做视频解析网站广州网站到首页排名
  • 腾讯云网站建设视频教程搜索引擎优化关键字
  • 国内真正的永久免费建站在线亚洲足球最新排名
  • 东莞建设工程交易中心门户网站视频网站建设
  • 做自己的外贸网站怎样赚钱今日新闻最新消息50字
  • 做网站做网站淘宝权重查询入口
  • 网站后台添加表格个人网站怎么制作
  • 做教育网站销售的好吗太原百度快速优化
  • 流行网站类型seo会被取代吗