首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >nexus状态为挂起

nexus状态为挂起
EN

Stack Overflow用户
提问于 2019-09-03 17:11:01
回答 3查看 416关注 0票数 0

当我使用命令“bash oneclick_deploy.sh 2>&1 | tee aio_deploy.log”部署Acumos时,它不成功,并打印出“nexus is Pending”。

1I使用了现有的k8s集群:Minikube

2命令“bash system-integration/AIO/setup_prereqs.sh k8s localhost $USER generic 2>&1 | tee aio_prep.log”运行成功

kubectl get pods -all-namespaces

代码语言:javascript
复制
master@ubuntu:/home$ kubectl get pods --all-namespaces
NAMESPACE     NAME                                  READY   STATUS    RESTARTS   AGE
acumos        nexus-5b577d94f8-hqxxl                0/1     Pending   0          18m
kube-system   coredns-6967fb4995-p2sjh              1/1     Running   3          3d20h
kube-system   coredns-6967fb4995-p57ml              1/1     Running   3          3d20h
kube-system   etcd-minikube                         1/1     Running   0          5h14m
kube-system   kube-addon-manager-minikube           1/1     Running   2          3d20h
kube-system   kube-apiserver-minikube               1/1     Running   0          5h14m
kube-system   kube-controller-manager-minikube      1/1     Running   2          5h14m
kube-system   kube-proxy-2wqqp                      1/1     Running   1          3d20h
kube-system   kube-scheduler-minikube               1/1     Running   2          3d20h
kube-system   kubernetes-dashboard-95564f4f-wrjgj   1/1     Running   2          3d20h
kube-system   storage-provisioner                   1/1     Running   2          3d20h
kube-system   tiller-deploy-75f5747884-5rnmc        1/1     Running   0          5h8m

kubectl描述-n acumos pod nexus 5b577d94f8-hqxxl

代码语言:javascript
复制
master@ubuntu:/home$ kubectl describe -n acumos pod nexus-5b577d94f8-hqxxl
Name:           nexus-5b577d94f8-hqxxl
Namespace:      acumos
Priority:       0
Node:           <none>
Labels:         app=nexus
                pod-template-hash=5b577d94f8
Annotations:    <none>
Status:         Pending
IP:             
Controlled By:  ReplicaSet/nexus-5b577d94f8
Containers:
  nexus:
    Image:       sonatype/nexus:3.9.0
    Ports:       8081/TCP, 8082/TCP
    Host Ports:  0/TCP, 0/TCP
    Environment:
      log_level:  DEBUG
    Mounts:
      /maven/logs from logs (rw)
      /nexus-data from nexus-data (rw)
      /var/run/secrets/kubernetes.io/serviceaccount from default-token-r6d6c (ro)
Conditions:
  Type           Status
  PodScheduled   False 
Volumes:
  logs:
    Type:       PersistentVolumeClaim (a reference to a PersistentVolumeClaim in the same namespace)
    ClaimName:  logs
    ReadOnly:   false
  nexus-data:
    Type:       PersistentVolumeClaim (a reference to a PersistentVolumeClaim in the same namespace)
    ClaimName:  nexus-data
    ReadOnly:   false
  default-token-r6d6c:
    Type:        Secret (a volume populated by a Secret)
    SecretName:  default-token-r6d6c
    Optional:    false
QoS Class:       BestEffort
Node-Selectors:  <none>
Tolerations:     node.kubernetes.io/not-ready:NoExecute for 300s
                 node.kubernetes.io/unreachable:NoExecute for 300s
Events:
  Type     Reason            Age                From               Message
  ----     ------            ----               ----               -------
  Warning  FailedScheduling  47s (x2 over 47s)  default-scheduler  pod has unbound immediate PersistentVolumeClaims

这个问题困扰了我很长时间,一直没有得到解决,如果有人能指导我如何解决这个问题,我将不胜感激。

EN

回答 3

Stack Overflow用户

回答已采纳

发布于 2019-09-03 21:17:23

我可以帮你调试,但请注意,我们还没有在minikube环境中测试这些工具。Minikube与单节点(AIO) k8s集群有很大不同,很可能无法工作;还要注意,您可以使用脚本https://github.com/acumos/system-integration/blob/master/tools/setup_k8s.sh创建单节点集群(在Ubuntu或Centos上)。

但是对于您的minikube情况,pods状态的"pending“状态通常意味着PV还没有准备好分配给PVC。这可能是minikube的副作用。kubectl get pv的结果是什么?

票数 0
EN

Stack Overflow用户

发布于 2019-09-04 09:16:09

非常感谢。稍后,我将尝试使用该脚本在ubuntu上创建一个单节点集群。kubectl get pv的结果:

代码语言:javascript
复制
master@ubuntu:/mnt/hgfs$ kubectl get pv
NAME                 CAPACITY   ACCESS MODES   RECLAIM POLICY   STATUS      CLAIM   STORAGECLASS   REASON   AGE
docker-volume        5Gi        RWO            Recycle          Available                                   22h
elasticsearch-data   10Gi       RWO            Recycle          Available                                   22h
logs                 1Gi        RWO            Recycle          Available                                   22h
mariadb-data         5Gi        RWO            Recycle          Available                                   22h
nexus-data           10Gi       RWO            Recycle          Available                                   22h
nifi-registry        5Gi        RWO            Recycle          Available                                   22h
pv-10gi-1            10Gi       RWO            Recycle          Available                                   22h
pv-10gi-2            10Gi       RWO            Recycle          Available                                   22h
pv-10gi-3            10Gi       RWO            Recycle          Available                                   22h
pv-10gi-4            10Gi       RWO            Recycle          Available                                   22h
pv-10gi-5            10Gi       RWO            Recycle          Available                                   22h
pv-1gi-1             1Gi        RWO            Recycle          Available                                   22h
pv-1gi-2             1Gi        RWO            Recycle          Available                                   22h
pv-1gi-3             1Gi        RWO            Recycle          Available                                   22h
pv-1gi-4             1Gi        RWO            Recycle          Available                                   22h
pv-1gi-5             1Gi        RWO            Recycle          Available                                   22h
pv-5gi-1             5Gi        RWO            Recycle          Available                                   22h
pv-5gi-2             5Gi        RWO            Recycle          Available                                   22h
pv-5gi-3             5Gi        RWO            Recycle          Available                                   22h
pv-5gi-4             5Gi        RWO            Recycle          Available                                   22h
pv-5gi-5             5Gi        RWO            Recycle          Available                                   22h

kubectl get pvc --all-namespaces:

代码语言:javascript
复制
master@ubuntu:/home$ kubectl get pvc --all-namespaces
NAMESPACE   NAME         STATUS    VOLUME       CAPACITY   ACCESS MODES   STORAGECLASS   AGE
acumos      logs         Pending   logs         0                         standard       27h
acumos      nexus-data   Pending   nexus-data   0                         standard       158m
票数 0
EN

Stack Overflow用户

发布于 2019-09-04 09:45:07

页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/57768496

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档