Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
problem z ssh na rps...
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Polskie forum (Polish) Instalacja i sprzęt
View previous topic :: View next topic  
Author Message
amdziak
n00b
n00b


Joined: 29 May 2006
Posts: 52
Location: Poland/Mogielnica

PostPosted: Wed Dec 28, 2011 6:32 pm    Post subject: problem z ssh na rps... Reply with quote

Witam!

Otóż mam takowy problem:
zrobiłęm na firmowym serwerze emerge --depclean i po tejze operacji wysypalo mi sie ssh..
Chcąc ręcznie odpalić ssh przez Webmina wywala taki błąd:

Quote:
Nie udało się uruchomić serwera SSH :
/var/empty must be owned by root and not group or world-writable.


W logach jest coś takiego:

Quote:
Dec 28 18:41:02 stock sshd[20564]: error: @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
Dec 28 18:41:02 stock sshd[20564]: error: @ WARNING: UNPROTECTED PRIVATE KEY FILE! @
Dec 28 18:41:02 stock sshd[20564]: error: @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
Dec 28 18:41:02 stock sshd[20564]: error: Permissions 0777 for '/etc/ssh/ssh_host_dsa_key' are too open.
Dec 28 18:41:02 stock sshd[20564]: error: It is recommended that your private key files are NOT accessible by others.
Dec 28 18:41:02 stock sshd[20564]: error: This private key will be ignored.
Dec 28 18:41:02 stock sshd[20564]: error: bad permissions: ignore key: /etc/ssh/ssh_host_dsa_key
Dec 28 18:41:02 stock sshd[20564]: error: Could not load host key: /etc/ssh/ssh_host_dsa_key
Dec 28 18:41:02 stock sshd[20564]: Disabling protocol version 2. Could not load host key
Dec 28 18:41:02 stock sshd[20564]: sshd: no hostkeys available -- exiting.
Dec 28 18:50:03 stock su[21122]: Successful su for root by root
Dec 28 18:50:03 stock su[21122]: + ??? root:root
Dec 28 18:55:41 stock su[21408]: Successful su for root by root
Dec 28 18:55:41 stock su[21408]: + ??? root:root
Dec 28 18:56:16 stock sshd[4746]: Received signal 15; terminating.
Dec 28 18:57:31 stock su[21538]: Successful su for root by root
Dec 28 18:57:31 stock su[21538]: + ??? root:root
Dec 28 19:00:45 stock sshd[4506]: pam_unix(sshd:session): session closed for user root


sshd ma status started..
Co mi pozostaje?
Zadne srony firmowe nie chodzą ani nic, normalnie nie chce mi się myśleć o reinstalce...

Pozdrawiam i z góry dziękuję za pomoc,
amdziak
_________________
Je¶li komputer, to tylko z Linuxem!!!;-)
Back to top
View user's profile Send private message
Jacekalex
Guru
Guru


Joined: 17 Sep 2009
Posts: 553

PostPosted: Thu Dec 29, 2011 1:31 am    Post subject: Reply with quote

Quote:
Dec 28 18:41:02 stock sshd[20564]: error: @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
Dec 28 18:41:02 stock sshd[20564]: error: @ WARNING: UNPROTECTED PRIVATE KEY FILE! @
Dec 28 18:41:02 stock sshd[20564]: error: @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
Dec 28 18:41:02 stock sshd[20564]: error: Permissions 0777 for '/etc/ssh/ssh_host_dsa_key' are too open.
Dec 28 18:41:02 stock sshd[20564]: error: It is recommended that your private key files are NOT accessible by others.
Dec 28 18:41:02 stock sshd[20564]: error: This private key will be ignored.
Dec 28 18:41:02 stock sshd[20564]: error: bad permissions: ignore key: /etc/ssh/ssh_host_dsa_key
Dec 28 18:41:02 stock sshd[20564]: error: Could not load host key: /etc/ssh/ssh_host_dsa_key
Dec 28 18:41:02 stock sshd[20564]: Disabling protocol version 2. Could not load host key
Dec 28 18:41:02 stock sshd[20564]: sshd: no hostkeys available -- exiting.


Poszukaj sobie lepiej lepszego okulisty, bo masz czarno na białym napisane, co jest grane.

SSH to jest Secure Shell - nie wystartuje, jeśli klucze nie mają bezpiecznych uprawnień.

I to raczej nie emerge rozpieprzyło uprawnienia, tylko rekursywne zmienianie uprawnień na 777.

RTFM
Code:
man chmod


Bo np u mnie, na takich uprawnieniach:
Code:
-rw-r--r--. 1 root root 1703904 11-18 09:42 blacklist
drwxr-x---. 2 root root    4096 2010-07-28  ca
-rw-r--r--. 1 root root  125811 11-18 09:29 moduli
-rw-r--r--. 1 root root    2079 2011-05-21  ssh_config
-rw-r--r--. 1 root root    5968 10-29 21:02 sshd_config
-rw-------. 1 root root     668 2010-07-28  ssh_host_dsa_key
-rw-r--r--. 1 root root     604 2010-07-28  ssh_host_dsa_key.pub
-rw-------. 1 root root     227 2011-06-23  ssh_host_ecdsa_key
-rw-r--r--. 1 root root     170 2011-06-23  ssh_host_ecdsa_key.pub
-rw-------. 1 root root     979 2010-07-28  ssh_host_key
-rw-------. 1 root root     644 2010-07-28  ssh_host_key.pub
-rw-------. 1 root root    1675 2010-07-28  ssh_host_rsa_key
-rw-------. 1 root root     396 2010-07-28  ssh_host_rsa_key.pub
ssh działa prawidłowo.

To by było na tyle
8)
Back to top
View user's profile Send private message
SlashBeast
Retired Dev
Retired Dev


Joined: 23 May 2006
Posts: 2922

PostPosted: Thu Dec 29, 2011 10:08 am    Post subject: Reply with quote

Najwyrazniej *ktos* dal 'chmod 777 -R /'. Ja bym taki system zaoral i postawil od nowa.
Back to top
View user's profile Send private message
Jacekalex
Guru
Guru


Joined: 17 Sep 2009
Posts: 553

PostPosted: Thu Dec 29, 2011 11:38 am    Post subject: Reply with quote

SlashBeast wrote:
Najwyrazniej *ktos* dal 'chmod 777 -R /'. Ja bym taki system zaoral i postawil od nowa.


A ja po postawieniu od nowa zrobiłbym backup samych uprawnień.
Sznurek: http://dug.net.pl/tekst/117/backup_uprawnien_w_folderach_systemowych_/

Pozdro
8)
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Polskie forum (Polish) Instalacja i sprzęt All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum