redis-cli的命令选项:
[gl@lx18 ~]$ redis-cli --help
redis-cli 2.4.16
Usage: redis-cli [OPTIONS] [cmd [arg [arg ...]]]
-pServer port (default: 6379)
-sServer socket (overrides hostname and port)
-aPassword to use when connecting to the server
-rExecute specified command N times
-iWhen -r is used, waitsseconds per command.
It is possible to specify sub-second times like -i 0.1.
-nDatabase number
-x Read last argument from STDIN
-dMulti-bulk delimiter in for raw formatting (default: \n)
--raw Use raw formatting for replies (default when STDOUT is not a tty)
--latency Enter a special mode continuously sampling latency.
--slave Simulate a slave showing commands received from the master.
--pipe Transfer raw Redis protocol from stdin to server.
--bigkeys Sample Redis keys looking for big keys.
--help Output this help and exit
--version Output version and exit
--raw 显示中文,而不是"\xd6\xd0"
redis 10.10.100.18:6379> set aaa 中
OK
redis 10.