我已经在 aws 上设置了 kops 集群,并且还在集群中安装了 helm。
我正在尝试使用图表安装 easltic/elasticsearch。我需要修改我在 .home{
height: 500px;
width: 100%;
}
#main{
width: 100%;
height: 100%;
}
#show-image{
width: 100%;
height: 100%;
display: flex;
justify-content: center;
align-items: center ;
}
.information{
width: 100%;
height: 30%;
display: flex;
align-items: center;
justify-content: center;
text-align: center;
}
#about{
height: 630px;
margin-top: 50px;
margin-bottom: 50px;
padding-top: 10px;
padding-bottom: 10px;
}
#guideline{
height: 500px;
margin-top: 50px;
margin-bottom: 50px;
padding-top: 10px;
padding-bottom: 10px;
}
.intro{
height: 63px;
margin-bottom: 30px;
margin-top: 10px;
display: flex;
justify-content: center;
align-items: center;
text-align: center ;
background: grey;
}
.function{
width: 100%;
height: 90%;
padding-left: 50px;
padding-right: 50px;
}
.mission{
width: 100%;
height: 100%;
display: flex;
justify-content: center;
padding-top: 30px;
align-items: left;
text-align: left;
font-size: 20px;
}
.guideline_text{
width: 100%;
height: 50%;
padding-top: 50px;
word-wrap: break-word;
font-size: 20px;
text-align: center;
}
文件下创建的默认卷大小。
values.yml
我是这样安装的,
# Allocate smaller chunks of memory per pod
resources:
requests:
cpu: "100m"
memory: "512M"
limits:
cpu: "1000m"
memory: "512M"
# Request smaller persistent volume
volumeClaimTemplate:
accessModes: [ "ReadWriteOnce" ]
storageClassName: default
resources:
requests:
storage: 10Gi
安装成功,但现在pods卡在pending状态
helm install elasticsearch -n logging elastic/elasticsearch -f values.yml
更新:
[ec2-user@ip-my elastic-search]$ kubectl get pods -n logging
NAME READY STATUS RESTARTS AGE
elasticsearch-master-0 0/1 Pending 0 6m35s
elasticsearch-master-1 0/1 Pending 0 6m35s
elasticsearch-master-2 0/1 Pending 0 6m35s
答案 0 :(得分:1)
您的集群中没有名为 standard
的 StorageClass。使用列表中的 storageClass 之一:
$ kubectl get storageclass
NAME PROVISIONER RECLAIMPOLICY VOLUMEBINDINGMODE ALLOWVOLUMEEXPANSION AGE
default kubernetes.io/aws-ebs Delete Immediate false 38d
gp2 kubernetes.io/aws-ebs Delete Immediate false 38d
kops-ssd-1-17 (default) kubernetes.io/aws-ebs Delete WaitForFirstConsumer true 38d
示例:
volumeClaimTemplate:
accessModes: [ "ReadWriteOnce" ]
storageClassName: default
resources:
requests:
storage: 10Gi