gpt4 book ai didi

AWS 主节点上的 Kubernetes 问题

转载 作者:行者123 更新时间:2023-12-02 11:46:16 24 4
gpt4 key购买 nike

在 AWS 上运行 Kubernetes 几天后,我的主节点死了。这是在设置 2 个不同的集群后发生的。 pod 仍在运行且可用,但无法管理/代理。

问题是为什么?或者,如何替换 AWS 上的主节点?或者,如何调试现有的?或者,我如何使用 t2.micro 以外的东西,它可能太小而无法运行 master?

症状:
$ kubectl 获取 pod
错误:无法从服务器读取版本:获取 https://**.###.###.###/api: dial tcp **.###.###.###:443 : 连接被拒绝

编辑:
这是我在进一步调试后发现的:

goroutine 571 [running]:
net/http.func·018()
/usr/src/go/src/net/http/transport.go:517 +0x2a
net/http.(*Transport).CancelRequest(0xc2083c0630, 0xc209750d00)
/usr/src/go/src/net/http/transport.go:284 +0x97
github.com/coreos/go-etcd/etcd.func·003()
/go/src/github.com/GoogleCloudPlatform/kubernetes/Godeps/_workspace/src/github.com/coreos/go-etcd/etcd/requests.go:159 +0x236
created by github.com/coreos/go-etcd/etcd.(*Client).SendRequest
/go/src/github.com/GoogleCloudPlatform/kubernetes/Godeps/_workspace/src/github.com/coreos/go-etcd/etcd/requests.go:168 +0x3e3

goroutine 1 [IO wait, 12 minutes]:
net.(*pollDesc).Wait(0xc20870e760, 0x72, 0x0, 0x0)
/usr/src/go/src/net/fd_poll_runtime.go:84 +0x47
net.(*pollDesc).WaitRead(0xc20870e760, 0x0, 0x0)
/usr/src/go/src/net/fd_poll_runtime.go:89 +0x43
net.(*netFD).accept(0xc20870e700, 0x0, 0x7f4424a42008, 0xc20930a168)
/usr/src/go/src/net/fd_unix.go:419 +0x40b
net.(*TCPListener).AcceptTCP(0xc20804bec0, 0x5bccce, 0x0, 0x0)
/usr/src/go/src/net/tcpsock_posix.go:234 +0x4e
net/http.tcpKeepAliveListener.Accept(0xc20804bec0, 0x0, 0x0, 0x0, 0x0)
/usr/src/go/src/net/http/server.go:1976 +0x4c
net/http.(*Server).Serve(0xc20887ec60, 0x7f4424a66dc8, 0xc20804bec0, 0x0, 0x0)
/usr/src/go/src/net/http/server.go:1728 +0x92
net/http.(*Server).ListenAndServe(0xc20887ec60, 0x0, 0x0)
/usr/src/go/src/net/http/server.go:1718 +0x154
github.com/GoogleCloudPlatform/kubernetes/cmd/kube-apiserver/app.(*APIServer).Run(0xc2081f0e00, 0xc20806e0e0, 0x0, 0xe, 0x0, 0x0)
/go/src/github.com/GoogleCloudPlatform/kubernetes/_output/dockerized/go/src/github.com/GoogleCloudPlatform/kubernetes/cmd/kube-apiserver/app/server.go:484 +0x264a
main.main()
/go/src/github.com/GoogleCloudPlatform/kubernetes/_output/dockerized/go/src/github.com/GoogleCloudPlatform/kubernetes/cmd/kube-apiserver/apiserver.go:48 +0x154

最佳答案

几乎可以肯定机器的初始大小太小,并且内存不足(或类似的东西)。要使用更大的集群大小,请点击此链接 [1] 并在启动集群之前设置环境变量。

在这种情况下,类似于:

export MINION_SIZE=t2.large

应该永远运行。[2]

[1] http://kubernetes.io/docs/getting-started-guides/aws/

[2] 或其合理的近似值。 :)

关于AWS 主节点上的 Kubernetes 问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32192339/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com