Redis 安装:

$ wget http://redis.googlecode.com/files/redis-2.4.5.tar.gz

$ tar xzf redis-2.4.5.tar.gz

$ cd redis-2.4.5

$ make & make install

测试:

$ src/redis-server

$ src/redis-cli

auth haojg //haojg是密码

redis> set foo bar

OK

redis> get foo

"bar"

将redis.conf中的daemonize no 变成daemonize yes

$ cd ../utils/

$./install_server     //安装启动服务

显示信息:

root@hman utils]# ./install_server.sh

Welcome to the redis service installer

This script will help you easily set up a running redis server

Please select the redis port for this instance: [6379]

Selecting default: 6379

Please select the redis config file name [/etc/redis/6379.conf]

Selected default - /etc/redis/6379.conf

Please select the redis log file name [/var/log/redis_6379.log]

Selected default - /var/log/redis_6379.log

Please select the data directory for this instance [/var/lib/redis/6379]

Selected default - /var/lib/redis/6379

Please select the redis executable path [/usr/local/bin/redis-server]

s#^port [0-9]{4}$#port 6379#;s#^logfile .+$#logfile /var/log/redis_6379.log#;s#^dir .+$#dir /var/lib/redis/6379#;s#^pidfile .+$#pidfile /var/run/redis_6379.pid#;s#^daemonize no$#daemonize yes#;

Copied /tmp/6379.conf => /etc/init.d/redis_6379

Installing service...

./install_server.sh: line 178: update-rc.d: command not found

exists, process is already running or crashed

Installation successful!

默认就可以了,一路回车

执行完后,查看/etc/redis/6379.conf,这个文件默认不能用chkconfig来添加到启动项,会报错的,可以使用附件里的文件来替换或修改。

fedorea19安装redis的更多相关文章

  1. Ubuntu安装redis并配置远程、密码以及开启php扩展

    一.前言 redis是当前流行的nosql数据库,很多网站都用它来做缓存,今天我们来安装并配置下redis 二.安装并配置redis 1.安装redis sudo apt-get install re ...

  2. CentOS 7 下安装redis步骤

    1. 从redis官网下载redis源码,本例安装在/usr/opt下 [root@localhost opt]# pwd /usr/opt [root@localhost opt]# wget ht ...

  3. 安装redis以windows服务形式

    安装redis以windows服务形式 安装redis以windows服务形式 redis windows windows 服务 以前跑redis,老是要开一个命令行窗口,一旦关闭,redis服务就挂 ...

  4. Mac Pro 编译安装 Redis 的 PHP 客户端 phpredis

    1.去官网下载 redis 扩展源码包 https://github.com/phpredis/phpredis 2.安装 redis 扩展 /usr/local/src/mac-sdk/source ...

  5. 编译安装PHP7并安装Redis扩展Swoole扩展

    编译安装PHP7并安装Redis扩展Swoole扩展 在编译php7的机器上已经有编译安装过php5.3以上的版本,从而依赖库都有了 本php7是编译成fpm-php 使用的, 如果是apache那么 ...

  6. 【安装Redis】CentOS7 下安装NodeJs+Express+MongoDB+Redis

    Redis,V3.2,官网l官方链接:http://www.redis.io/download,参考:http://blog.csdn.net/mlks_2008/article/details/19 ...

  7. centos7.0 安装redis集群

    生产环境下redis基本上都是用的集群,毕竟单机版随时都可能挂掉,风险太大.这里我就来搭建一个基本的redis集群,功能够用但是还需要完善,当然如果有钱可以去阿里云买云数据库Redis版的,那个还是很 ...

  8. Linux(Centos)之安装Redis及注意事项

    1.redis简单说明 a.在前面我简单的说过redis封装成共用类的实现,地址如下:http://www.cnblogs.com/hanyinglong/p/Redis.html. b.redis是 ...

  9. centos上如何安装redis?|centos傻瓜式安装redis教程

    本文介绍centos安装redis,请不要安装2.4.3,是有问题的. 首先安装gcc yum -y install gcc yum -y install gcc-c++ yum install ma ...

随机推荐

  1. Day5 - Python基础5 常用模块学习

    Python 之路 Day5 - 常用模块学习   本节大纲: 模块介绍 time &datetime模块 random os sys shutil json & picle shel ...

  2. windows服务安装(System.ComponentModel.Win32Exception:远程过程调用失败)

    “安装”阶段发生异常.System.ComponentModel.Win32Exception:远程过程调用失败 附上提示信息C:\Windows\Microsoft.NET\Framework\v4 ...

  3. 国内优秀npm镜像

    淘宝npm镜像 淘宝npm镜像:http://npm.taobao.org/ 1.临时使用 npm --registry https://registry.npm.taobao.org install ...

  4. [转] iOS开发- UICollectionView详解+实例

    本章通过先总体介绍UICollectionView及其常用方法,再结合一个实例,了解如何使用UICollectionView. UICollectionView 和 UICollectionViewC ...

  5. [转] UIImage 图像-IOS开发 (实例)

    转自  http://justcoding.iteye.com/blog/1470931 一 UIImageView 简介 UIImageView是显示图片的控件,显示图片时,首先需要把图片加载到UI ...

  6. IOS常用CGRect的交错,边缘,中心的检测

    转自:http://tsyouaschen.iteye.com/blog/1946957 判断给定的点是否被一个CGRect包含,可以用CGRectContainsPoint函数 BOOL conta ...

  7. 《编写高质量代码--Web前端开发修炼之道》读书笔记

    前言 这两周参加公司的新项目,采用封闭式开发(项目成员在会议室里开发),晚上加班到很晚,所以没时间和精力写原创博客了,今天就分享下这篇<编写高质量代码--Web前端开发修炼之道>读书笔记吧 ...

  8. Oracle的卸载与安装

    今天在做一个CURD的web小应用,为后面使用ExtJS搭建一个后台.因为还没有使用过Oracle数据库,因此今天也特的地的使用oracle数据库作为后台的数据库,也当练习使用oracle. 但是今天 ...

  9. Linux下Openfire相关安装和配置

    记录下来,方便下次再用时从头查找资料 小京东ecshop中的通讯有用到openfire,Window下配置安装很简单,直接下载exe文件安装就行,而linux下要麻烦一点.安装后的配置下面会细说: 一 ...

  10. $_GLOBALS超全局数组和global定义的全局变量区别?

    全局变量:主程序中定义的变量(函数外部),只能在主程序中使用,在函数内部不能调用 背景:解决在函数内部调用全局变量的问题 解决方法: 1.在函数内部声名全局变量 <?php public $va ...