SoftTree Technologies SoftTree Technologies
Technical Support Forums
RegisterSearchFAQMemberlistUsergroupsLog in
Running Script Library Function on Remote Agen

 
Reply to topic    SoftTree Technologies Forum Index » 24x7 Scheduler, Event Server, Automation Suite View previous topic
View next topic
Running Script Library Function on Remote Agen
Author Message
Michael Tuszynski



Joined: 07 May 2004
Posts: 30

Post Running Script Library Function on Remote Agents Reply with quote

I have written a few Script Library functions and used them in a few JAL jobs.
When I deploy a job to one of the remote agents, I get a fail "Keyword not found.",
which references one of my functions from my script library. When I run the script
locally, I get no errors.


Wed May 12, 2004 10:05 am View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7955

Post Re: Running Script Library Function on Remote Agen Reply with quote

Script Library is not part of a job definition and because of that it is not deployed automatically. To deploy it to remote agents you need to copy your job database file either manually to remote agents or modify your jobs to copy the entire file or just the script library every time the job runs (copy it using "on job start" notification action). You can use FileTransfer or RemoteCopySettings for this purpose.

If you don't modify your functions very often I suggest copying the file manual. I don't think it makes much sense to add unnecessary processing for every job run.

If you modify your functions often then add RemoteCopySettings call with "SCRIPT LIBRARY" parameter to the code of the job start notification action.

: I have written a few Script Library functions and used them in a few JAL
: jobs.
: When I deploy a job to one of the remote agents, I get a fail "Keyword
: not found.",
: which references one of my functions from my script library. When I run the
: script
: locally, I get no errors.

Wed May 12, 2004 10:35 am View user's profile Send private message
Michael Tuszynski



Joined: 07 May 2004
Posts: 30

Post Re: Running Script Library Function on Remote Agen Reply with quote

Could you be a bit more specific? I have one Master Schedule (where my current Script
Library resides.) I want to copy that script library to each of my 3 remote agents.

I have written a 1 line script:

RemoteCopySettings "MASTER", "SCRIPT LIBRARY"

Do I run this on the Master Scheduler? On each of the remote agents?

: Script Library is not part of a job definition and because of that it is not
: deployed automatically. To deploy it to remote agents you need to copy
: your job database file either manually to remote agents or modify your
: jobs to copy the entire file or just the script library every time the job
: runs (copy it using "on job start" notification action). You can
: use FileTransfer or RemoteCopySettings for this purpose.

: If you don't modify your functions very often I suggest copying the file
: manual. I don't think it makes much sense to add unnecessary processing
: for every job run.

: If you modify your functions often then add RemoteCopySettings call with
: "SCRIPT LIBRARY" parameter to the code of the job start
: notification action.

Wed May 19, 2004 1:04 pm View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7955

Post Re: Running Script Library Function on Remote Agen Reply with quote

You run this on the master

RemoteCopySettings "Agent 1", "SCRIPT LIBRARY"
RemoteCopySettings "Agent 2", "SCRIPT LIBRARY"
RemoteCopySettings "Agent 3", "SCRIPT LIBRARY"

: Could you be a bit more specific? I have one Master Schedule (where my
: current Script
: Library resides.) I want to copy that script library to each of my 3 remote
: agents.

: I have written a 1 line script: RemoteCopySettings "MASTER",
: "SCRIPT LIBRARY"

: Do I run this on the Master Scheduler? On each of the remote agents?

Wed May 19, 2004 1:52 pm View user's profile Send private message
Michael Tuszynski



Joined: 07 May 2004
Posts: 30

Post Re: Running Script Library Function on Remote Agen Reply with quote

: You run this on the master

: RemoteCopySettings "Agent 1", "SCRIPT LIBRARY"
: RemoteCopySettings "Agent 2", "SCRIPT LIBRARY"
: RemoteCopySettings "Agent 3", "SCRIPT LIBRARY"

When I run this code(using either the alias of the agent or the actual computer name), I get the error:

