System Administration
cancel
Showing results for 
Search instead for 
Did you mean: 

root login not allowing: neither ssh nor scp ..Whats wrong???

 
rveri-admin
Frequent Advisor

root login not allowing: neither ssh nor scp ..Whats wrong???

Hi Experts,

 

Few servers shipped from another place, I have got root password but unable to login directly to root using pty session.

 

- I can login using direct console hooked up from the GSP /MP serial port ,   or from MP network lan.

- However from putty I can not ?? it is saying permission denied. 

- I am also not able to do scp using root user.

 

I checked the file : /opt/STMtools/STMopenssh/etc/sshd_config    and changed from  "no" to "yes"    

PermitRootLogin yes

 

- restarted the daemon /sbin/init.d/STMsshd   stop   ;   &    /sbin/init.d/STMsshd/start .

- even rebooted the server . But still unable to login using root :

- moved the file /etc/securetty   to  /etc/securetty.OLD   # [ inside entry was  console  ]

 

 

 

 

Getting error: 

login as: root
root@10.11.20.25's password:
Access denied
root@10.11.20.25's password:

 

 

 

Please help , what else needs to be check, as I need root login for temporary setting up the server and few other copy work.

 

Thank you..

 

 

 

 

 

 

 

4 REPLIES
TeamHP_1
Member

Re: root login not allowing: neither ssh nor scp ..Whats wrong???

Did you try telnet ?

pradeep m
Respected Contributor

Re: root login not allowing: neither ssh nor scp ..Whats wrong???

Check the /etc/nsswitch.conf file for proper settings configured for "passwd" field. Make sure it is configured to use files instead of NIS, ldap or compat. 

 

For Example: 

# cat /etc/nsswitch.conf

#
# /etc/nsswitch.files:
#
# @(#)B11.23_LR
#
# An example file that could be copied over to /etc/nsswitch.conf; it
# does not use any name services.
#
passwd:    files
group:        files
hosts:        files
ipnodes:   files
services:   files
networks:  files
protocols:  files
rpc:             files
publickey:  files
netgroup: files
automount: files
aliases: files

 

If you dont find the /etc/nsswitch.conf file, create one using the below command. 

# cp /etc/nsswitch.files /etc/nsswitch.conf

 

Now try to login as root and check if it works. 

 

 

 

Regards,
Pradeep

I am an HP Employee
A quick resolution to technical issues for your HP Enterprise products is just a click away HP Support Center Knowledge-base
See Self Help Post for more details


Denver Osborn
Honored Contributor

Re: root login not allowing: neither ssh nor scp ..Whats wrong???

Have you checked the syslog for clues?  So far it sounds as if sshd_config could have a setting which is leading to the failed login...  Unfortunately the only setting we know is 'PermitRootLogin yes'  

 

Are you able to login via ssh as a non-root user?

 

To troubleshoot, you could always login at the console as root and start another instance of sshd in debug mode.  The output will give you a better idea of what's going on other than 'access denied'

 

on server:  sshd -ddd -p 2222-f /path/to/your/sshd_config

 

on client:  ssh -vvv -p 2222 root@yourhost

 

Hope this helps,

-denver

laiju.c.babu
Regular Advisor

Re: root login not allowing: neither ssh nor scp ..Whats wrong???

Could you please  check whether any error is reporting  in /var/adm/syslog/syslog.log

Laiju.C.Babu