【问题标题】:gRPC Name Resolution FailuregRPC 名称解析失败
【发布时间】:2019-07-28 09:24:27
【问题描述】:

在尝试使用 docker 运行 tensorflow-serving 时,我收到以下错误,使用带有以下代码的 gRPC 发出客户端请求:

`python client.py --server=172.17.0.2/16:9000 --image=./test_images/image2.jpg

debug_error_string = "{"created":"@1551888435.208113000","description":"Failed to create subchannel","file":"src/core/ext/filters/client_channel/client_channel.cc","file_line":2267,"referenced_errors":[{"created":"@1551888435.208109000","description":"Name resolution failure","file":"src/core/ext/filters/client_channel/request_routing.cc","file_line":165,"grpc_status":14}]}"`

关于我的环境的信息:

操作系统:macOS 虚拟环境:Anaconda 3 Python 3.6 gRPC/tools 1.19

您能帮我解决这个问题吗?

【问题讨论】:

    标签: docker tensorflow-serving grpc-python


    【解决方案1】:

    当通道处于 TRANSIENT_FAILURE 并且负载平衡策略找不到任何准备好发送请求的后端时会发生这种情况。

    请在https://github.com/grpc/grpc/ 上提交问题,详细说明您所做的事情,希望提供更多日志/跟踪上下文,以便我们更好地帮助您。

    【讨论】:

    【解决方案2】:

    看起来略有不同的 IP 地址172.17.0.2/16 似乎是导致问题的原因。您可以改用localhost

    所以,运行client.py的命令可以是

    python client.py --server=localhost:9000 --image=./test_images/image2.jpg
    

    【讨论】:

      猜你喜欢
      • 2020-09-18
      • 1970-01-01
      • 1970-01-01
      • 2021-06-09
      • 2020-05-21
      • 1970-01-01
      • 2020-07-08
      • 2012-04-18
      • 1970-01-01
      相关资源
      最近更新 更多