Introduction to cache Database Redis---> Installation

Source: Internet
Author: User
Tags install homebrew install redis redis server

NoSQL Introduction to NoSQL: A new type of database (not only SQL)
    • A non-relational database
    • SQL syntax not supported
    • The storage structure is completely different from the relational table in the traditional relational database, and the data stored in NoSQL is in kv form
    • There is no universal language in the NoSQL world, and each NoSQL database has its own API and syntax, as well as a business scenario that excels
    • There are quite a few types of products in NoSQL:
      • Mongodb
      • Redis
      • Hbase Hadoop
      • Cassandra Hadoop
Comparison of NoSQL and SQL databases:
    • Different scenarios: SQL database is ideal for data query scenarios with particularly complex relationships, NoSQL instead
    • Support for the transaction attribute: SQL supports transactions very well, and NoSQL basically does not support transactions
    • The two continue to complement each other and present a trend of convergence
About Redis
    • Redis is an open source API that is written in ANSI C, supports the web, can be persisted in memory, key-value databases, and provides multiple languages. From March 15, 2010 onwards, the development work of Redis is hosted by VMware. Since May 2013, the development of Redis has been sponsored by pivotal.
    • Redis is a member of the NoSQL technology camp, which adapts various key-value data types to the storage needs of different scenarios, using a number of high-level interfaces that can be used to handle different roles, such as caching and queuing systems.
Redis Features
    • Redis and other Key-value cache products have the following three features:
    • Redis supports data persistence, which saves data in memory on disk and can be loaded again for use when restarting.
    • Redis not only supports simple key-value types of data, but also provides storage of data structures such as List,set,zset,hash.
    • Redis supports backup of data, that is, Master-slave mode of data backup.
Redis Benefits
    • The performance is very high –redis can read the speed is 110,000 times/s, the write speed is 81,000 times/s.
    • Rich data types –redis support binary case Strings, Lists, hashes, sets and Ordered sets data type operations.
    • All atomic –redis operations are atomic, and Redis supports atomic execution of several operations.
    • Rich features –redis also supports publish/subscribe, notifications, key expiration, and more.
Redis Application Scenarios
    • All the data used to do the cache (ehcache/memcached)--redis is in memory (in-memory database)
    • Can be used to replace traditional databases in certain scenarios-such as social applications
    • In some large systems, the ingenious implementation of some specific functions: Session sharing, Shopping cart
    • As long as you have a rich imagination, redis can be used to give you infinite surprises ....
Recommended Reading
    • Redis official website
    • Redis Chinese official website
Redis Installation
    • Current Redis latest stable version is 4.0.9
    • Redis is already installed in Ubuntu virtual machine, the following steps can skip the latest stable version download link: http://download.redis.io/releases/redis-4.0.9.tar.gz
    • Step1: Download wget http://download.redis.io/releases/redis-4.0.9.tar.gz

  • Step2: Unzip

    Tar xzf redis-4.0.9.tar.gz

  • Step3: Move, put it on the usr/local?

    sudo mv./redis-4.0.9/usr/local/redis/

  • Step4: Into a redis record

    cd/usr/local/redis/

  • STEP5: Generate sudo make

  • STEP6: Test, this time will be more? sudo make test
  • STEP7: Install, install Redis commands to/usr/local/bin/? sudo make install
  • STEP8: After the installation is complete, we go to the directory/usr/local/bin to view the Ls-a
    • Redis-server Redis Server
    • REDIS-CLI Redis command-line Client
    • Redis-benchmark Redis Performance Testing Tool
    • Redis-check-aof aof File Repair Tool
    • Redis-check-rdb RDB File Retrieval Tool
      • STEP9: Configure the pieces, move to/etc/?

      • The configuration of the piece is recorded as/usr/local/redis/redis.conf.

        sudo cp/usr/local/redis/redis.conf/etc/redis/

      • Install Redis on MAC:

        • Install Homebrew:

        https://brew.sh/

        • Using Brew to install Redis

        Https://www.cnblogs.com/cloudshadow/p/mac_brew_install_redis.html

Introduction to cache database Redis---> Installation

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.