TimeoutError: (9, 'Failed to connect', 'src/main/aerospike/as_cluster.c', 395, False)

Hi I have these command

config = { ‘hosts’: [ (‘10.3.48.161’, 3000), (‘10.3.48.248’, 3000), (‘10.3.50.138’, 3000), (‘10.3.51.160’, 3000)] }

write_policies = {‘total_timeout’: 20000, ‘max_retries’: 0}

read_policies = {‘total_timeout’: 15000, ‘max_retries’: 1}

policies = {‘write’: write_policies, ‘read’: read_policies}

config[‘policies’] = policies

client = aerospike.client(config)

client.connect()

But I get this error:

TimeoutError: (9, ‘Failed to connect’, ‘src/main/aerospike/as_cluster.c’, 395, False)

Any ideas to fix this? Many thanks

Are you able to telnet to port 3000 against those IP addresses from where the client is running and did you make sure the server nodes did successfully come up?

Hi thanks for your answer! All server nodes are ok and I’ve fixed the error by changing version and found out that aerospike version > 4.0.0 caused this.