Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: Re: Win32::AdvNotify problems

by cheshirecat (Sexton)
on May 29, 2002 at 14:05 UTC ( [id://170086]=note: print w/replies, xml ) Need Help??


in reply to Re: Win32::AdvNotify problems
in thread Win32::AdvNotify problems

Jenda,

Thanks for the comprehensive reply, I'm sorry I didn't make the question clear.

I can create a service using Win32::Daemon and have done so successfully. I have built an application using both Win32::AdvNotify and Net::FTP to syncronise the content management server with the webserver. This application is currently run as a console application where the Win2k Server has been logged in.

I am now try to make the application a service so our IT guys do not have to log in to start the application.

The problem appears to that Win32::AdvNotify requires a console window and as the service will be running without being logged in, there will be no console.

I have investigated the perl code in Win32::AdvNotify and I have tried replacing use Carp; with use CGI::Carp qw(carpout); but still no luck.

I have not compiled the script, I am just running it under the windows services control panel (ie I have installed it as a service).

I hope this makes my problem clearer.

Regards
The Cat

Replies are listed 'Best First'.
Re: Re: Re: Win32::AdvNotify problems
by Jenda (Abbot) on May 29, 2002 at 21:08 UTC
    • But you are positive the script runs, right?
    • Under what account does the service run? Did you try to run it under the account of the user that it was running under before?
    • Do you get any errors somewhere?
    • What about if you redirect both STDOUT and STRERR to a log file in a BEGIN{} block on top of your script? Do you see anything there then?
    • Do you try to access any mapped drives or UNCs from the script? While the second should work fine if you run the service under a domain account, the first is doomed to fail. As you may know, the drives are mapped per user session, so the service doesn't see them. And I believe even if they were set as "persistent" for the user the service runs under they would not be available.

    I do not see any reason why would Win32::AdvNotify require a console. I'd think permissions are a much more likely culprit.

    If you think it is the console and you run the service under LocalSystem account you may try to "Allow service to interact with desktop". That should allow it to create a console, though maybe it will be visible only if there is someone loged on.

      Hope one of the wild guesses will help :-)
      Jenda

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://170086]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others romping around the Monastery: (6)
As of 2024-04-19 15:42 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found