"An error occurred while executing automation script.
Line 1: . Extended error code: -4000.
Continue testing this job?"

When I go to Tools->Remote Agents and test the connection, it prompts me for a user/pass.
I enter the proper credentials and get a good connection. I think this might be the issue.

Mon May 24, 2004 9:32 am View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7955

Post Re: Running Script Library Function on Remote Agen Reply with quote

In the code you must enter agent's name exactly as it appears in the Tools/Remote Agents dialog.

"Extended error code: -4000" usually indicates user authentication errors or administrator permission errors. When you test the connection you get a chance to enter user/password interactively. When the job runs on schedule or triggered manually it uses currently logged on user name for the connection. If you have security options enabled on the agent this can cause non-interactive job logon to fail because the user is unknown to the remote agent or has insufficient permissions. Try turning off security options on the agent and then running the job. This way you can find out if this is a permissions issue.

: When I run this code(using either the alias of the agent or the actual
: computer name), I get the error: "An error occurred while executing
: automation script.
: Line 1: . Extended error code: -4000.
: Continue testing this job?"

: When I go to Tools->Remote Agents and test the connection, it prompts me
: for a user/pass.
: I enter the proper credentials and get a good connection. I think this might
: be the issue.

Mon May 24, 2004 9:56 am View user's profile Send private message
Michael Tuszynski



Joined: 07 May 2004
Posts: 30

Post Re: Running Script Library Function on Remote Agen Reply with quote

Still having problems running script library functions on remote agents. Although I
was able to successfully use the 'RemoteCopySettings' statement without error,
I cannot run script library functions on remote agents. How would I go about copying
the script library manually. As far as I can see, each remote agent doesnt have its
own job database, I have one master database running on the master scheduler, and
I select which remote agents on which to run jobs via the job wizard.

: In the code you must enter agent's name exactly as it appears in the
: Tools/Remote Agents dialog.

: "Extended error code: -4000" usually indicates user authentication
: errors or administrator permission errors. When you test the connection
: you get a chance to enter user/password interactively. When the job runs
: on schedule or triggered manually it uses currently logged on user name
: for the connection. If you have security options enabled on the agent this
: can cause non-interactive job logon to fail because the user is unknown to
: the remote agent or has insufficient permissions. Try turning off security
: options on the agent and then running the job. This way you can find out
: if this is a permissions issue.

Thu Jun 17, 2004 6:58 am View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7955

Post Re: Running Script Library Function on Remote Agen Reply with quote

Yes, it does not load jobs, but when a script function is called it loads it from the file dynamically.
'RemoteCopySettings' simply copies the specified settings from one computer to another. Some settings are stored in the registry, other stored in the job database file. Because the script library is part of the file calling 'RemoteCopySettings' with script library as a parameter causes this part of the file to be copied. The library is copied from an active job db file on one computer to an active job db file on another computer. File names and locations can be different.
In case if you want to copy it manually: if your scheduler uses file A.dat and your agent uses file B.data, don't simply copy A.dat to the agent computer, set the agent to use file A.dat as an active file (there are several ways how this can be done but the easiest is to start 24x7 Scheduler on the agents computer using "24x7.exe /NOTIMER" command line and then select File/Open menu to open the file, then exit the scheduler).

: Still having problems running script library functions on remote agents.
: Although I
: was able to successfully use the 'RemoteCopySettings' statement without
: error,
: I cannot run script library functions on remote agents. How would I go about
: copying
: the script library manually. As far as I can see, each remote agent doesnt
: have its
: own job database, I have one master database running on the master scheduler,
: and
: I select which remote agents on which to run jobs via the job wizard.

Thu Jun 17, 2004 8:41 am View user's profile Send private message
Display posts from previous:    
Reply to topic    SoftTree Technologies Forum Index » 24x7 Scheduler, Event Server, Automation Suite All times are GMT - 4 Hours
Page 1 of 1

 
Jump to: 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


 

 

Powered by phpBB © 2001, 2005 phpBB Group
Design by Freestyle XL / Flowers Online.