8

UPDATE: I have solved the problem,from the log, I saw that the db was opening and closing frequently. I had put the redis creation in a for loop. So...foolish question,if anyone's log like me, check for looping.

I tried shutting it down and restarting, but it still happened. Here's the error message:

redis.exceptions.ConnectionError: Error 99 connecting localhost:6379. Cannot assign requested address.

I was trying to insert 300000 records into redis (my memory is big enough). But after I inserted about 30000 record in it,then an error occurs:

  redis.exceptions.ConnectionError: Error 99 connecting localhost:6379. Cannot assign   requested address.

After looking at the log file,it looks like the redis closed after I successful insert 30000 records into it.

the following is some part of my logfile:

[32176] 11 Jun 20:59:27 - Accepted 127.0.0.1:36578
[32176] 11 Jun 20:59:27 - Client closed connection
[32176] 11 Jun 20:59:27 - Accepted 127.0.0.1:52327
[32176] 11 Jun 20:59:27 - Client closed connection
[32176] 11 Jun 20:59:27 - Accepted 127.0.0.1:52367
[32176] 11 Jun 20:59:27 - Client closed connection
[32176] 11 Jun 20:59:27 - Accepted 127.0.0.1:52368
[32176] 11 Jun 20:59:27 - Client closed connection
[32176] 11 Jun 20:59:27 - Accepted 127.0.0.1:52369
[32176] 11 Jun 20:59:27 - Client closed connection
[32176] 11 Jun 20:59:27 - Accepted 127.0.0.1:52370
[32176] 11 Jun 20:59:27 - Client closed connection
[32176] 11 Jun 20:59:28 - DB 6: 28226 keys (0 volatile) in 32768 slots HT.
[32176] 11 Jun 20:59:28 - 0 clients connected (0 slaves), 9181112 bytes in use
[32176] 11 Jun 20:59:33 - DB 6: 28226 keys (0 volatile) in 32768 slots HT.
[32176] 11 Jun 20:59:33 - 0 clients connected (0 slaves), 9181112 bytes in use
[32176] 11 Jun 20:59:38 - DB 6: 28226 keys (0 volatile) in 32768 slots HT.
[32176] 11 Jun 20:59:38 - 0 clients connected (0 slaves), 9181112 bytes in use
[32176] 11 Jun 20:59:43 - DB 6: 28226 keys (0 volatile) in 32768 slots HT.
[32176] 11 Jun 20:59:43 - 0 clients connected (0 slaves), 9181112 bytes in use
Jeff Tratner
  • 16,270
  • 4
  • 47
  • 67
kuafu
  • 1,466
  • 5
  • 17
  • 28
  • just wondering - are you writing to disk? Can you share redis.conf file that you are using? Can you possibly run top (or something similar) while inserting records? – ali haider Jun 11 '12 at 13:40
  • my redis.conf is here:http://pastie.org/4067860 – kuafu Jun 11 '12 at 14:57

0 Answers0