Skip to content

tiup cluster deploy: using -user instead of --user leads to misleading SSH authentication error #2672

@yi888long

Description

@yi888long

Bug Report

Please answer these questions before submitting your issue. Thanks!

  1. What did you do?

I deployed a TiDB cluster using tiup cluster deploy, but accidentally used -user instead of --user as the flag name.

Steps to reproduce:

tiup cluster deploy tidb-ryl v8.5.3 topo.yaml -user tidb -i global_user

  1. What did you expect to see?

unknown flag: -user
did you mean --user ?

  1. What did you see instead?
    TiUP did not report any flag parsing error and continued execution.
    Later, it failed during the SSH phase with a misleading authentication error:

Error: failed to fetch cpu-arch or kernel-name: executor.ssh.execute_failed: Failed to execute command over SSH for 'ser@10.0.0.3:22' {ssh_stderr: , ssh_stdout: , ssh_command: export LANG=C; PATH=$PATH:/bin:/sbin:/usr/bin:/usr/sbin; /usr/bin/sudo -H bash -c "uname -m"}, cause: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain

  1. What version of TiUP are you using (tiup --version)?
    1.16.3 tiup
    Go Version: go1.24.1
    Git Ref: v1.16.3

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions