[Twisted-Python] Windows NT Service Problem

Benjamin Henry bhenry at pacecocorp.com
Thu May 17 16:54:47 MDT 2007


What reactor are you using?

 

Code that I've used in the global scope for my .tac file is:

 

application=service.Application('Service Name',uid=1000,gid=100)

factory = DerivedFactory()

 

internet.TCPServer(80,
factory).setServiceParent(service.IServiceCollection(application))

 

I ran setup.py (moonfallen's code), registered the service, and it
worked fine.

 

Have you specified a specific reactor, or called reactor.run()?  You
don't need to do that.

 

Regards,

 

Ben

> -----Original Message-----

> From: twisted-python-bounces at twistedmatrix.com [mailto:twisted-python-

> bounces at twistedmatrix.com] On Behalf Of Berkstresser, Dan

> Sent: Thursday, May 17, 2007 1:52 PM

> To: twisted-python at twistedmatrix.com

> Subject: [Twisted-Python] Windows NT Service Problem

> 

> Hello, I am trying to get my twisted project to run as a Windows

> Service.  I have followed the instructions here:

> http://gradstein.info/DeployingTwistedWindows

> as well as here:

> http://svn.twistedmatrix.com/cvs/sandbox/moonfallen/?rev=18080#dirlist

> 

> I have tried setting it up with twistd and also using the runner.py

> script with the same result.

> 

> I can build the executable and install the service, but whenever I try

> to start it it exits immediately.  The Event Log shows this error:

> 

> The instance's SvcRun() method failed

>   File "win32serviceutil.pyc", line 785, in SvcRun

>   File "ntsvc\runner.pyc", line 79, in SvcDoRun

>   File "ntsvc\runner.pyc", line 48, in run

>   File "twisted\application\reactors.pyc", line 82, in installReactor

> twisted.application.reactors.NoSuchReactor: ''

> 

> I have tried changing the ntsvc.cfg to 'default' for the reactor entry

> and also leaving it blank.  (default says NoSuchReactor: 'default').

> 

> Any help would be greatly appreciated.

> 

> Thanks,

> 

> Dan Berkstresser

> 

> 

> 

> _______________________________________________

> Twisted-Python mailing list

> Twisted-Python at twistedmatrix.com

> http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python

-------------- next part --------------
An HTML attachment was scrubbed...
URL: </pipermail/twisted-python/attachments/20070517/ee909b85/attachment.html>


More information about the Twisted-Python mailing list