Can you describe how the client and server are connected? i.e. is this on your laptop connecting to a Docker container? Are you in a particular cloud provider?
Typically a timeout at this early stage is caused by some networking issue in between the client and server rather than a bug or performance issue.
You can also try using the sdk doctor to get more connection diagnostics:
(also note that version 4 of the Python SDK is available now, I don’t have any reason to suspect that upgrading would resolve the issue you’re having, but good to be aware of the latest version )
Hi , When I am trying to connect couchbase server from my laptop using python sdk locally its working,
But when when i am trying to connect my same standalone application in remote desktop , then I am facing this issue(time out issue).
Hi , When I am trying to connect couchbase server from my laptop using python sdk locally its working,
But when when i am trying to connect my same standalone application in remote desktop , then I am facing this issue(time out issue). we are using latest sdk 4.
But we have java application which is running fine for both local and remote
Hi @abhijsar – Sorry, since you are using the 4.x SDK, the logging is different (we use our C++ SDK and not the C SDK as the 3.x version of the Python SDK did). See the 4.x logging documentation here. A quick way to get log information for the SDK is as follows (be sure to change test_script.py to the name of your python script). Also, you can use debug or trace logging levels as those will provide the most information for debugging purposes.
PYCBC_LOG_LEVEL=trace python test_script.py
Also as @perry has noted, using SDK Doctor is a good tool to use to make sure your connection is okay.
hi @jcasey@perry
getting this after using sdk doctor :
Summary:
e[33m[WARN]e[0m No certificate authority file specified (–tls-ca), skipping server certificate verification for this run.
e[33m[WARN]e[0m Your connection string specifies only a single host. You should consider adding additional static nodes from your cluster to this list to improve your applications fault-tolerance
e[31m[ERRO]e[0m Failed to fetch configuration via cccp from npcchbs69.abc.xyz.com:11207 (error: dial tcp 172.22.274.101:11207: i/o timeout)
e[31m[ERRO]e[0m Failed to fetch terse configuration via http from npcchbs69.abc.xyz.com:18091 (error: Get “http://npcchbs69.abc.xyz.com:18091/pools/default/b/”: net/http: HTTP/1.x transport connection broken: malformed HTTP response “\x15\x03\x03\x00\x02\x02”)
e[31m[ERRO]e[0m All endpoints specified by your connection string were unreachable, further cluster diagnostics are not possible.
It looks to me like some pretty low-level networking issue is blocking communication. This is usually due to a firewall (or security group) configuration.
Can you share some more details on exactly how this is all setup? You mention a remote desktop…is that running on a cloud instance (and if so, which provider?). Is it Windows or Linux? Is Couchbase running in another cloud instance? Windows or Linux? Or is this all in your local datacenter/home network? Any docker, kubernetes or load balancers? And you mentioned that a java application is running fine…is that running in the exact same remote desktop and using the exact same connection string?
Sorry for all the questions, just trying to get a complete picture to identify some potential areas for digging into. If you have a license to our Enterprise Edition it might be worth opening a support ticket with the team, they’ll probably ask a lot of the same questions though