Ubuntu System Installation Configuration Redis

Source: Internet
Author: User
Tags dotfiles

Ubuntu System Installation Configuration Redis

Redis is a NoSQL database, and Redis is very efficient in scenarios where the data needs to be updated frequently and where the data has a wide range of access hotspots.
The installation process for Redis is described below, as shown in the following steps.

1. Download and install

12345 wget http://redis.googlecode.com/files/redis-2.2.13.tar.gztar-zxf redis-2.2.13.tar.gzcd redis-2.2.13makesudo makeinstall

The Redis executable is then placed in the/usr/local/bin.

2. Download the configuration file and Init startup script

12345 wget https://github.com/ijonas/dotfiles/raw/master/etc/init.d/redis-serverwget https://github.com/ijonas/dotfiles/raw/master/etc/redis.confsudo mv redis-server /etc/init.d/redis-serversudo chmod +x /etc/init.d/redis-serversudo mv redis.conf /etc/redis.conf

3. Initialize user and log path
Before you start Redis for the first time, it is recommended that you create a separate user for Redis and create a new data and log folder.

12345 sudo useradd redis sudo mkdir -p /var/lib/redis sudo mkdir -p /var/log/redis sudo chown redis.redis /var/lib/redis sudo chown redis.redis /var/log/redis

4, set the boot automatically start, shut down automatically

1 sudoupdate-rc.d redis-server defaults

5. Start Redis

1 sudo/etc/init.d/redis-serverstart

6. Verify the Startup success

123 ps-ef | grep redisredis     9544     1  0 21:06 ?        00:00:00 /usr/local/bin/redis-server    /etc/redis.confhadoop    9549  7429  0 21:06 pts/3 00:00:00 grep--color=auto redis

7. Starting Client Clients

1234567 redis-cliredis 127.0.0.1:6379> helpredis-cli 2.6.14Type: "help @<group>" to get a list of commands in <group>      "help <command>" for help on <command>      "help <tab>" to get a list of possible help topics      "quit" to exit

Ubuntu System Installation Configuration Redis

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.