问题描述
我是 KFServing 和 Kubeflow 的新手。
我跟随 https://github.com/kubeflow/kfserving/tree/master/docs/samples/v1alpha2/tensorflow 部署了一个简单的推理服务。
但是,在查看日志时,我找不到容器存储初始化程序。我的预测服务 pod 仅有的容器是 kfserving 和 queue-proxy。
我目前在 IBM Cloud 上使用 Kubeflow 1.2 和 Kubernetes 1.17。
解决方法
storage-initializer
是一个 init container,因此如果您描述 pod,您将不会在 pod 规范的 containers
部分中找到它,而是在 initContainers
部分中找到它。
$ kubectl get pod flowers-sample-predictor-default-00002-deployment-58bb9557sf7g2 -o json | jq .status.initContainerStatuses
[
{
"containerID": "docker://e40e5f86401b3715118b873fec4ae6c3ef57765ffbb5c9ab48757234c4f53b6f","image": "gcr.io/kfserving/storage-initializer:v0.5.0","imageID": "docker-pullable://gcr.io/kfserving/storage-initializer@sha256:1d396c0c50892f5562a1c24d925691ec786e5d48e08200f3f9bb17bb48da40ae","lastState": {},"name": "storage-initializer","ready": true,"restartCount": 0,"state": {
"terminated": {
"containerID": "docker://e40e5f86401b3715118b873fec4ae6c3ef57765ffbb5c9ab48757234c4f53b6f","exitCode": 0,"finishedAt": "2021-02-27T20:13:25Z","reason": "Completed","startedAt": "2021-02-27T20:13:11Z"
}
}
}
]
我不熟悉您使用的 model
标签,您可以使用 app
标签或直接使用 pod 名称重试吗?
$ kubectl logs -l app=flowers-sample-predictor-default-00002 -c storage-initializer
[I 210227 20:13:12 initializer-entrypoint:13] Initializing,args: src_uri [gs://kfserving-samples/models/tensorflow/flowers] dest_path[ [/mnt/models]
[I 210227 20:13:12 storage:43] Copying contents of gs://kfserving-samples/models/tensorflow/flowers to local
[W 210227 20:13:15 _metadata:104] Compute Engine Metadata server unavailable onattempt 1 of 3. Reason: timed out
[W 210227 20:13:15 _metadata:104] Compute Engine Metadata server unavailable onattempt 2 of 3. Reason: [Errno 113] No route to host
[W 210227 20:13:18 _metadata:104] Compute Engine Metadata server unavailable onattempt 3 of 3. Reason: timed out
[W 210227 20:13:18 _default:250] Authentication failed using Compute Engine authentication due to unavailable metadata server.
[I 210227 20:13:19 storage:127] Downloading: /mnt/models/0001/saved_model.pb
[I 210227 20:13:19 storage:127] Downloading: /mnt/models/0001/variables/variables.data-00000-of-00001
[I 210227 20:13:25 storage:127] Downloading: /mnt/models/0001/variables/variables.index
[I 210227 20:13:25 storage:76] Successfully copied gs://kfserving-samples/models/tensorflow/flowers to /mnt/models