karthik talam
karthik talam

Reputation: 514

How to solve tf_serving_entrypoint.sh: line 3: 6 Illegal instruction (core dumped) when using tensorflow/serving image

I have encountered this problem while deploying my model in the cloud using docker image tesorflow/serving:1.13.0. But it runs perfectly in my local system.

The actual logs from the cloud system are:

usr/bin/tf_serving_entrypoint.sh: line 3:     6 Illegal instruction     (core dumped) tensorflow_model_server --port=8500 --rest_api_port=8501 --model_name=${MODEL_NAME} --model_base_path=${MODEL_BASE_PATH}/${MODEL_NAME} "$@"

I have tried to using various images from the tensorflow serving docker registry and none of them worked.

This is my docker-compose file structure. And the mounting file structure. Structure of mounting folder

  tensorflow:
image: tensorflow/serving:1.13.0
container_name: tensorflow
environment:
  - MODEL_NAME=test
volumes:
  - ./data_pipeline/machine_learning/models/v1/:/models/test/1
ports:
  - 8501:8501

I expect the following result which lets us use the model which is being served for results. These are the logs which I obtain when the container is running.

2019-05-08 06:31:31.357564: I tensorflow_serving/model_servers/server.cc:82] Building single TensorFlow model file config:  model_name: test model_base_path: /models/test

2019-05-08 06:31:31.388148: I tensorflow_serving/model_servers/server_core.cc:461] Adding/updating models.

2019-05-08 06:31:31.388179: I tensorflow_serving/model_servers/server_core.cc:558]  (Re-)adding model: test

2019-05-08 06:31:31.496616: I tensorflow_serving/core/basic_manager.cc:739] Successfully reserved resources to load servable {name: test version: 1}

2019-05-08 06:31:31.496640: I tensorflow_serving/core/loader_harness.cc:66] Approving load for servable version {name: test version: 1}

2019-05-08 06:31:31.496651: I tensorflow_serving/core/loader_harness.cc:74] Loading servable version {name: test version: 1}

2019-05-08 06:31:31.496663: I external/org_tensorflow/tensorflow/contrib/session_bundle/bundle_shim.cc:363] Attempting to load native SavedModelBundle in bundle-shim from: /models/test/1

2019-05-08 06:31:31.496669: I external/org_tensorflow/tensorflow/cc/saved_model/reader.cc:31] Reading SavedModel from: /models/test/1

2019-05-08 06:31:31.600082: I external/org_tensorflow/tensorflow/cc/saved_model/reader.cc:54] Reading meta graph with tags { serve }

2019-05-08 06:31:31.626460: I external/org_tensorflow/tensorflow/core/platform/cpu_feature_guard.cc:141] Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX2 FMA

2019-05-08 06:31:31.657342: I external/org_tensorflow/tensorflow/cc/saved_model/loader.cc:182] Restoring SavedModel bundle.

2019-05-08 06:31:31.863963: I external/org_tensorflow/tensorflow/cc/saved_model/loader.cc:285] SavedModel load for tags { serve }; Status: success. Took 367280 microseconds.

2019-05-08 06:31:31.864020: I tensorflow_serving/servables/tensorflow/saved_model_warmup.cc:101] No warmup data file found at /models/test/1/assets.extra/tf_serving_warmup_requests

2019-05-08 06:31:31.864115: I tensorflow_serving/core/loader_harness.cc:86] Successfully loaded servable version {name: test version: 1}

2019-05-08 06:31:31.875615: I tensorflow_serving/model_servers/server.cc:313] Running gRPC ModelServer at 0.0.0.0:8500 ...

[warn] getaddrinfo: address family for nodename not supported
2019-05-08 06:31:31.883332: I tensorflow_serving/model_servers/server.cc:333] Exporting HTTP/REST API at:localhost:8501 ...

[evhttp_server.cc : 237] RAW: Entering the event loop ...

Can someone help me resolve this issue?

Upvotes: 4

Views: 2536

Answers (1)

karthik talam
karthik talam

Reputation: 514

I have solved this error by building binaries for respective CPU's on which i am working.

I have built the binaries from this link. tensorflow-serving from source using docker

I have pushed my images to dockerhub repository. If anyone donot want to build their own respective images with same configurations as of my CPU's.

Dockerhub repository for tensorflow-serving images for Centos built from source

Upvotes: 1

Related Questions