SimpleXMLRPCServer Releasing Ports

Gerhard Häring gerhard.haering at
Tue Oct 8 17:25:56 CEST 2002

Ulli Stein <mennosimons at> [2002-10-08 13:32 GMT]:
> John Abel wrote:
>> Hi,
>> I have a script running, using SimpleXMLRPCServer, which works OK.
>>  Except, when I stop, and restart the script, I receive the error,
>> "Address already in use".  Is there something I can do, like a
>> destructor, to tidy up, so that the script can be restarted?
>> Thanks
>> John
> It is probably an os issue. Maybe you can tweak it using low level socket 
> operations which state how long your IP/Port will be blocked.

Yep. The SO_REUSE flag should do the trick. But that probably means changing
the xmlrpclib module in some way.

-- Gerhard

More information about the Python-list mailing list