Bug 39941

Summary: Аварийно завершается
Product: Sisyphus Reporter: Олег Соловьев <mcpain>
Component: opensshAssignee: Gleb F-Malinovskiy <glebfm>
Status: CLOSED NOTABUG QA Contact: qa-sisyphus
Severity: normal    
Priority: P5 CC: glebfm, ldv, rider, vt
Version: unstable   
Hardware: x86_64   
OS: Linux   

Description Олег Соловьев 2021-04-14 10:25:04 MSK
Скрипт:
rsync -vaPz --delete user@remote:/path/to/dir1 /path/to/local1
rsync -vaPz --delete user@remote:/path/to/dir2 /path/to/local2

При запуске скрипта второй rsync рапортует connection refused.
sshd запускается с ключом -d

Логи (IP, hostname и имя пользователя заменены):

апр 14 10:22:54 remote sshd[9333]: Received disconnect from <IP> port 41694:11: disconnected by user
апр 14 10:22:54 remote sshd[9333]: Disconnected from user <user> <IP> port 41694
апр 14 10:22:54 remote sshd[9333]: debug1: do_cleanup
апр 14 10:22:54 remote sshd[9317]: debug1: do_cleanup
апр 14 10:22:54 remote sshd[9317]: debug1: audit_event: unhandled event 12
апр 14 10:22:54 remote audit[1]: SERVICE_STOP pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=sshd comm="systemd" exe="/lib/systemd/systemd" hostname=? addr=? terminal=? res=failed'
апр 14 10:22:54 remote systemd[1]: sshd.service: Main process exited, code=exited, status=255/EXCEPTION
Comment 1 Anton Farygin 2021-04-14 11:54:37 MSK
Олег, а как ты так запускаешь sshd ?

Под пользователем что ли ?
Comment 2 Олег Соловьев 2021-04-14 12:02:55 MSK
(Ответ для Anton Farygin на комментарий #1)
> Олег, а как ты так запускаешь sshd ?
> 
> Под пользователем что ли ?

Нет. Как systemd'шный сервис.
В моём случае было

bash # cat /etc/sysconfig/sshd
# Parameters for OpenSSH server daemon.
# See sshd(8) for more details.

# Specifies additional parameters for sshd.
EXTRAOPTIONS="-d"
Comment 3 Олег Соловьев 2021-04-14 12:04:08 MSK
not a bug.

man sshd(8):
-d Debug mode.  The server sends verbose debug output to standard error, and does not put itself in the background.  The server also will not fork and will only process one connection.  This option is only intended for debugging for the server.  Multiple -d options increase the debugging level.  Maximum is 3.
Comment 4 Anton Farygin 2021-04-14 12:04:41 MSK
Надеюсь, что ты читал man прежде чем повесить баг:

  -d      Debug mode.  The server sends verbose debug output to standard error, and does not put itself in the background.  The server also will not
             fork and will only process one connection.  This option is only intended for debugging for the server.  Multiple -d options increase the
             debugging level.  Maximum is 3.