SSH root access for NSX-T appliance fails with "Access Denied"
search cancel

SSH root access for NSX-T appliance fails with "Access Denied"

book

Article ID: 375479

calendar_today

Updated On:

Products

VMware NSX

Issue/Introduction

If root ssh access was not enabled at NSX-T appliance deployment time, root ssh will fails with "Access Denied" error.


Checking service ssh status with get service ssh shows Root Login Enabled and SSH enabled

Environment

VMware NSX-T Data Center 3.x

VMware NSX 4.1.x

Cause

The ssh was enabled, however the root was not allowed to use ssh. In order to allow ssh login with root account, it is necessary to run the enable root.login.sh and give the PermitRootLogin to Yes.

 

 

Resolution

1.Log in to the NSX-T manager console as root,

2.Edit ssh config file:

  • Open the file " vi /etc/ssh/sshd_config " for editing. 

3.Modify the Configuration:

  • Locate the line  "#PermitRootLogin prohibit-password" 
  • Replace it with  "PermitRootLogin yes"

4.Restart the ssh service:

  • Execute the command  " /etc/init.d/ssh restart

Note: If root login still fails you may need to enable root login after restarting SSH

  • set ssh root-login