Super User Asked on November 4, 2021
Seems like unless I specify -l <account name on the remote computer>
when typing ssh <ip>
, the ssh command just uses my Windows account name by default. This is annoying. Can I make it not use my Windows account name and ask for the user name by default, when -l
is not used?
OpenSSH always uses the current user's name unless you either specify one by writing it before an at sign (e.g., ssh [email protected]
) or you use the -l
option. However, you can adjust this using ~/.ssh/config
if you like by specifying something else:
Host github.com
User git
Host *
User bk2204
This will use the user git
for github.com
and bk2204
for all other sites. You can still override it at the command line with the two techniques I mentioned above.
Answered by bk2204 on November 4, 2021
Get help from others!
Recent Questions
Recent Answers
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP