Community forum

Please note that VisualCron support is not actively monitoring this community forum. Please use our contact page for contacting the VisualCron support directly.


Black4cimt
2008-02-27T15:57:06Z
We are running Visual Cron to execute VBS scripts that monitor Disk utilization, Services, and process. THe problem that shows up is that when we are not physically logged into VisualCron as the DefaultAdmin, the job fails with the error "Cannot find the connection specified". The Tray client user has full rights, so what is causing this?
Sponsor
Forum information
Support
2008-02-27T16:08:45Z
I assume you are executing with foreground execution. You can alter the foreground execution settings to execute on any session. Currently, it seems like you have set it to launch on a special session/desktop. Check out the properties on the Foreground execution.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
Support
2008-02-27T16:11:31Z
Or do you mean it fails to execute when you are not logged in?
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
Black4cimt
2008-02-27T16:14:49Z
It fails when I am not logged in through the client. As soon as I log in through the client the job starts running successfully even though I don't actually DO anything in the client.
Support
2008-02-27T16:16:15Z
Don't you mean that it does not work when no one is logged in at the machine?
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
Black4cimt
2008-02-27T16:19:30Z
That does seem to be the case, yes.
Support
2008-02-27T16:21:53Z
Since the foreground task is dependant on that you have loaded a desktop you have 2 choices:

1. Never logoff, just lock the computer

or

2. Set auto login settings in foreground execution settings
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
Black4cimt
2008-02-27T16:25:04Z
The VB scripts that we run have never been logon-dependant before. They run in the background using Windows Task Scheduler without problems.
Support
2008-02-27T16:27:40Z
yes, it is hard to say what variable or environment property your script require as it does not work with Credentials in VisualCron. That is why we switched to Foreground execution which has this limitation. Another alternative would be to change the username of the VisualCron service.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
Black4cimt
2008-02-27T16:37:55Z
Maybe I am a bit confused. When the task runs today, It must run as a domain Admin because of tasks it performs, and it does run as the credentials that I set up in VisualCron (I can see the user in Task manager that called Wscript.exe). But your saying that it doesn't work with the credentials? Also are you saying that VisualCron will not work unattended?
Support
2008-02-27T16:56:42Z
No. To start from the beginning we must say that there are very few cases when something that works in the Task Scheduler does not directly work in VisualCron. As you have mentioned before some of your scripts work right away and some don't. If we focus on those that doesn't work we are now looking at this VBS script. I am no expert on VBS scripts and I could not tell directly what was special about your script that did not work. Debugging is needed and especially debugging on your machine. For some reason you could not use background execution.

Since we did not find the obvious reason and you wanted it to work we set it up as a Foreground task. When running it as a Foreground task we know that you get the exact same environment. The Foreground task runs unattended - if you set the right settings.

The Task scheduler works differently from VisualCron. That is why we provide these 2 modes. None of the modes provide identical Task scheduler environment. No mode including the pure Task scheduler mode solves everything. That is why we are discussing different alternatives.

Currently we have 3 alternatives:

1. Background execution (with service running as SYSTEM account) - does not work with current script. Debugging is needed.
2. Background execution (with service running as your user) - not confirmed if it works
3. Foreground execution - works

Option 1 is desired, but we need to break down the script and see where it fails. I hope this makes it more clear.



Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
Black4cimt
2008-02-27T17:03:43Z
Thanks a lot, that does clear things up. I appreciate you being so helpful. Just for kicks I went back in and fipped the scripts to background execution and they seem to be running alright. Time will tell, but as it sits they might not need foreground execution. I am not sure what drove me to put them as foreground execution in the first place now that I think about it. Anyway, the scripts work and all is good for the moment. Thanks a lot.
Scroll to Top