Table of contents
Preface
Since I have been using the Linux interface for a long time, I don’t know how to start with Redis under Windows. This blog post is hereby recorded
Pay special attention to the newly downloaded Redis. If you need to configure a password, you can configure it in this file:redis.windows-service.conf
In the configuration file, find the requirepass foobared text
, append a line after it, enterrequirepass 123456
and then restart the service to take effect. How to restart the service See below
1. Graphical interface
You can go to Computer->Management->Services
Just restart the Redis service. If you want to confirm the shutdown, you need to close it in the Redis service:
2. Command line
For command line opening and closing
The following is the configuration of the Redis environment variables. If the environment variables are not configured, they need to be turned on and off in the Redis installation directory:
-
Start the service:
redis-server --service-start
-
Out of service:
redis-server --service-stop
There is another way to close it, by querying its Redis process number: tasklist | findstr "redis"
and closing its process number: taskkill /pid 11548 -f
(this The execution of the command requires cmd under the administrator)