/********* redis server指令操作 *************/
bgrewriteaof -
summary: asynchronously rewrite the append-only file
since: 1.0.0
bgsave -
summary: asynchronously save the dataset to disk
client getname -
summary: get the current connection name
since: 2.6.9
client kill ip:port
summary: kill the connection of a client
since: 2.4.0
client list -
summary: get the list of client connections
client setname connection-name
summary: set the current connection name
config get parameter
summary: get the value of a configuration parameter
since: 2.0.0
config resetstat -
summary: reset the stats returned by info
config set parameter value
summary: set a configuration parameter to the given value
dbsize -
summary: return the number of keys in the selected database
debug object key
summary: get debugging information about a key
debug segfault -
summary: make the server crash
flushall -
summary: remove all keys from all databases
flushdb -
summary: remove all keys from the current database
info [section]
summary: get information and statistics about the server
lastsave -
summary: get the unix time stamp of the last successful save to disk
monitor -
summary: listen for all requests received by the server in real time
save -
summary: synchronously save the dataset to disk
shutdown [nosave] [save]
summary: synchronously save the dataset to disk and then shut down the server
slaveof host port
summary: make the server a slave of another instance, or promote it as master
slowlog subcommand [argument]
summary: manages the redis slow queries log
since: 2.2.12
sync -
summary: internal command used for replication
time -
summary: return the current server time
since: 2.6.0
/**************** redis scripting 指令操作 *************/
eval script numkeys key [key ...] arg [arg ...]
summary: execute a lua script server side
evalsha sha1 numkeys key [key ...] arg [arg ...]
script exists script [script ...]
summary: check existence of scripts in the script cache.
script flush -
summary: remove all the scripts from the script cache.
script kill -
summary: kill the script currently in execution.
script load script
summary: load the specified lua script into the script cache.