那棵树看起来生气了
[常见错误]TensorFlow Serving grpg错误
12/26
前言
在进行部署TensorFlow Serving环境过程中,总是报错(如下错误信息),刚开始以为是服务器没有启动,后来才发现是代理问题
<_Rendezvous of RPC that terminated with:
status = StatusCode.UNAVAILABLE
details = "Socket closed"
debug_error_string = "{"created":"@1545792723.752821509","description":"Error received from peer","file":"src/core/lib/surface/call.cc","file_line":1036,"grpc_message":"Socket closed","grpc_status":14}"
>
解决过程
- 查看服务器是否启动
telnet localhost 50051
使用telnet命令发现端口是打开的,所以排除是服务器启动失败造成的。
- 关闭服务器
后来我关闭服务器,再次启动,发现客户端报错仍然是这个,我就想服务器和客户端之间一定存在某种障碍,然后就想到了是不是代理的问题。
- 查看代理
使用命令查看代理是否存在,果然有代理,试着关闭代理
env | grep proxy
https_proxy=http://*:888
- 关闭所有代理
unset http_proxy
- 再次启动服务器,客户端,成功
[root@dyb example]# python ./mnist_client.py --num_tests=1000 --server=127.0.0.1:50051
Extracting /tmp/train-images-idx3-ubyte.gz
Extracting /tmp/train-labels-idx1-ubyte.gz
Extracting /tmp/t10k-images-idx3-ubyte.gz
Extracting /tmp/t10k-labels-idx1-ubyte.gz
........................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................
Inference error rate: 9.1%
[root@dyb example]#
三合一收款
下面三种方式都支持哦