google / gnxi

gNXI Tools - gRPC Network Management/Operations Interface Tools
Apache License 2.0
260 stars 115 forks source link

rpc error: code = DeadlineExceeded desc = context deadline exceeded #333

Open nskalis opened 1 year ago

nskalis commented 1 year ago

Hi, and thank you for making the gnxi utilities available.

The binaries have been built and installed without any errors using golang go1.17.13. But,

I am failing to contact a router using gnmi_capabilities (or gnmi_get). The error message is as follows:

~/go/bin/gnmi_capabilities -target_name "prod-lab03a-rd1" -target_addr x.x.x.x:57400 -username xxx -password xxx -alsologtostderr -logtostderr -v 1 -insecure true -notls true 
F0426 11:26:02.260135    6501 gnmi_capabilities.go:59] error in getting capabilities: rpc error: code = DeadlineExceeded desc = context deadline exceeded

while there is connectivity:

> nc -vz x.x.x.x 57400
Connection to x.x.x.x 57400 port [tcp/*] succeeded!

Using another grpc client, it succeeds as well:

/usr/local/sbin/gnmic --address x.x.x.x:57400 --username xxx --password xxx --insecure capabilities

Do you have perhaps any idea what might be going wrong here?

JoseIgnacioTamayo commented 1 year ago

" gnmi_capabilities -notls -insecure " == This tells gnmic_capabilities to do a non-TLS connection and at the same time, to do a non-verified TLS connection. I think you should use only --notls.