¿Cómo "ambos lados simplemente colgarán"? ¿De verdad observas eso?
Cita de "TCP/IP Illustrated, Volume 1, 2nd edition" pág. 628:
The reset segment contains a sequence number and acknowledgement number. Also notice that the reset segment elicits no response from the other end—it is not acknowledged at all. The receiver of the reset aborts the connection and advises the application that the connection was reset. This often results in the error indication "Connection reset by peer" or a similar message.
Y en la página anterior:
Aborting a connecting provides two features...any queued data is thrown away and a reset segment is sent immediately...the receiver of the reset can tell that the other end did an abort instead of a normal close.
(También puede revisar la opción de socket SO_LINGER
que puede usar el socket de escucha de su aplicación.)
Это зависит от конкретной реализации, которую использует ваш дистрибутив (, а иногда и от конфигурации ), но один из:
startpar
без -M
еще во времена Debian Lenny. insserv
/ startpar -M
. Или что делают другие системы инициализации (, например, systemd )уровни совместимости SysV. Вам нужно будет проверить документацию по вашей системе или код (, который в SysV init часто представлял собой сценарии оболочки, поэтому проверить их относительно легко; вы можете узнать, где он находится, прочитав/etc/inittab
).