Differences
This shows you the differences between the selected revisions of the page.
| 2008-04-10 | 2008-07-09 | ||
| missing of (martin) | another consequence is absence of envvar (martin) | ||
| Line 1: | Line 1: | ||
| - | ====== My script works fine when executed manually, but fails when run by Windows Scheduler or a similar tool. What am I doing wrong? ====== | + | ====== My script works fine when executed manually, but fails when run by Windows Scheduler or another automation tool. What am I doing wrong? ====== |
| You probably depend on your configuration of WinSCP. Note that when using registry as [[config|configuration storage]], the settings are accessible only for your Windows account. When the script is run from Windows Scheduler, it is typically run under different account that cannot access your configuration. | You probably depend on your configuration of WinSCP. Note that when using registry as [[config|configuration storage]], the settings are accessible only for your Windows account. When the script is run from Windows Scheduler, it is typically run under different account that cannot access your configuration. | ||
| Line 5: | Line 5: | ||
| * The script "hangs" because the host key is not known by the Scheduler's account and WinSCP asks for its [[ssh#verifying_the_host_key|verification]] (SFTP and SCP only). | * The script "hangs" because the host key is not known by the Scheduler's account and WinSCP asks for its [[ssh#verifying_the_host_key|verification]] (SFTP and SCP only). | ||
| * The connection fails, because your script depends on stored session, which is not known by the Scheduler's account. | * The connection fails, because your script depends on stored session, which is not known by the Scheduler's account. | ||
| + | * Environment variables referenced in script are not resolved, because they are not set by the Scheduler's account. | ||
| Solutions: | Solutions: | ||