Problem with netcat and memcached

Vicente Arteaga varteaga at
Wed Feb 9 00:16:35 PST 2005

Hi, it's me again,

It doesn't happen all the time.

Strangely, it happens more frequently when  I connect remotely, than if 
I connect to localhost, and the most (I don't know why, but it's true), 
when I connect from a SuSE 9.1 to a RedHat 7.3, than the other way 
around. (Both same exact hardware: HP Netservers Pentium III 800 Mhz, 1 
GB Ram)


Brad Fitzpatrick wrote:

>Yes, I see how that could happen in the source.
>The fix is pretty easy, but I can't reproduce quickly, so I don't want to
>fix it blindly.  What sized object is your "is_ok"?
>On Tue, 8 Feb 2005, Vicente Arteaga wrote:
>>Hi Everyone!
>>I've done the following script to check that memcached has a key in it's
>>inside, and thus know that it's working correctly:
>>echo -e "get is_ok\r\nquit\r\n" | netcat $host $ip
>>and I find that sometimes it returns the VALUE in it's inside, but other
>>The only way to be able to receive it correctly is to delay a second
>>between command and command:
>>echo -e "get is_ok\r\nquit\r\n" | netcat -i1 $host $ip
>>Maybe there is a race condition inside memcached that if it receives a
>>quit it closes the connection even when there is data to send?
>>Vicente Arteaga
>>Tecnobe Tecnología, S.L.
>>C/ Diagonal, 34A 3o1a
>>08290 Cerdanyola del Valles
>>93 580 98 95

Vicente Arteaga
Tecnobe Tecnología, S.L.
C/ Diagonal, 34A 3o1a
08290 Cerdanyola del Valles
93 580 98 95

-------------- next part --------------
A non-text attachment was scrubbed...
Name: varteaga.vcf
Type: text/x-vcard
Size: 307 bytes
Desc: not available
Url :

More information about the memcached mailing list