凌晨 wrote: > Hi there > > Please help me out!! > > We built a server on mina framework then running in linux(red hat as4 update > 2).Everytime after I shut down the server using KILL -9,the socket would > stuck in status FIN_WAIT1 > > How fix this problem TKS Very Much!! > >
I replied to your previous mail (sent June 8). Guess you didn't get that mail? Well, here's my reply again: ---- What version of MINA are you using? Which JRE? If using MINA 0.9.4 you should make sure you set reuseAddress to true when binding. This is a property in the SocketAcceptorConfig which you can pass to bind() SocketAcceptorConfig config = new SocketAcceptorConfig(); config.setReuseAddress(true); acceptor = new SocketAcceptor(); acceptor.bind(address, handler, config); Or you can call ((SocketAcceptorConfig ) acceptor.getDefaultConfig()).setReuseAddress(true) before binding. -- Niklas Therning Software Architect www.spamdrain.net
