Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BUG: Failed to add nodes to the cluster using diff ssh options #3492

Closed
SpringHgui opened this issue Jul 12, 2023 · 3 comments · Fixed by #3525
Closed

BUG: Failed to add nodes to the cluster using diff ssh options #3492

SpringHgui opened this issue Jul 12, 2023 · 3 comments · Fixed by #3525
Assignees
Labels
kind/feature New feature or request

Comments

@SpringHgui
Copy link

Sealos Version

4.2.0

How to reproduce the bug?

参考 #1941 的问题,尝试增加节点

因为每个节点的ssh密码不同,所有修改下面ssh密码,然后添加节点

[root@svrhz8-3 ~]# cat /root/.sealos/default/Clusterfile
apiVersion: apps.sealos.io/v1beta1
kind: Cluster
metadata:
  creationTimestamp: "2023-05-24T03:54:52Z"
  name: default
spec:
  hosts:
  - ips:
    - 172.16.21.247:22
    roles:
    - master
    - amd64
  - ips:
    - 172.16.21.249:22
    roles:
    - node
    - amd64
  image:
  - labring/kubernetes-docker:v1.27.2
  - labring/helm:v3.11.3
  - labring/calico:v3.25.1
  ssh:
    passwd: *****
    pk: /root/.ssh/id_rsa
    port: 22
    user: root
status:
  commandCondition:
  - images:
    - labring/kubernetes-docker:v1.27.2
    - labring/helm:v3.11.3
    - labring/calico:v3.25.1
    lastHeartbeatTime: "2023-05-24T03:54:52Z"
    message: Applied to cluster successfully
    reason: Apply Command
    status: "True"
    type: ApplyCommandSuccess
  - images: null
    lastHeartbeatTime: null
    status: ""
    type: ""
  conditions:
  - lastHeartbeatTime: "2023-05-24T03:54:52Z"
    message: Applied to cluster successfully
    reason: Ready
    status: "True"
    type: ApplyClusterSuccess

本次新增节点172.16.21.245,但是报错是之前添加的一个子节点172.16.21.249的密码问题,密码已经被修改为172.16.21.245的密码了,当然验证不通过

[root@svrhz8-3 ~]# sealos add --nodes 172.16.21.245
2023-07-12T11:22:52 info start to scale this cluster
2023-07-12T11:22:52 info Executing pipeline JoinCheck in ScaleProcessor.
Error: failed to run checker: checker: failed to create ssh client, failed to connect 172.16.21.249:22: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain

What is the expected behavior?

No response

What do you see instead?

No response

Operating environment

- Sealos version:  4.2.0

Additional information

#1941 只能解决当只有主节点时添加一个子结点,如果继续新增子节点,还是要所有子节点的密码相同?

@SpringHgui SpringHgui added the kind/bug Something isn't working label Jul 12, 2023
@sealos-ci-robot sealos-ci-robot changed the title BUG: 集群增加节点失败 BUG: Failed to add nodes to the cluster Jul 12, 2023
@cuisongliu
Copy link
Collaborator

暂时不支持不同节点密码不同,有兴趣可以提交PR。#2896 这个没有后续了,你可以接着看一下这个问题。

@sealos-ci-robot
Copy link
Member

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Different node passwords are not supported for the time being, if you are interested, you can submit a PR. #2896 There is no follow-up for this, you can continue to look at this issue.

@cuisongliu cuisongliu added kind/feature New feature or request and removed kind/bug Something isn't working labels Jul 12, 2023
@cuisongliu cuisongliu changed the title BUG: Failed to add nodes to the cluster BUG: Failed to add nodes to the cluster using diff ssh options Jul 12, 2023
@yangxggo
Copy link
Contributor

/assign

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/feature New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants