ALT Linux Team development discussions
 help / color / mirror / Atom feed
From: "Dmitry V. Levin" <ldv@altlinux.org>
To: ALT Devel discussion list <devel@altlinux.ru>
Subject: Re: [devel] Re: I: service-0.0.3: introduction to new start/stop service scheme
Date: Tue, 29 Apr 2003 19:03:17 +0400
Message-ID: <20030429150317.GA4869@basalt.office.altlinux.org> (raw)
In-Reply-To: <20030429145148.GE11315@osdn.org.ua>

[-- Attachment #1: Type: text/plain, Size: 1482 bytes --]

On Tue, Apr 29, 2003 at 05:51:48PM +0300, Michael Shigorin wrote:
> On Sat, Apr 26, 2003 at 01:41:51AM +0400, Dmitry V. Levin wrote:
> > - При запуске демона осуществляется поиск уже запущенных процессов, при
> >   этом есть шанс ошибочного нахождения процесса, обслуживающего клиента,
> >   что препятствует запуску демона.
> >   ssh localhost
> >   su -
> >   service sshd restart (ой!)
> 
> Тут еще вопрос с портами остался -- что делать с имеющимися sshd?

С процессами sshd, обслуживающими клиентов, ничего делать не надо.
Наоборот, эти процессы надо обходить стороной.

> inmetex:~> netstat -na | grep :22
> tcp        0      0 0.0.0.0:22              0.0.0.0:*               LISTEN      
> tcp        0      0 10.0.1.1:22             10.0.1.105:33576        ESTABLISHED 
> tcp        0      0 213.186.211.22:22       10.0.1.104:1330         ESTABLISHED 
> tcp        0      0 10.0.1.1:22             10.0.1.242:33129        ESTABLISHED 
> tcp        0     40 10.0.1.1:22             10.0.1.105:34759        ESTABLISHED 
> 
> Если сейчас сделать service sshd restart, то все равно останутся
> процессы, которые открыли соединение с локального trusted :22 --
> если я правильно понимаю, при таком раскладе bind()нуться к :22
> пытающемуся вновь запуститься sshd просто не дадут.
> 
> Нет?

Нет:
$ fgrep -n SO_REUSEADDR openssh-3.6.1p1/sshd.c
1171:			if (setsockopt(listen_sock, SOL_SOCKET, SO_REUSEADDR,
1173:				error("setsockopt SO_REUSEADDR: %s", strerror(errno));


--
ldv

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

      reply	other threads:[~2003-04-29 15:03 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-04-25 21:41 [devel] " Dmitry V. Levin
2003-04-27 19:09 ` Dmitry V. Levin
2003-04-29 14:51 ` [devel] " Michael Shigorin
2003-04-29 15:03   ` Dmitry V. Levin [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20030429150317.GA4869@basalt.office.altlinux.org \
    --to=ldv@altlinux.org \
    --cc=devel@altlinux.ru \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

ALT Linux Team development discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/devel/0 devel/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 devel devel/ http://lore.altlinux.org/devel \
		devel@altlinux.org devel@altlinux.ru devel@lists.altlinux.org devel@lists.altlinux.ru devel@linux.iplabs.ru mandrake-russian@linuxteam.iplabs.ru sisyphus@linuxteam.iplabs.ru
	public-inbox-index devel

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.devel


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git