In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-30 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)05/31 Report--
This article will explain in detail the methods of real-time monitoring redis performance. The editor thinks it is very practical, so I share it with you as a reference. I hope you can get something after reading this article.
Foreword:
Redis is a key-value storage system written by Salvatore Sanfilippo, which is a cross-platform non-relational database.
Redis is an open source key-value pair (Key-Value) database that is written in ANSI C, complies with the BSD protocol, supports the network, can be based on memory, distributed, and optional persistence, and provides API in multiple languages.
Main contents:
First, how to view the monitoring
After installing Redis, you can use its own connection client redis-cli to connect to the Redis service, and use the info command to view the running status of all redis
[root@node1 ~] # redis-cli info all # View redis information
Next, we need to know and analyze the meaning of each parameter.
2. Description of the parameters monitored
2.1. Connection class information
Number of connected_clients ◦ connected clients (excluding clients connected through secondary servers) client_longest_output_list ◦ currently connected clients, longest output list client_longest_input_buf ◦ currently connected clients, maximum input cache blocked_clients ◦ number of clients waiting for blocking commands (BLPOP, BRPOP, BRPOPLPUSH)
2.2, memory class information
Memory information currently used by used_memory ◦, peak memory consumption in bytes of used_memory_rss ◦ memory allocated to Redis by the current operating system used_memory_peak ◦ Redis, in bytes used_memory_peak_human ◦ returns the ratio between Redis's peak memory consumption mem_fragmentation_ratio ◦ used_memory_rss and used_memory in human-readable format
2.3. Running status class information
The number of commands executed by changes_since_last_save ◦ since the last time the database was saved, the number of save operations in progress by bgsave_in_progress ◦ in the background, the last point in time that last_save_time ◦ saved successfully Displays in UNIX timestamp format the number of aof file modifications in progress in the bgrewriteaof_in_progress ◦ background, the total number of clients connected since the total_connections_received ◦ run, the total number of commands executed since the total_commands_processed ◦ run, the total number of key expired since the expired_keys ◦ run, the number of times keyspace_hits ◦ hit key, the number of times keyspace_misses ◦ missed key.
Use the following command to monitor the information of redis's current dbindex
[root@localhost ~] # redis-cli info Keyspace# command output # Keyspacedb0:keys=4,expires=0,avg_ttl=0db1:keys=2,expires=0,avg_ttl=0db4:keys=4,expires=0,avg_ttl=0db9:keys=57,expires=0 Avg_ttl=0 related explanation: the first column ◦ represents the number of key contained under dbindex keys ◦ dbindex, the number of key with lifetime under expires ◦ dbindex, the number of avg_ttl ◦ dbindex survival time count, about "ways to monitor redis performance in real time" this article ends here. Hope that the above content can be helpful to you, so that you can learn more knowledge, if you think the article is good, please share it for more people to see.
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.