08:16:12 GMT is there a way to fetch n elements from a redis set? 08:16:28 GMT I dont want to use `smembers` as the set in question is huge. 08:25:38 GMT dhanush: http://redis.io/commands/#set SRANDMEMBER probably 08:26:40 GMT minus: aha! 08:26:45 GMT I missed it somehow. 12:38:53 GMT how to optimize redis performance 12:43:55 GMT buy faster hardware 12:44:22 GMT or try this http://redis.io/topics/memory-optimization 13:03:11 GMT optimize which part? 13:20:50 GMT hi all. my master slave replication is broken this morning and i can't figure out why. i've restarted redis on both the master and slave... but anytime I run INFO REPLICATION on the slave it shows the link as "down" 13:21:19 GMT I've tried to run netstat -lnp on both the slave and master... and I do see references to the port 6379 13:21:46 GMT specifically, if the master's ip address is 10.1.2.3 then I see this in the netstat -lnp output: 13:22:14 GMT tcp 0 0 127.0.0.1:6379 0.0.0.0:* LISTEN 21399/redis-server 13:22:14 GMT tcp 0 0 10.1.2.3:6379 0.0.0.0:* LISTEN 21399/redis-server 13:22:24 GMT and on the slave i see: 13:22:42 GMT tcp 0 0 0.0.0.0:6379 0.0.0.0:* LISTEN 5577/redis-server 13:22:42 GMT tcp 0 0 :::22 :::* LISTEN 1857/sshd 13:22:42 GMT tcp 0 0 :::6379 :::* LISTEN 5577/redis-server 13:23:29 GMT I've also retried running the command "slaveof 10.1.2.3 6379" in the cli on the slave... 13:23:46 GMT and i get this message: 127.0.0.1:6379> slaveof 10.1.2.3 6379 13:23:46 GMT OK Already connected to specified master 13:23:46 GMT 127.0.0.1:6379> 13:23:55 GMT not sure what else I should check 14:09:35 GMT @cpama logfiles? and try to telnet to master/slave ip/port? also you need 'dir' and 'dbfilename' set in redis conf. also are you binding to the right ips. .. thats all i can think of 14:10:04 GMT kablamo, i just rebooted the slave... and it came back. 14:10:05 GMT :( 14:10:08 GMT worries me 14:10:45 GMT i will check the settings you mention in redis.conf right now on the master.... 14:15:38 GMT kablamo, this is what I have the redis.conf file on the master: 14:15:39 GMT # The filename where to dump the DB 14:15:39 GMT dbfilename dump.rdb 14:15:46 GMT looks like just the default value right? 14:16:01 GMT and then in the folder /var/lib/redis i have a dump.rdb file 14:16:23 GMT is it ok to leave as is kablamo? 14:20:14 GMT i think i know how I broke the replication kablamo 14:20:28 GMT I tried to add a requirepass value on the master. 14:20:34 GMT restarted redis on master 14:20:49 GMT and then on slave... i added the same password value in the "masterauth" field in the config file 14:20:55 GMT and then restarted slave. 14:21:17 GMT then when I run redis-cli on the slave and check INFO REPLICATION it shows that the master link is down 14:21:50 GMT earlier in the day, I undid the password set up... and thought replication would just start working again... but I think this must be what broke it in the first place. 15:22:17 GMT anyone have suggestions/best practice for renaming a key in redis-cluster across slots? 17:19:55 GMT Hey all - whats the easiest way to do a disk backup of the redis database? 17:20:03 GMT can I just copy dump.rdb to some other spot? 17:21:39 GMT that's a possibility 17:23:48 GMT minus: guaranteed to work? 17:24:05 GMT it's always complete, yes 17:24:20 GMT I have a few days worth of setting up a nice database, and I want to be able to powercycle the box but be able to load that up again in a week, for example 17:24:25 GMT you could do a manual save/bgsave too i guess 17:24:44 GMT I don't need to do the backup as it stands, right? 17:24:56 GMT well, if you don't remove the .rdb you don't have to back it up anywhere 17:24:58 GMT Like, you can powercycle a box and bring redis back up and data is still there? 17:25:00 GMT yeah 17:25:02 GMT ok 17:25:08 GMT I'm going to make one just in case 17:26:10 GMT also thanks for your help the last few days of questions - wrapping up the project now, redis is wonderful 17:36:19 GMT hello there! I am trying to mix in lau script KEYS * command and DEL command, redis.call('DEL', *redis.call('KEYS', KEYS[1])) - I can not find any information how to converts result from KEYS to list of keys for delete command. 17:36:44 GMT asterisk - is how it can be for example in Python 18:02:31 GMT Hello. I'm seeing a really weird bug that I can't explain. I have a redis list to which I LPUSH entries. the thing is, I see entries disappearing off this list all the time (And I'm not crazy, I have redis MONITOR open before my eyes and the log can't explain this) 18:03:19 GMT E.g. list X had 4 entries, a minute has passed, and some client pops off that list what should've been the second entry - then I look at the list and there are only 2 entries 18:03:38 GMT and there's nothing in the log thatcan explain this 18:04:18 GMT where does the backed up database reside? minus 18:06:13 GMT you mean the rdb file? 18:06:52 GMT /var/lib/redis usually 18:07:34 GMT I thought everytime I shut-down my LXC container that the Redis-DB was being removed/deleted. then I found out that the data persists in it 20:36:45 GMT Hello, i have 3 set, lets call a,b and c i want to get bUc\a (in other words (b+c)-a) is it possible? 20:42:40 GMT hm i found it sunionstore tmp b c, sdiff tmp a, thanks anyway