容器初始化失败-在Kubernetes中使用Helm图表部署Artifactory
我试着用头盔图表安装jfrog人工工厂。容器初始化失败-在Kubernetes中使用Helm图表部署Artifactory,kubernetes,kubernetes-helm,Kubernetes,Kubernetes Helm,我试着用头盔图表安装jfrog人工工厂。 artifactory-0pod正在无限期地等待容器初始化 我使用此链接安装Jfrog Artifactory 我使用的是kubernetes v1.14。本地虚拟机,ESXI管理程序 编辑2/3月 PV: 聚氯乙烯: 编辑3月4日 StorageClass: NAME PROVISIONER AGE managed-nfs-storage fuseim.pri/ifs
artifactory-0
pod正在无限期地等待容器初始化
我使用此链接安装Jfrog Artifactory
我使用的是kubernetes v1.14。本地虚拟机,ESXI管理程序
编辑2/3月 PV: 聚氯乙烯:
编辑3月4日 StorageClass:
NAME PROVISIONER AGE
managed-nfs-storage fuseim.pri/ifs 132d
standard kubernetes.io/no-provisioner 156d
编辑2006年3月 聚氯乙烯(2006年3月):
编辑09/03 聚氯乙烯: kubectl获取事件--排序依据='.lastTimestamp':
2m7s Normal Created pod/artifactory-oss-artifactory-0 Created container wait-for-db
2m7s Normal Started pod/artifactory-oss-artifactory-0 Started container wait-for-db
100s Normal Started pod/artifactory-oss-postgresql-0 Started container init-chmod-data
100s Normal Created pod/artifactory-oss-postgresql-0 Created container init-chmod-data
100s Normal Pulled pod/artifactory-oss-postgresql-0 Successfully pulled image "docker.io/bitnami/minideb:stretch"
72s Warning BackOff pod/artifactory-oss-postgresql-0 Back-off restarting failed container
62s Warning VolumeFailedDelete persistentvolume/pvc-97666796-67b0-4152-b801-2cd84dcbc106 remove /persistentvolumes/default-artifactory-volume-artifactory-oss-artifactory-0-pvc-97666796-67b0-4152-b801-2cd84dcbc106/bootstrap/access/etc/security/join.key: permission denied
58s Normal Pulling pod/artifactory-oss-postgresql-0 Pulling image "docker.io/bitnami/minideb:stretch"
54s Warning Unhealthy pod/artifactory-oss-artifactory-nginx-54b677c764-2lpws Readiness probe failed: Get http://192.168.233.227:80/router/api/v1/system/health: net/http: request canceled (Client.Timeout exceeded while awaiting headers)
51s Warning Unhealthy pod/artifactory-oss-artifactory-nginx-54b677c764-2lpws Liveness probe failed: Get http://192.168.233.227:80/router/api/v1/system/health: net/http: request canceled (Client.Timeout exceeded while awaiting headers)
42s Warning VolumeFailedDelete persistentvolume/pvc-f2b1461f-35b5-4199-9395-6b0b4ff7ea05 remove /persistentvolumes/default-artifactory-volume-artifactory-oss-artifactory-0-pvc-f2b1461f-35b5-4199-9395-6b0b4ff7ea05/bootstrap/access/etc/security/join.key: permission denied
kubectl获得吊舱:
NAME READY STATUS RESTARTS AGE
artifactory-oss-artifactory-0 0/1 Init:3/5 0 12m
artifactory-oss-artifactory-nginx-54b677c764-2lpws 0/1 Running 6 12m
artifactory-oss-postgresql-0 0/1 Init:CrashLoopBackOff 7 12m
“FailedBinding:没有可用于此声明的持久卷,也没有设置存储类”
- 你可以从中了解更多
StorageClass
,但是没有一个设置为默认值。
- 将此注释添加到
上,以使其成为要部署artifactory oss的默认值(用SC替换StorageClass
)
kubectl patch-storageclass-p'{“metadata”:{“annotations”:{“storageclass.kubernetes.io/是默认类”:“true”}
了解更多关于
此外,我强烈建议:
- 检查这些
是否正确配置StorageClass
- 您可以按照以下步骤检查您的
标准是否正确
- 将帮助您验证第二个
- 您可以按照以下步骤检查您的
编辑: 根据我上面的建议,我们开始发现您的环境中存在不同的问题,因此为了帮助您,我将为您提供一些疑难解答页面,以便您可以测试环境的组件: 在您的日志中,我看到您正在尝试设置NFS存储,因此我建议:
- 首先,尝试将本地存储设置为
,并在那里部署,如果一切正常,您就会知道问题出在您的NFS设置上default
- :按照以下步骤设置并部署一个更简单的helm chard,这样您就可以确保NFS配置正确。了解更多信息:
- :在这里,您可以找到有关尝试部署的应用程序的说明
- 并检查--设置有助于您的参数
- 如果在对安装进行故障排除后,您认为这是一个bug,并直接从开发人员社区获得支持
kubectl get events--sort by='.lastTimestamp'
12s正常故障绑定persistentvolumeclaim/data-artifactory-postgresql-0此声明没有可用的持久卷,也没有设置存储类。但是,我指定了此POD要使用的PV和PVC。您能给我一些建议吗有关k8s运行位置的详细信息我的k8s运行的是本地虚拟机。虚拟机监控程序是Esxii。在将我的一个存储类设置为默认存储后,添加了我的pvc详细信息,请检查它。任何卷都使用默认存储连接到pvcclass@SridharP设置为默认设置后,您将完全删除已损坏的安装并重试?如果是,请继续我有问题,请更新日志、事件和状态以了解错误所在。卸载了以前的artifactory并重新安装,但没有出现pod。请检查我添加的pvc、状态和事件。@SridharP由于您使用NFS作为存储,您能试着在部署期间传递这些参数吗?--set artifactory.persistence.type=nfs--设置artifactory.persistence.nfs.ip=${nfs_ip}
(并将nfs_ip设置为nfs ip的环境变量。Ref:@SridharP我还更新了我的答案,并提供了更多疑难解答步骤。如果我的答案有用,请单击upvote按钮(▲) 在它的左边。这样其他人就知道你得到了帮助。另请参见“
NAME STATUS VOLUME CAPACITY ACCESS MODES STORAGECLASS AGE
artifactory-volume-artifactory-oss-artifactory-0 Pending standard 24s
data-artifactory-oss-postgresql-0 Pending standard 6s
artifactory-volume-artifactory-oss-artifactory-0 Bound pvc-3804670b-3e13-4162-bbf9-bb945c45ddbd 10Gi RWO managed-nfs-storage 16m
data-artifactory-oss-postgresql-0 Bound pvc-18a744d3-3f3d-4a36-b8bc-7ecc593fc04d 10Gi RWO managed-nfs-storage 16m
s
2m7s Normal Created pod/artifactory-oss-artifactory-0 Created container wait-for-db
2m7s Normal Started pod/artifactory-oss-artifactory-0 Started container wait-for-db
100s Normal Started pod/artifactory-oss-postgresql-0 Started container init-chmod-data
100s Normal Created pod/artifactory-oss-postgresql-0 Created container init-chmod-data
100s Normal Pulled pod/artifactory-oss-postgresql-0 Successfully pulled image "docker.io/bitnami/minideb:stretch"
72s Warning BackOff pod/artifactory-oss-postgresql-0 Back-off restarting failed container
62s Warning VolumeFailedDelete persistentvolume/pvc-97666796-67b0-4152-b801-2cd84dcbc106 remove /persistentvolumes/default-artifactory-volume-artifactory-oss-artifactory-0-pvc-97666796-67b0-4152-b801-2cd84dcbc106/bootstrap/access/etc/security/join.key: permission denied
58s Normal Pulling pod/artifactory-oss-postgresql-0 Pulling image "docker.io/bitnami/minideb:stretch"
54s Warning Unhealthy pod/artifactory-oss-artifactory-nginx-54b677c764-2lpws Readiness probe failed: Get http://192.168.233.227:80/router/api/v1/system/health: net/http: request canceled (Client.Timeout exceeded while awaiting headers)
51s Warning Unhealthy pod/artifactory-oss-artifactory-nginx-54b677c764-2lpws Liveness probe failed: Get http://192.168.233.227:80/router/api/v1/system/health: net/http: request canceled (Client.Timeout exceeded while awaiting headers)
42s Warning VolumeFailedDelete persistentvolume/pvc-f2b1461f-35b5-4199-9395-6b0b4ff7ea05 remove /persistentvolumes/default-artifactory-volume-artifactory-oss-artifactory-0-pvc-f2b1461f-35b5-4199-9395-6b0b4ff7ea05/bootstrap/access/etc/security/join.key: permission denied
NAME READY STATUS RESTARTS AGE
artifactory-oss-artifactory-0 0/1 Init:3/5 0 12m
artifactory-oss-artifactory-nginx-54b677c764-2lpws 0/1 Running 6 12m
artifactory-oss-postgresql-0 0/1 Init:CrashLoopBackOff 7 12m
kubectl patch storageclass <your-class-name> -p '{"metadata": {"annotations":{"storageclass.kubernetes.io/is-default-class":"true"}}}'