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.
Official: Http://redis.io/download, but there is no official 64-bit Windows executable program, currently has an open source hosted on GitHub, address: https://github.com/ServiceStack/ Redis-windows Click this place, download the file and unzip it to your own computer directory.
This article uses version:redis64-3.0.501.zip
The following directories are extracted:
Filename |
Briefly |
Redis-benchmark.exe |
Benchmark Test |
Redis-check-aof.exe |
AoF |
Redischeck-dump.exe |
Dump |
Redis-cli.exe |
Client |
Redis-server.exe |
Server |
Redis.windows.conf |
Configuration file |
Then edit the redis.windows.conf file, I see some tutorials on the web said the editor inside Maxheap <bytes> , but after the 3.x version, modified is MaxMemory < Bytes>, Bytes is byte, please self-conversion, I change here to maxmemory 1024000000.
In fact, this place can not be set, he described the already said, Redis will automatically set.
Set the Redis password: Find # requirepass foobared instead of requirepass my password , the native test is not set.
After saving open the Redis directory, shift+ the left mouse button to find the menu: Open a command line window here or run the cmd command yourself to this directory
The command is as follows:
Redis-server.exe redis.windows.conf--maxmemory 200M
Where--maxmemory 200M is optional, if you configure the file redis.windows.conf configuration, this can be omitted, if not configured, this can add also can not add, you happy good.
When this interface appears, the boot is successful, listen to Port 6379, and let's test the effect.
Reopen a DOS interface with the following effect:
If you set up a redis password, you need to execute the auth password command before set, otherwise the Noauth authentication required will be indicated (error).
Finally, add Redis to the Windows service. First, start the Redis server, and then run the Redis client, and then through the Windows Service-install command, enter
Redis-server--service-install redis.windows.conf--loglevel verbose
You can start with the win service later, without having to open a DOS interface every time.
Redis installation and use under Win10x64