admin管理员组文章数量:1122832
I have a UAT Bastion-enabled Management VM in Azure.
I have already copied my public ssh-key into the machine.
I am able to access the machine using web-browser. However, I wish to connect via terminal due to familiary and ease-of-use.
I wish to connect to the VM from local terminal using the below command -
az network bastion ssh --name MyBastionHost --resource-group MyResourceGroup \
--target-resource-id vmResourceId --auth-type ssh-key \
--username xyz --ssh-key ~/.ssh/id_rsa
This gives me a 'bastion' is misspelled or not recognized by the system.
error on local.
az cli version details -
"azure-cli": "2.67.0",
"azure-cli-core": "2.67.0",
"azure-cli-telemetry": "1.1.0",
"extensions": {}
}
Local machine OS - MacOS
Remote VM - Ubuntu 22.04
Is bastion
support disabled for this tenant ? Do I need to check any logs to find out ?
I have a UAT Bastion-enabled Management VM in Azure.
I have already copied my public ssh-key into the machine.
I am able to access the machine using web-browser. However, I wish to connect via terminal due to familiary and ease-of-use.
I wish to connect to the VM from local terminal using the below command -
az network bastion ssh --name MyBastionHost --resource-group MyResourceGroup \
--target-resource-id vmResourceId --auth-type ssh-key \
--username xyz --ssh-key ~/.ssh/id_rsa
This gives me a 'bastion' is misspelled or not recognized by the system.
error on local.
az cli version details -
"azure-cli": "2.67.0",
"azure-cli-core": "2.67.0",
"azure-cli-telemetry": "1.1.0",
"extensions": {}
}
Local machine OS - MacOS
Remote VM - Ubuntu 22.04
Is bastion
support disabled for this tenant ? Do I need to check any logs to find out ?
1 Answer
Reset to default 0This gives me a
'bastion' is misspelled or not recognized by the system.
error on local.
The error you are encountering is due to the Bastion extension not being installed on your laptop
To resolve this, run the command below to install the Bastion service
az extension update --name bastion
Once the extension is installed, make sure to verify the Bastion installation.
az extension show --name bastion
Below are the prerequisites to run the az network bastion ssh.Follow the MS Doc for more details
Bastion supports the Standard and Premium tiers, along with Native client support option enabled. For more details, refer to the MS DOC.
After configuring all the settings, I am able to connect to the Linux VM using az network bastion ssh
本文标签: ssh into Azure VM from local MacOS terminal using Bastion tunnelStack Overflow
版权声明:本文标题:ssh into Azure VM from local MacOS terminal using Bastion tunnel - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1736310970a1934570.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
az network bastion ssh
cmdlet, you may need to follow the prerequisites specified in the MS DOC. – Venkat V Commented Nov 22, 2024 at 4:13