[Win32utils-devel] Problem with starting service with win32-service
sean.karlage at uky.edu
Mon Aug 5 17:02:49 UTC 2013
Do I need to require win32/daemon in the controller as well?
On Sat, Aug 3, 2013 at 1:32 AM, Heesob Park <phasis at gmail.com> wrote:
> 2013/7/25 Sean Karlage <sean.karlage at uky.edu>:
> > Hi all,
> > At Daniel's request, I'm posting my problem to this mailing list in the
> > that it can be resolved.
> > I'm using Windows 7 x64 in a virtual machine with an OS X 10.8.4 host,
> > I'm using win32-service 0.8.0 (obtained via a gem install). Ruby version
> > ruby 2.0.0p195 [x64-mingw32].
> > This service monitors a directory (and all files and subdirectories under
> > it) and notifies owners of those files at the emails in a file of
> > corresponding emails to usernames when they haven't been
> modified/touched in
> > some configurable amount of days. After some other (longer) number of
> > the files are purged.
> > I can install my service just fine, and it is picked up when I do a
> > Service.status() on it. However, when I go to actually start the service
> > immediately get 'The service did not respond to the start or control
> > in a timely fashion.' I followed Daniel's suggestion on his github page
> > wrapped my service in a begin/end block, and ensured that the command
> > executable was correct, but control doesn't even seem to be getting to my
> > service code at all - control does not even enter service_main at all as
> > as I can tell.
> > I've attached my code, as well as a sample configuration file. I'd
> > appreciate any help with this.
> > All three files should be in the same directory when they are run. It
> can be
> > executed as follows:
> > ruby sharecleaner_daemon_controller.rb [-config C:/path/to/config/file]
> > [-emails C:/path/to/emails/file] install|start|uninstall|pause|resume
> You should use
> require 'win32/daemon'
> instead of
> require 'win32/service'
> in the file sharecleaner_daemon.rb line 5.
> Park Heesob
> win32utils-devel mailing list
> win32utils-devel at rubyforge.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the win32utils-devel