redis-cli keys "sess*" | while read LINE ;do echo `redis-cli EXPIRE $LINE 10000`; done;
NOTE: "sess*" will be replaced by the key name and 10000 will be replaced by time you want to set for expiry (will be in seconds)
NOTE: "sess*" will be replaced by the key name and 10000 will be replaced by time you want to set for expiry (will be in seconds)
Comments
Post a Comment