Nick,

  I looked this up in the socket guide and the syntax is correct. The only real 
issue that can arise by enabling address re-use is
the slim possibility that partial data could be received into the socket 
buffer, from the sockets that were never shutdown down
properly. This can lead to confusion in the application and/or the socket 
subsystem. I've never had that issue occur, but the
possibility of the condition should be known.

Just for clarity in future reading, socket shutdown and close are not 
synonymous.
Close refers only to the release of a file handle. A handle can be closed and 
re-opened on the same socket address.
Shutdown refers to the releasing of the file handle and also the addresses used 
by the socket.

Glen
http://picksource.com
http://mvdevcentral.com

> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] Behalf Of Nick Cipollina
> Sent: Friday, February 25, 2005 8:29 AM
> To: [email protected]
> Subject: RE: [U2][UV] Forcing a port to close
>
>
> This is exactly what I am getting.  The process is stopped, but for
> whatever reason, UniVerse is not closing and cleaning up the port.  The
> program in question has LOGTO statements in it, and I think that it is
> causing itself to get crossed up on the socket port.  If I include the
> following statement, will it help:
>
> X = setSocketOptions(SOCKETHANDLE, "REUSEADDR" : @VM : 1)
>
> Thanks,
>
> Nick Cipollina
>
> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On Behalf Of Glen B
> Sent: Thursday, February 24, 2005 6:13 PM
> To: [email protected]
> Subject: RE: [U2][UV] Forcing a port to close
>
>  This is a typical socket address condition that can't be safely
> overridden by hand. If you look at your net stats, the socket in
> question is probably in a CLOSE_WAIT state. This is a subsystem status
> that says the remote has shutdown and it's waiting for the
> socket to close and cleanup. If the socket gets dumped improperly by the
> socket application, then the socket can be left in
> CLOSE_WAIT with no process attached to finish cleanup. The status will
> clear up, but it could take a long time. That all depends on
> the tcp_close_wait setup and whether or not the socket is setup with the
> SO_LINGER flag. If the socket's SO_REUSEADDR flag can be
> enabled using some kind of U2 "setsocketopt" function before you listen
> on it, then you can re-use the same socket address over and
> over again.
>
> Check out this sockets FAQ:
> http://www.unixguide.net/network/socketfaq/
>
>
> Glen
> http://picksource.com
> http://mvdevcentral.com
>
> > -----Original Message-----
> > From: [EMAIL PROTECTED]
> > [mailto:[EMAIL PROTECTED] Behalf Of Nick Cipollina
> > Sent: Thursday, February 24, 2005 4:20 PM
> > To: [email protected]
> > Subject: [U2][UV] Forcing a port to close
> >
> >
> > Is anyone aware of a way to force a socket port to close at the
> > operating system level.  We are currently using Sun 9.xx.  We have a
> > process that opens a port and accepts socket connections.  Whenever we
> > stop it and try to restart it, we get a port in use message.  The only
> > way that I've been able to get it to release the port is to stop and
> > start universe again.  I'm just wondering if there is a way to force
> the
> > port to close.  Thanks.
> >
> >
> >
> > Nick Cipollina
> >
> >
> >
> > Pick Programmer
> >
> > ACS - Heritage Information Systems, Inc.
> >
> > 2810 North Parham Road, Suite 210
> >
> > Richmond, VA 23294
> >
> > (804)644-8707 x 314
> > -------
> > u2-users mailing list
> > [email protected]
> > To unsubscribe please visit http://listserver.u2ug.org/
> -------
> u2-users mailing list
> [email protected]
> To unsubscribe please visit http://listserver.u2ug.org/
> -------
> u2-users mailing list
> [email protected]
> To unsubscribe please visit http://listserver.u2ug.org/
-------
u2-users mailing list
[email protected]
To unsubscribe please visit http://listserver.u2ug.org/

Reply via email to