FROM: http://www.art-coder.com/2011/12/01/how-to-run-redis-server-as-daemon/

How to run Redis server as daemon

So I think, that those who will read this article probably know, what is Redis. For those who don't I can say shortly, that this is a software, that is used for storing some maped data ( key => value ) for faster usage. This software could help developers to make their applications by storing some primitive data like for example translations on multi-language webpage or other similar information. In this article I will shortly explain how to make your Redis server run as daemon, since making startup file for this in unix is not an option.

First obviously you need to get it and unpack. It is all explained on official Redis webpage, but for those who want to stay in one place I will explain it here.

Sort of installation

Download, extract and compile Redis with:
$ wget http://redis.googlecode.com/files/redis-2.4.4.tar.gz
$ tar xzf redis-2.4.4.tar.gz
$ cd redis-2.4.4
$ make

So now when everything is ready for starting server comes the part with creating a daemon from this.
Make sure you are in redis directory and do the following:
vim redis.conf

And after that just change 'no' to 'yes' in line with daemonize option
# By default Redis does not run as a daemon. Use 'yes' if you need it.
# Note that Redis will write a pid file in /var/run/redis.pid when daemonized.
daemonize yes

After you saved file with this change just start server:
$ src/redis-server

This is it. Now you can look it up by typing ps aux and you will see it as a deamon process there.

[转载]Redis后台启动的更多相关文章

  1. redis后台启动配置

    在cmd窗口启动redis,窗口关闭后再次操作会报错. 将redis安装为服务,可使其在后台启动,无须担心误操作关闭服务窗口. 配置如下: 进入redis目录,输入如下命令执行即可: redis-se ...

  2. Linux 下的 Redis 安装 && 启动 && 关闭 && 卸载

    转自https://blog.csdn.net/zgf19930504/article/details/51850594 Redis 在Linux 和 在Windows 下的安装是有很大的不同的,和通 ...

  3. Linux云服务器下Redis安装与部署以及设置redis后台运行

    Redis下载: http://redis.io/download 我下载的4.0.11 上传到服务器 注: 官方的建议是直接在linux下载并解压编译 这里不建议先解压再上传到服务器,之前我这样做, ...

  4. redis如何后台启动

    当安装好redis之后,运行redis-server命令之后,显示如图所示: 但是这样没有办法在这个tab下做任何操作了,因为这个时候使用Ctrl+c之后,就变成了这个样子 然后就关闭了,那么我想让r ...

  5. redis前端启动和后台启动的区别

    Part I. 直接启动下载官网下载安装tar zxvf redis-2.8.9.tar.gzcd redis-2.8.9#直接make 编译make#可使用root用户执行`make install ...

  6. protocol error, got 'n' as reply type byte + redis如何后台启动

    其它机子的PHP访问redis爆“protocol error, got 'n' as reply type byte ”错误 解决办法: 在redis配置文件redis.conf中注释掉bind配置 ...

  7. Windows Redis 开机启动后台运行

    1. 从 Redis 的安装目录进入 cmd 2. 在 cmd 中输入, 将Redis绑定为 Windows 服务, 并设置为后台启动: redis-server --service-install ...

  8. 将Redis设置为后台启动

    Linux 在执行redis-server  /etc/redis.conf 时默认开启的是一个前台的进程,也就是说启动的redis 就做不了其他的操作了,只有关闭redis 才能做其他的操作.非常的 ...

  9. centos7安装redis 并配置在后台启动

    官网  https://redis.io/download 先进入 目录 /usr/local 1 下载文件包 $ wget http://download.redis.io/releases/red ...

随机推荐

  1. codeforces ice cave

    /// /// 题意:告诉起点终点,踩一次, '.'变成'X',再踩一次,冰块破碎,问是否能使终点冰破碎 /// DFS:如题解所说,分三种情况:1. 如果两点重合,只要往外走一步再走回来就行了:2. ...

  2. POJ3680:Intervals(离散化+最大流最小费用)

    Intervals Time Limit: 5000MS   Memory Limit: 65536K Total Submissions: 9320   Accepted: 4014 题目链接:ht ...

  3. Educational Codeforces Round 42 (Rated for Div. 2) A

    A. Equator time limit per test 2 seconds memory limit per test 256 megabytes input standard input ou ...

  4. [ CodeVS冲杯之路 ] P3027

    不充钱,你怎么AC? 题目:http://codevs.cn/problem/3027/ 显然是DP题,先按线段的右端点升序排序 设 f[i] 为dp到第 i 个线段时最大的价值 目标状态为 max( ...

  5. [bzoj2190][SDOI2008]仪仗队 ——欧拉函数

    题解 以c点为(0, 0)建立坐标系,可以发现, 当(x,y)!=1,即x,y不互素时,(x,y)点一定会被点(x/n, y/n)遮挡. 所以点(x, y)被看到的充分必要条件是Gcd(x, y) = ...

  6. 信息传递(NOIP2015)(寻找最小环。。)

    原题传送门 这是一道寻找最小环的题目. 在做的时候给每一个点染色.. 防止再做已经搜过的点(优化) v[]表示是否访问的过,以及第一次访问该点的时间. u[]表示染色.. 这道题还可以用拓补排序做. ...

  7. centos dhcp获取不到ip解决方法 Bringing up interface eth0: Device eth0 does not seem to be present,delaying initialization.

    1.删除文件: /etc/udev/rules.d/70-persistent-net.rules 2.编辑 /etc/sysconfig/network-scripts/ifcfg-eth0 删除H ...

  8. 推荐一本书:《UML面向对象建模基础》

    http://www.cnblogs.com/onlytiancai/archive/2006/10/13/528205.html 以前对UML呀,感觉用不上,不知道都干啥的,也就是知道有个用例图.类 ...

  9. 理解python的super

    def super(cls, inst): mro = inst.__class__.mro() return mro[mro.index(cls) + 1] super做了这些事 摘自:https: ...

  10. AC日记——Count on a tree II spoj

    Count on a tree II 思路: 树上莫队: 先分块,然后,就好办了: 来,上代码: #include <cmath> #include <cstdio> #inc ...