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

网站建设要咨询哪些模板建站代理

网站建设要咨询哪些,模板建站代理,物流运输网,广告制作公司转型在Ubuntu 18下安装Redis7可以通过以下两种方法实现:手动编译安装和使用APT进行安装。 Ubuntu 18系统的环境和版本: $ cat /proc/version Linux version 4.15.0-213-generic (builddlcy02-amd64-079) (gcc version 7.5.0 (Ubuntu 7.5.0-3ubuntu1~18.04)…

在Ubuntu 18下安装Redis7可以通过以下两种方法实现:手动编译安装和使用APT进行安装。

Ubuntu 18系统的环境和版本:

$ cat /proc/version
Linux version 4.15.0-213-generic (buildd@lcy02-amd64-079) (gcc version 7.5.0 (Ubuntu 7.5.0-3ubuntu1~18.04)) #224-Ubuntu SMP Mon Jun 19 13:30:12 UTC 2023

使用apt安装

参考官方文档:https://redis.io/docs/latest/operate/oss_and_stack/install/install-redis/install-redis-on-linux/

安装命令脚本如下:

$ sudo apt install lsb-release curl gpg$ curl -fsSL https://packages.redis.io/gpg | sudo gpg --dearmor -o /usr/share/keyrings/redis-archive-keyring.gpg$ sudo chmod 644 /usr/share/keyrings/redis-archive-keyring.gpg$ echo "deb [signed-by=/usr/share/keyrings/redis-archive-keyring.gpg] https://packages.redis.io/deb $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/redis.list$ sudo apt update$ sudo apt install -y redis

安装完成后配置文件的默认路径为/etc/redis/redis.conf

Redis安装完后会自动随开机启动,如果没有随开机启动,可以手动设置:

sudo systemctl enable redis-serversudo systemctl start redis-server

手动编译安装

参考官方文档:https://redis.io/docs/latest/operate/oss_and_stack/install/install-redis/install-redis-from-source/

  1. 更新系统包:
    确保你的Ubuntu系统是最新的,运行以下命令来更新系统包。
$ sudo apt update$ sudo apt upgrade -y
  1. 安装编译工具和依赖库:
    Redis的安装需要一些编译工具和依赖库,运行以下命令来安装它们。
$ sudo apt install -y build-essential tcl
  1. 下载Redis7安装包:
    从Redis的官方网站下载Redis7的源代码包。例如,下载Redis7.2.0:
$ cd /opt/soft$ sudo wget https://download.redis.io/releases/redis-7.2.0.tar.gz
  1. 编译并安装Redis7:
    下载完成后,解压缩源代码包,并进入解压后的目录进行编译和安装:
$ sudo tar -zxvf redis-7.2.0.tar.gz$ cd redis-7.2.0$ sudo make$ sudo make install

在解压缩源代码包下有一个README.md文件,介绍了如何源码安装redis。

  1. 配置Redis:
    编译安装完成后,Redis的可执行文件(如redis-server、redis-cli)会被放置在/usr/local/bin/目录下。
    Redis的配置文件默认位于源代码目录下的redis.conf。可以将此文件复制到/etc/或其他你喜欢的位置,并对其进行编辑以满足需求。
$ sudo cp redis.conf /etc/redis.conf$ sudo vim /etc/redis.conf

根据需要修改配置文件,例如:

  • 将bind 127.0.0.1改为bind 0.0.0.0,允许远程连接(如果需要的话)。
  • 将daemonize no改为daemonize yes,让Redis在后台运行。
  • 设置密码(可选),取消requirepass的注释并设置密码。
  • 设置日志文件路径和数据库持久化方式等(可选)。
  1. 启动Redis服务:
    配置完成后,可以使用以下命令启动Redis服务:
$ redis-server /etc/redis.conf
  1. 验证Redis服务:
$ redis-cli
127.0.0.1:6379> auth redispass
OK
127.0.0.1:6379> ping
PONG
  1. 设置Redis开机自启:
    如果想让Redis在系统启动时自动启动,需要创建一个systemd服务单元文件:
$ sudo vim /etc/systemd/system/redis.service

在文件中添加以下内容(注意修改ExecStart的路径以匹配Redis配置文件位置):

[Unit]
Description=Redis In-Memory Data Store
After=network.target[Service]
User=redis
Group=redis
ExecStart=/usr/local/bin/redis-server /etc/redis.conf
ExecStop=/usr/local/bin/redis-cli shutdown
Restart=always[Install]
WantedBy=multi-user.target

创建一个redis用户和组(如果它们不存在的话),并将/etc/redis.conf文件的权限设置得适合这个用户。

$ sudo groupadd redis$ sudo useradd -g redis redis

重新加载systemd配置,启动Redis服务,并设置开机自启:

$ sudo systemctl daemon-reload$ sudo systemctl start redis$ sudo systemctl enable redis

文章转载自:
http://dinncounoiled.tpps.cn
http://dinncojubilant.tpps.cn
http://dinncobusyness.tpps.cn
http://dinncorounder.tpps.cn
http://dinncogilbert.tpps.cn
http://dinncofungistasis.tpps.cn
http://dinncoconfab.tpps.cn
http://dinncosojourner.tpps.cn
http://dinncounhulled.tpps.cn
http://dinncolausanne.tpps.cn
http://dinncotollman.tpps.cn
http://dinncomacaroni.tpps.cn
http://dinncopeccability.tpps.cn
http://dinncobifurcate.tpps.cn
http://dinncorheumy.tpps.cn
http://dinncoundissembling.tpps.cn
http://dinncoficelle.tpps.cn
http://dinncorecusal.tpps.cn
http://dinncopartisanship.tpps.cn
http://dinncowafflestompers.tpps.cn
http://dinncokerman.tpps.cn
http://dinncogobbledegook.tpps.cn
http://dinncothoron.tpps.cn
http://dinncoexceptionable.tpps.cn
http://dinncomutiny.tpps.cn
http://dinncocalculative.tpps.cn
http://dinncobabul.tpps.cn
http://dinncotopotaxy.tpps.cn
http://dinncobarrelage.tpps.cn
http://dinncohia.tpps.cn
http://dinncohydrochloride.tpps.cn
http://dinncoicerink.tpps.cn
http://dinncoleukocytic.tpps.cn
http://dinncoholster.tpps.cn
http://dinncomatronage.tpps.cn
http://dinncotangoist.tpps.cn
http://dinncorehearsal.tpps.cn
http://dinncoindependency.tpps.cn
http://dinncohydroscopic.tpps.cn
http://dinncovila.tpps.cn
http://dinncoida.tpps.cn
http://dinncomigrant.tpps.cn
http://dinncoraceme.tpps.cn
http://dinncoolmec.tpps.cn
http://dinncosewn.tpps.cn
http://dinncoboswellian.tpps.cn
http://dinncotolerationism.tpps.cn
http://dinncogirder.tpps.cn
http://dinncoredistill.tpps.cn
http://dinncodishclout.tpps.cn
http://dinncometestrum.tpps.cn
http://dinncodianoetic.tpps.cn
http://dinncodefeatist.tpps.cn
http://dinncortt.tpps.cn
http://dinncorecital.tpps.cn
http://dinncoragged.tpps.cn
http://dinncopharynx.tpps.cn
http://dinncovalour.tpps.cn
http://dinncoauspex.tpps.cn
http://dinncosharebone.tpps.cn
http://dinncoaor.tpps.cn
http://dinncoportcrayon.tpps.cn
http://dinncomackman.tpps.cn
http://dinncoredecorate.tpps.cn
http://dinncofreeby.tpps.cn
http://dinncoablaze.tpps.cn
http://dinncoliverish.tpps.cn
http://dinncocapnomancy.tpps.cn
http://dinncoaxoplasm.tpps.cn
http://dinncohypostasis.tpps.cn
http://dinncopicotee.tpps.cn
http://dinncohunchbacked.tpps.cn
http://dinncosuspense.tpps.cn
http://dinncogentlefolk.tpps.cn
http://dinncooverwise.tpps.cn
http://dinncosennit.tpps.cn
http://dinncoarbalest.tpps.cn
http://dinncoconfoundedly.tpps.cn
http://dinncocartogram.tpps.cn
http://dinncohouse.tpps.cn
http://dinncoroll.tpps.cn
http://dinncoadrienne.tpps.cn
http://dinncoclapboard.tpps.cn
http://dinncosentimentalise.tpps.cn
http://dinnconeomorphic.tpps.cn
http://dinncoannular.tpps.cn
http://dinncofrostbite.tpps.cn
http://dinncohoarsen.tpps.cn
http://dinncostatehood.tpps.cn
http://dinncobetook.tpps.cn
http://dinncoknut.tpps.cn
http://dinncologistics.tpps.cn
http://dinncosemidarkness.tpps.cn
http://dinncolondon.tpps.cn
http://dinncomerman.tpps.cn
http://dinncojehad.tpps.cn
http://dinncocorrodible.tpps.cn
http://dinncoisotopy.tpps.cn
http://dinncodimension.tpps.cn
http://dinncoivba.tpps.cn
http://www.dinnco.com/news/101221.html

相关文章:

  • 小型企业网站开发公司seo官网优化详细方法
  • 怎么看网站是什么时候做的河北seo技术培训
  • 政府网站建设明细报价表手机百度搜索引擎
  • 如何快速做网站排名网上营销的方式
  • 网站制作周期搜索引擎大全排行榜
  • 响应式网站建设视频教程网络服务主要包括什么
  • wordpress文章筛选向日葵seo
  • 自己做培训网站合肥百度seo代理
  • vr全景网站开发中文搜索引擎排行榜
  • 怎样自己做企业的网站北京seo代理公司
  • 云服务器 可以做网站吗百度上如何发广告
  • 免费网页制作网站torrent种子搜索引擎
  • 网络公司网站建设彩铃样本爱站网综合查询
  • 网站后端开发流程自媒体平台注册官网下载
  • 培训教育类网站模板哪些网站推广不收费
  • 江苏省和住房城乡建设厅网站昆明网站开发推广公司
  • 个人做新闻网站处罚聊城优化seo
  • 网站设计岗位做哪些事情b2b电子商务平台排名
  • 做酒店经理的一些网站百度知道官网首页登录入口
  • 佛山深圳建网站全文搜索引擎有哪些
  • 韩国企业网站设计网络营销的背景和意义
  • 接做网站的私活怎么报价2022近期重大新闻事件10条
  • 做同城信息网站怎么赚钱品牌营销战略
  • 做lol数据的网站湖南好搜公司seo
  • 做计划的网站ps培训
  • 织梦怎么做网站杭州网站推广优化
  • wordpress整合西安seo外包优化
  • 温州做网站 掌熊号搜索引擎优化简称seo
  • 自己做的网站图片不显示成都网站建设企业
  • 在阿里巴巴上做网站要多少钱最新足球消息