一,查看redis所有配置
使用命令:
CONFIG GET *
例:
127.0.0.1:6379> CONFIG GET *
1) "cluster-announce-bus-port"
2) "0"
3) "syslog-ident"
4) "redis"
5) "enable-module-command"
6) "no"
7) "min-slaves-to-write"
8) "0"
9) "cluster-enabled"
10) "no"
二,查看单个配置
127.0.0.1:6379> config get aof-use-rdb-preamble
1) "aof-use-rdb-preamble"
2) "yes"
三,查看全部状态
127.0.0.1:6379> info
# Server
redis_version:7.2.5
redis_git_sha1:00000000
redis_git_dirty:0
redis_build_id:980b4f44272b36a1
redis_mode:standalone
os:Linux 5.14.0-437.el9.x86_64 x86_64
arch_bits:64
monotonic_clock:POSIX clock_gettime
multiplexing_api:epoll
atomicvar_api:c11-builtin
gcc_version:11.4.1
process_id:248074
process_supervised:no
....
四,查看单个状态:
127.0.0.1:6379> info cpu
# CPU
used_cpu_sys:13.881941
used_cpu_user:13.274817
used_cpu_sys_children:0.001730
used_cpu_user_children:0.000563
used_cpu_sys_main_thread:13.880884
used_cpu_user_main_thread:13.274786
127.0.0.1:6379> info memory
# Memory
used_memory:1186112
used_memory_human:1.13M
used_memory_rss:10878976
used_memory_rss_human:10.38M
used_memory_peak:1406384
used_memory_peak_human:1.34M
used_memory_peak_perc:84.34%
used_memory_overhead:868232
...
五,查看redis的版本:
127.0.0.1:6379> info server
# Server
redis_version:7.2.5
redis_git_sha1:00000000
redis_git_dirty:0
redis_build_id:980b4f44272b36a1
redis_mode:standalone
os:Linux 5.14.0-437.el9.x86_64 x86_64
...
或
[sysop@blog conf]$ /usr/local/soft/redis7/bin/redis-cli --version
redis-cli 7.2.5
标签:used,cli,0.1,redis,6379,memory,cpu,客户端 From: https://www.cnblogs.com/architectforest/p/18293318