You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mina.apache.org by Pawel Sm7 <pa...@gmail.com> on 2015/02/02 16:30:34 UTC

Re: SSH Server fails when is opened and closed 3 times in a row.

Hello,

I'd like to raise JIRA issue for the problem described below. Please
let me know if you agree.
Regards,

Pawel

2015-01-20 14:08 GMT+01:00 Pawel Sm7 <pa...@gmail.com>:
> Hello,
>
> When I try to start and then stop SSH Server, starting SSH Server for
> the 3. time fails with the error:
> Address already in use: bind.
>
> In other words, the sequence of actions fail:
>
> SSH Server start
> SSH Server stop
> SSH Server start
> SSH Server stop
> SSH Server start
>
>
> I checked that 2. stop in not fully performed - the 'if' condition is not true:
> CloseableUtils.java, AbstractCloseable.close(), line 282
> if (state.compareAndSet(State.Opened, State.Graceful)) {
>
> Forcing the condition above to true causes 2. stop to perform
> completely, and as a consequence,
> consecutive SSH Server start/stops work.
>
>
> I know this is just workaround, but not complete solution for the problem.
>
> Could you look at this?
>
> Do you want me to raise JIRA issue for this?
>
> Regards,
>
> Pawel

Re: SSH Server fails when is opened and closed 3 times in a row.

Posted by Guillaume Nodet <gn...@apache.org>.
Yes, please raise a JIRA and if you could attach a unit test, that would be
awesome.

2015-02-02 16:30 GMT+01:00 Pawel Sm7 <pa...@gmail.com>:

> Hello,
>
> I'd like to raise JIRA issue for the problem described below. Please
> let me know if you agree.
> Regards,
>
> Pawel
>
> 2015-01-20 14:08 GMT+01:00 Pawel Sm7 <pa...@gmail.com>:
> > Hello,
> >
> > When I try to start and then stop SSH Server, starting SSH Server for
> > the 3. time fails with the error:
> > Address already in use: bind.
> >
> > In other words, the sequence of actions fail:
> >
> > SSH Server start
> > SSH Server stop
> > SSH Server start
> > SSH Server stop
> > SSH Server start
> >
> >
> > I checked that 2. stop in not fully performed - the 'if' condition is
> not true:
> > CloseableUtils.java, AbstractCloseable.close(), line 282
> > if (state.compareAndSet(State.Opened, State.Graceful)) {
> >
> > Forcing the condition above to true causes 2. stop to perform
> > completely, and as a consequence,
> > consecutive SSH Server start/stops work.
> >
> >
> > I know this is just workaround, but not complete solution for the
> problem.
> >
> > Could you look at this?
> >
> > Do you want me to raise JIRA issue for this?
> >
> > Regards,
> >
> > Pawel
>