我正在使用KOPS,并且我有一个包含3个主控的集群。我删除了一个master和磁盘(root disk和etcd disk(main和events))。
现在,kops重新创建了这个主节点和磁盘,但是这个新的主节点不能加入集群。kube-apiserver上的错误消息是
controller.go:135] Unable to perform initial IP allocation check: unable to refresh the service IP block: client: etcd cluster is unavailable or misconfigured; erro
在创建集群时,kops为我们提供了一组参数,用于配置用于主实例和节点实例的镜像,如create cluster命令的kops文档中所述:https://github.com/kubernetes/kops/blob/master/docs/cli/kops_create_cluster.md --image string Set image for all instances.
--master-image string Set image for masters. Takes precedence over --image
在使用kops命令创建k8集群时,我遇到了问题。
这就是我在创建集群时遇到的错误。
W1104 16:31:41.803150 18534 apply_cluster.go:945] **unable to pre-create DNS records - cluster startup may be slower: Error pre-creating DNS records: InvalidChangeBatch**: [RRSet with DNS name api.dev.devops.com. is not permitted in zone uswest2.dev.devops
我使用kops创建了一个集群。它工作得很好,集群是健康的。我可以使用kubectl查看我的节点,并且已经创建了一些部署和服务。我尝试使用"kops edit ig nodes“添加一个节点,但得到一个错误"cluster not found”。现在我得到了所有kops命令的错误:
kops validate cluster
Using cluster from kubectl context: <clustername>
cluster "<clustername>" not found
所以我的问题是: kops在哪里寻找集群,我如何
我继续参照以下站点进行工作(我不使用EKS.I。我使用kops在ec2上创建ec2)
在AWS上开始使用kOps
当我试图给kubectl get service打电话时,我收到了这样的消息:error: You must be logged in to the server (Unauthorized)
以下是我所做的:
设置IAM用户(创建用户并添加角色)
集群状态存储(S3)
准备当地环境
export NAME=myfirstcluster.example.com
export KOPS_STATE_STORE=s3://prefix-example-com-state-store
我正在尝试在aws上创建一个kubernetes集群,但它在验证时总是失败。使用以下命令更新集群kops update cluster cluster.foo.com --yes并开机自检运行此kops validate cluster
Using cluster from kubectl context: cluster.foo.com
Validating cluster cluster.api.com
INSTANCE GROUPS
NAME ROLE MACHINETYPE MIN MAX SUBNETS
master-eu-west-2a Mast