Re: Stop/Start nameserver
Irmen de Jong <[email protected]> Thu, 21 May 2015 18:47:45 +0200
| Newsgroups | gmane.comp.python.pyro |
|---|---|
| Message-ID | <[email protected]> |
On 21-5-2015 11:41, Dick Kniep wrote: > Hi Minesh, > > Thanks for your answer, however, I think this is not the solution to my problem. What > you suggest is relevant if the nameserver is running, and one wants to re-use the > socket. However, my problem is that the nameserver simply does not start immediately > after it has been stopped (by supervisor). I get a traceback where pyro states that > the port is in use. This will sometimes last for 5 minutes or more. By then > supervisor does not try to restart the process anymore and gives up. Err? Pyro4.config.SOCK_REUSE = True --> sets SO_REUSEADDR on the socket. The SO_REUSEPORT option which is a recent addition to Linux kernals, is the one that permits multiple listeners on a single socket. This option is not used by Pyro. If enabling SO_REUSEADDR doesn't do what you want, I dunno what else to try. Pyro's server socket creation is fairly standard. And I'm not aware of any other socket options to set that may be relevant. How do you stop the nameserver? Do you kill -9 it? That will probably leave the socket behind in a bad state. Try shutting it down in a regular fashion. Irmen ------------------------------------------------------------------------------ One dashboard for servers and applications across Physical-Virtual-Cloud Widest out-of-the-box monitoring support with 50+ applications Performance metrics, stats and reports that give you Actionable Insights Deep dive visibility with transaction tracing using APM Insight. http://ad.doubleclick.net/ddm/clk/290420510;117567292;y