SCRIPT KILL
Since 1.1.0ScriptingKnown issue
Syntax
SCRIPT KILLStops the script running, if it has not written anything. While a script has run longer than lua-time-limit (5 seconds by default), other clients' commands get BUSY Redis is busy running a script. You can only call SCRIPT KILL or SHUTDOWN NOSAVE.. SCRIPT KILL and SHUTDOWN NOSAVE still get through.
Reply
OK; the script's client getsERR Script killed by user.ERR No scripts in execution.if none is running.
Known issue
In KiviDB 1.1, SCRIPT KILL on a script that has already written replies OK, but the script goes on running, and the server stays busy until SHUTDOWN NOSAVE. Redis replies UNKILLABLE instead. Filed as kividb#129, fixed in 1.2.
Examples
client 1> EVAL "local i=0 while true do end" 0
client 2> GET greeting
(error) BUSY Redis is busy running a script. You can only call SCRIPT KILL or SHUTDOWN NOSAVE.
client 2> SCRIPT KILL
OK
client 1>
(error) ERR Script killed by user