[vpsFree.cz: community-list] ssh a screen po vypadku 2019-01-14 14:50 CET (na node3.brq)
Petr Fišer
priestcz at gmail.com
Wed Jan 16 09:06:49 CET 2019
Ahoj,
run je myslim tmpfs, takze restarty ho cisti.
Workaround:
poeditujte/forknete si unitu pro sshd a pridejte si tam (vyzkouset,
pisu to z hlavy!):
ExecStartPre=/usr/bin/mkdir -p /var/run/sshd
Fiisch
st 16. 1. 2019 v 8:25 odesílatel zd nex <zdnexnet at gmail.com> napsal:
>
> Ahoj,
>
> stalo se nám to samé na několika VPS (ssh/screen/fail2ban a ještě něco). Zřejmě to souvisí s novým systemd a jádrem ve OpenVZ. Zatím jsem vyřešil tak, že jsem provedl downgrade systemd na předchozí verzi a restartoval. Také jde ručně vytvořit požadovaný adresář pro /var/run/sshd > ale má to nevýhodu, že další restart to bude zase zpět.
>
> --
> S pozdravem,
>
> Zdeněk
> Web: www.pripravto.cz
>
> st 16. 1. 2019 v 8:01 odesílatel Jiri Drozd <jiri.drozd at sde.cz> napsal:
>>
>>
>> Ahoj,
>>
>> od vypadku viz subj. mi na VPSce odmita startovat SSH a SCREEN - oboje ma problem s chybejicim adresarem ve /var/run, jede to na ubuntu 16.04
>>
>> - sshd chybi /var/run/sshd a proto nenajede po restartu, musim rucne vytvorit /var/run/sshd a nastartovat sshd, nicmene po dalsim restartu adresar opet chybi a je nutno ho vytvorit znova
>>
>> ---
>> root at bgrserver:~# systemctl status sshd
>> ● ssh.service - OpenBSD Secure Shell server
>> Loaded: loaded (/lib/systemd/system/ssh.service; enabled; vendor preset: e
>> Active: failed (Result: start-limit-hit) since Mon 2019-01-14 16:06:32 UTC
>> Process: 376 ExecStartPre=/usr/sbin/sshd -t (code=exited, status=255)
>>
>> xxx at bgrserver:~$ sudo cat /var/log/syslog | grep ssh
>> [sudo] password for xxx:
>> Jan 14 16:06:14 bgrserver systemd-tmpfiles[86]: Failed to validate path /var/run/sshd: Too many levels of symbolic links
>> Jan 14 16:06:31 bgrserver sshd[326]: Missing privilege separation directory: /var/run/sshd
>> Jan 14 16:06:31 bgrserver systemd[1]: ssh.service: Control process exited, code=exited status=255
>> Jan 14 16:06:31 bgrserver systemd[1]: ssh.service: Unit entered failed state.
>> Jan 14 16:06:31 bgrserver systemd[1]: ssh.service: Failed with result 'exit-code'.
>> Jan 14 16:06:31 bgrserver systemd[1]: ssh.service: Service hold-off time over, scheduling restart.
>> ---
>>
>> - screenu prozmenu chybi /var/run/screen a situace je stejna jako u sshd - po restartu je nutne rucne znova vytvorit a zmenit mod na 777, pak jede
>>
>> ---
>> xxx at bgrserver:~$ screen -S test
>> Cannot make directory '/var/run/screen': Permission denied
>>
>> ... screen nejede ...
>>
>> xxx at bgrserver:~$ sudo mkdir /var/run/screen
>> [sudo] password for xxx:
>> xxx at bgrserver:~$ screen -S test
>> Directory '/var/run/screen' must have mode 777.
>> xxx at bgrserver:~$ sudo chmod 777 /var/run/screen
>> xxx at bgrserver:~$ screen -S test
>>
>> ... ted screen funguje, co po rebootu? ...
>>
>> [detached from 7334.test]
>> xxx at bgrserver:~$
>> xxx at bgrserver:~$ sudo reboot
>> packet_write_wait: Connection to 37.205.11.73 port 22: Broken pipe
>>
>> ... ted je treba nahodit sshd pres VPSadmina, vytvorenim /var/run/sshd a restartem sshd, jinak connection refused ...
>>
>> jdrozd at jdrozd-MS-7592:~$ ssh xxx at srv.dread.cz
>> ssh: connect to host srv.dread.cz port 22: Connection refused
>>
>> jdrozd at jdrozd-MS-7592:~$ ssh xxx at srv.dread.cz
>> Welcome to Ubuntu 16.04.5 LTS (GNU/Linux 3.16.6-042stab134.43 x86_64)
>>
>> * Documentation: https://help.ubuntu.com
>> * Management: https://landscape.canonical.com
>> * Support: https://ubuntu.com/advantage
>> Last login: Wed Jan 16 06:10:45 2019
>> xxx at bgrserver:~$ screen -S test
>> Cannot make directory '/var/run/screen': Permission denied
>>
>> ... po restartu je to o5 v ...
>>
>> ---
>>
>> Pritom prava na /var/run potazmo /run kam se to symlinkuje jsou stejna jako na jine ubuntu 16.04 masine kde vse funguje.
>>
>> ---
>> xxx at bgrserver:~$ ll /var | grep run
>> lrwxrwxrwx 1 root root 9 lis 15 2016 lock -> /run/lock/
>> lrwxrwxrwx 1 root root 4 lis 15 2016 run -> /run/
>>
>> xxx at bgrserver:~$ ll / | grep run
>> drwxr-xr-x 17 root root 560 led 16 06:11 run/
>> ---
>>
>> Nesetkal se nekdo z Vas s necim podobnym, nebo netusite kde by mohl byt problem?
>>
>> Poslal sem to i na podporu VPSfree, protoze si nejsem jisty jestli se jedna o problem na jejich strane, nebo se mi rozbilo Ubuntu (i kdyz k tomu nemelo duvod)...
>>
>> Diky - Buger
>> _______________________________________________
>> Community-list mailing list
>> Community-list at lists.vpsfree.cz
>> http://lists.vpsfree.cz/listinfo/community-list
>
>
> _______________________________________________
> Community-list mailing list
> Community-list at lists.vpsfree.cz
> http://lists.vpsfree.cz/listinfo/community-list
More information about the Community-list
mailing list