In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/02 Report--
Editor to share with you how Redis in Window to achieve similar to linux in the daemon mode to run services, I believe that most people do not know much, so share this article for your reference, I hope you can learn a lot after reading this article, let's go to know it!
Step 1: install redis-server.exe as a service under window
First change to the directory of redis-server.exe, and then execute the following installation command:
Redis-server.exe-service-install redis.windows.conf-loglevel verbose
Where:-- the purpose of service-install is to tell window to install redis-server.exe as a service
The purpose of redis.windows.conf is to tell window to start with this parameter, which is the configuration file of redis, that is, the configuration file that specifies redis.window.conf as redis when starting.
-- loglevel this parameter is the specified logging level. Redis supports a total of four levels: debug, verbose, notice, and warning. Default is verbose.
The result of executing the command is as follows, indicating that the service was installed successfully:
Step 2: start the server
Change to the redis-server.exe directory and execute the following startup command:
Redis-server.exe-service-start
After seeing the following result, it shows that redis starts successfully. At this time, we find that the current process is no longer blocked, that is, the redis service runs successfully in the background.
At this point, how do we verify that redis is running in the background service?
Step 3: verify that the redis service is running in the background:
Open the task manager. The shortcut key is ctrl+shift+esc.
We see redis in the service tab, and the status is running, indicating that the goal has been achieved!
Step 4: supplement
Uninstall service: change to the redis-server.exe directory and execute the following uninstall command:
Redis-server.exe-service-uninstall
Stop the service: change to the redis-server.exe directory and execute the following stop command:
Redis-server.exe-service-stop
The following errors can be reported during installation:
[10416] 13 Oct 22:23:30.501 # HandleServiceCommands: system error caught. Errorcode=1073, message = CreateService failed: unknown error
The reason is that there is already a reids service, re-execute the uninstall command redis-server.exe-- service-uninstall, and then re-execute the install service command!
These are all the contents of the article "how to run the service as a daemon in Redis under Window similar to that in linux". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.