• Categories
    Category
    {{ postCtrl.tags }}
    • {{ category.tag_type }}

      • {{tag.tag_name}}
      • View more
  • Categories
    Category
    {{ postCtrl.tags }}
    • {{ category.tag_type }}

      • {{tag.tag_name}}
      • View more
  • News
  • Tutorials
  • Forums
  • Tags
  • Users
Tutorial News Comments FAQ Related Articles

How to install Redis server on Ubuntu 17.04

{{postValue.id}}

How to install Redis server on Ubuntu 17.04

Redis is an open source (BSD licensed), in-memory data structure store, used as a database, cache and message broker. It supports data structures such as strings, hashes, lists, sets, sorted sets with range queries, bitmaps, hyperloglogs and geospatial indexes with radius queries. It also supports built-in replication, Lua scripting, LRU eviction, transactions and different levels of on-disk persistence, and provides high availability via Redis Sentinel and automatic partitioning with Redis Cluster. This tutorial will explain on how to install Redis server on Ubuntu 17.04.

Installation procedure

To start the installation process, execute the following command to install the Redis package as shown below.

root@linuxhelp1:~# apt-get install redis-server
Reading package lists... Done
Building dependency tree      
Reading state information... Done
The following additional packages will be installed:
  libjemalloc1 redis-tools
Suggested packages:
  ruby-redis
.
.
.
Created symlink /etc/systemd/system/multi-user.target.wants/redis-server.service &rarr  /lib/systemd/system/redis-server.service.
Processing triggers for ureadahead (0.100.0-19) ...
Processing triggers for systemd (232-21ubuntu2) ...

The Redis package has been successfully installed. Now install the php-redis package by running the following command.

root@linuxhelp1:~# apt-get install php-redis
Reading package lists... Done
Building dependency tree      
Reading state information... Done
The following additional packages will be installed:
  php-common php-igbinary php7.0-cli php7.0-common php7.0-json php7.0-opcache php7.0-phpdbg
  php7.0-readline
.
.
.
Creating config file /etc/php/7.0/phpdbg/php.ini with new version
Setting up php-igbinary (2.0.1-1) ...
Setting up php-redis (3.1.1-1) ...

Run the following command to open the configuration file in vim editor. Add the following statements in Redis configuration file. Save and exit from the file.

root@linuxhelp1:~# vim /etc/redis/redis.conf
maxmemory 128mb
maxmemory-policy allkeys-lru

The configuration file is saved with the changes. Now restart and enable the Redis service.

root@linuxhelp1:~# systemctl restart redis-server.service
root@linuxhelp1:~# systemctl enable redis-server.service

Now the Redis server is ready, run the below command to access Redis application.

root@linuxhelp1:~# redis-cli
127.0.0.1:6379> 

The Redis terminal is logged on, now the user can manage the database by using Redis server.

Wasn' t that an easy installation procedure? The Redis server influence queues, leaderboards, pub/sub, session cache and full page cache.

Tags:
wyatt
Author: 

Comments ( 0 )

No comments available

Add a comment
{{postCtrl.cmtErrMsg}}

Frequently asked questions ( 5 )

Q

Are Redis on-disk-snapshots atomic?

A

Yes, redis background saving process is always forked when the server is outside of the execution of a command, so every command reported to be atomic in RAM is also atomic from the point of

Q

What does Redis actually mean?

A

Redis means REmote DIctionary Server.

Q

Why did you start the Redis project?

A

Originally Redis was started in order to scale LLOOGG. But after I got the basic server working I liked the idea to share the work with other people, and Redis was turned into an open source

Q

which command to access the redis server in ubuntu terminal?

A

Now the Redis server is ready, run the below command to access Redis application.
# redis-cli

Q

how to install the redis package in ubuntu server?

A

execute the following command to install the Redis package as shown below
# apt-get install redis-server

Back To Top!
Rank
User
Points

Top Contributers

userNamenaveelansari
135850

Top Contributers

userNameayanbhatti
92510

Top Contributers

userNamehamzaahmed
32150

Top Contributers

1
userNamelinuxhelp
31040

Top Contributers

userNamemuhammadali
24500
Can you help Ganesh Konka ?
Zentya 6.1 http proxy configuration

please send link for creating zentyal 6.1 for http proxy and firewall as gateway.

Networking
  • Routing
  • trunk
  • Netmask
  • Packet Capture
  • domain
  • HTTP Proxy
Server Setup
  • NFS
  • KVM
  • Memory
  • Sendmail
  • WebDAV
  • LXC
Shell Commands
  • Cloud commander
  • Command line archive tools
  • last command
  • Shell
  • terminal
  • Throttle
Desktop Application
  • Linux app
  • Pithos
  • Retrospect
  • Scribe
  • TortoiseHg
  • 4Images
Monitoring Tool
  • Monit
  • Apache Server Monitoring
  • EtherApe 
  • Arpwatch Tool
  • Auditd
  • Barman
Web Application
  • Nutch
  • Amazon VPC
  • FarmWarDeployer
  • Rukovoditel
  • Mirror site
  • Chef
Contact Us | Terms of Use| Privacy Policy| Disclaimer
© 2025 LinuxHelp.com All rights reserved. Linux™ is the registered trademark of Linus Torvalds. This site is not affiliated with linus torvalds in any way.