ALT Linux Community general discussions
 help / color / mirror / Atom feed
From: Roman S <rromas@mailru.com>
To: mandrake-russian@altlinux.ru
Subject: Re: [mdk-re] Socket problem
Date: Mon Apr 23 21:18:00 2001
Message-ID: <20010423172834.3B7049B3E@rromas.user.lanet.ru> (raw)
In-Reply-To: <01042316084000.09110@asch.office.totem.ru>

On Mon, 23 Apr 2001 16:08:40 +0400
Alex Ryabchikov <chico@mail.spbnit.ru> wrote:
> Спасибо за ответ! Однако я наверно не совсем точно описал проблему - попробую 
> поподробнее! Использую я значит в работе IBM VisualAge For Java (Linux port). 
> Прога великолепная! Из ide я запускаю свое серверное приложение которое 
> открывает серверный сокет и ждет соединений клиента. Но когда сервер 
> заканчивает свою работу - сокет _НЕ ЗАКРЫВАЕТСЯ_. Соответсвенно повторный 
> запуск вызывает ошибку мол что сокет уже используется! Конечно я понимаю что 
> это ошибка VisualAge'a однако мне кажется что в Линуксе должны быть какие то 
> средства что бы насильно освободить сокет. 
> Спасибо если кто ответит! :)
Я давно не брал в руки этой шашки, но посмотрите 
netstat -le | less

90% моей уверенности, что держит сокет VA IDE.
Насколько я помню (могу ошибаться по причине склероза) ежели вызвать проект из оболочки, то он будет работать в VM, встроенной в оболочку (для скорости и отладочных функций).
Т.е. сокет остаётся за Java VM, и остаётся, пока она не завершится...
Осталось решить, глюк это или фича (для пост-отладки).

90% вероятности, что если запустить приложение как java -jar something.jar, то сокут отвалится вместе с завершением программы.
И наверняка закроется, если выйти из IDE.

Средств "насильно" закрыть ресурс чужого процесса я не знаю. Пристрелить процесс - это пожалуйста, вмешиваться насильно в работу другого процесса и заблокированные им ресурсы - ни-ни.

А так... - закрывайте за собой... В приложении.

-- 
Rgds!
Roman Savelyev



      parent reply	other threads:[~2001-04-23 21:18 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-04-22 18:17 Alex Ryabchikov
2001-04-23  0:32 ` Sergei
2001-04-23 16:11   ` Alex Ryabchikov
2001-04-23 16:35     ` Maxim Savrilov
2001-04-24 13:51       ` Artem K.Jouravsky
2001-04-23 21:18     ` Roman S [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=20010423172834.3B7049B3E@rromas.user.lanet.ru \
    --to=rromas@mailru.com \
    --cc=mandrake-russian@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 Community general discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/community/0 community/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 community community/ http://lore.altlinux.org/community \
		mandrake-russian@linuxteam.iplabs.ru community@lists.altlinux.org community@lists.altlinux.ru community@lists.altlinux.com
	public-inbox-index community

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


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