Root login Ubuntu VM on Azure

后端 未结 6 1691
情深已故
情深已故 2021-02-02 13:38

Installed Ubuntu Server LTS 14.04 from Azure library on Azure VM. Logged in as standard \"azureuser\" created by Azure with my password. Changed root password:

s         


        
6条回答
  •  执笔经年
    2021-02-02 14:27

    To enter into a Azure VM using SSH...

    First, You need to enable the root account:

    #sudo passwd root
    

    Then you need to enable the root login for ssh editing the file /etc/ssh/sshd_config (the default value in Azure VMs is PermitRootLogin without-password, so you need to change/comment it):

    ...
    #PermitRootLogin without-password
    PermitRootLogin yes
    ...
    

    Finally, you need to reload/restart the ssh service:

    #sudo service ssh reload
    

提交回复
热议问题