TCPSocket.new Errno::EBADF: Bad file descriptor error

Im trying to use memcache-client, but there is a line in their where it
calls:

TCPSocket.new(host, port). It fails at this point. I’ve tried just
trying to establish a connection in my script/console with

TCPSocket.new(“localhost”, 11211)
TCPSocket.new(“127.0.0.1”, 11211)
TCPSocket.new("", 11211)
TCPSocket.new("", 11211)

And I also tried with different ports. I had my Norton AV firewall
turned off as well and even tried this on my friends computer in the
script/console environment.

We have not been able to get a connection established in any attempts.

Does anyone know what might be wrong?