tiup cluster deploy: using -user instead of --user leads to misleading SSH authentication error
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 466
- Forks
- 338
- Avg merge
- 3d 7h
- Merged PRs (30d)
- 8
Description
Bug Report
Please answer these questions before submitting your issue. Thanks!
- 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
- What did you expect to see?
unknown flag: -user
did you mean --user ?
- 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
- What version of TiUP are you using (
tiup --version)?
1.16.3 tiup
Go Version: go1.24.1
Git Ref: v1.16.3
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the tiup cluster deploy command with -user instead of --user, then trace the command's argument parsing before the SSH phase. Done means the command stops immediately with an unknown-flag error that suggests --user, rather than continuing to SSH and reporting an authentication failure.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100