2016-05-26 11 views
-1

Ich möchte Root-Benutzernamen ändern, aber endlich bekomme ich ein großes Problem!Zugang verweigert über ssh Login in Centos

jetzt kann ich nicht auf den Server zugreifen, mit root-Benutzernamen und Passwort

zuerst: ich hatte einen Ping Sekunde: Direct ist ok http-Service ist ok dritte: alle Websites sind ok /etc/shadow und/etc/passwd scheint in Ordnung zu sein! aber ich denke, es gibt einen Fehler Dinge überhaupt! diese Befehle antworten root @ rescue: ~ # tail -1/etc/passwd Code:

rootftp:x:0:0:root:/mnt:/bin/nologin 

und

root @ rescue: ~ # tail -l/etc/shadow Code:

systemd-timesync:*:16567:0:99999:7::: 
systemd-network:*:16567:0:99999:7::: 
systemd-resolve:*:16567:0:99999:7::: 
systemd-bus-proxy:*:16567:0:99999:7::: 
uuidd:*:16567:0:99999:7::: 
ftp:*:16567:0:99999:7::: 
ovh:f1iXm9JFloDhE:16947:0:99999:7::: 
statd:*:16729:0:99999:7::: 
sshd:*:16737:0:99999:7::: 
rootftp:*:12856:0:99999:7::: 

jetzt, wenn ich will über premissions und Änderung root-Passwort über passwd

Rettungsdiskette und Kontrolle der sshd Dienst einfügen verwenden ftp ans SFTP 210

wieder kann ich ssh root Service

jetzt, und ich kann nicht mehr, ich kann nicht auf den Server über den Port 22 und 21

, wie kann ich dieses Problem beheben gehen nicht? innerhalb Rettungs Panel

ist diese Lognachricht

Code:

May 26 13:15:10 rescue kernel: random: systemd urandom read with 74 bits of entropy available 
May 26 13:15:10 rescue kernel: random: nonblocking pool is initialized 
May 26 13:15:10 rescue rsyslogd-2007: action 'action 17' suspended, next retry is Thu May 26 13:15:40 2016 [try http://www.rsyslog.com/e/2007 ] 
May 26 13:15:11 rescue mpt-statusd: detected non-optimal RAID status 
May 26 13:22:57 rescue kernel: nf_conntrack: automatic helper assignment is deprecated and it will be removed soon. Use the iptables CT target to attach helpers instead. 
May 26 13:22:57 rescue kernel: ip_set: protocol 6 
May 26 13:23:34 rescue kernel: ip_set: protocol 6 
May 26 13:23:39 rescue kernel: ip_set: protocol 6 
May 26 13:25:11 rescue mpt-statusd: detected non-optimal RAID status 
May 26 13:35:11 rescue mpt-statusd: detected non-optimal RAID status 
+0

was hast du den root username * in * geändert? – user3788685

Antwort

0

Die pb hier ist, dass Sie die Shell verändert!

rootftp: x: 0: 0: root:/mnt: /bin/nologin

Sie haben so etwas wie "/ bin/bash" setzen

rootftp: x: 0 : 0: root:/mnt: /bin/bash

+0

Neben dieser Antwort kann es sein, dass die Nebenwirkung sich ändert root username cf. : http://unix.stackexchange.com/questions/8447/how-do-you-rename-root & http://www.cyberciti.biz/faq/understanding-etcpasswd-file-format/ – k4cy