...
- Import Module
PS C:\> Import-Module JobScheduler
- loads the module from a location that is available with the PowerShell module path,
- see
$env:PSModulePath
for predefined module locations.
PS C:\> Import-Module C:\some_module_location\JobScheduler
- loads the module from a specific location, absolute and relative paths can be used.
- Use JobScheduler Master Instance
- As a first operation after importing the module it is required to execute the
Use-Master
cmdlet. PS C:\> Use-Master Url <Url>
orPS C:\> Use-Master -Url Url Url <Url>
- specifies the URL for which the JobScheduler Master is available. This is the same URL that you would use when opening the JOC GUI in your browser, e.g.
http://localhost:4444
. Do not omit the protocol (http/https) for the URL. - allows to execute cmdlets for the specified Master independently from the server and operating system that the JobScheduler Master is operated for, i.e. you can use PowerShell cmdlets to manage a JobScheduler Master running on a Linux box.
- specifying the URL is not sufficient to manage the Windows Service of the respective Master, see below.
- specifies the URL for which the JobScheduler Master is available. This is the same URL that you would use when opening the JOC GUI in your browser, e.g.
PS C:\> Use-Master JobSchedulerID <JobSchedulerID>
orPS C:\> Use-Master -Id JobSchedulerIDId <JobSchedulerID>
- references the JobScheduler ID that has been assigned during installation of a Master.
- adds the JobScheduler ID to the assumed installation base path.
- A typical base bath would be
C:\Program Files\sos-berlin.com\jobscheduler
- The path is added the subdirectory with the name of the JobScheduler ID
- A typical base bath would be
PS C:\> Use-Master -InstallPath " <InstallationPath>
- specifies the full installation path, e.g.
C:\Program Files\sos-berlin.com\jobscheduler\
- for local JobScheduler instances the installation path can be specified
scheduler1.10
, for a locally available JobScheduler Master.
- specifies the full installation path, e.g.
PS C:\> Use-Master -InstallPath $env:SCHEDULER_HOME
- It is recommended to create You can use an environment variable
SCHEDULER_HOME
that points to the installation path. - The JobScheduler CLI module on import checks availability of this environment variable
- The
Use-Master
cmdlet is executed automatically ifSCHEDULER_HOME
is present.
- It is recommended to create You can use an environment variable
PS C:\> Use-Master <Url> <JobSchedulerID>
- specify both URL and JobScheduler ID (recommended).
- determines if the Master with the specified JobSchedulerID is locally available.
- As a first operation after importing the module it is required to execute the
- Manage JobScheduler Objects
PS C:\> Show-Status
- shows the summary information for a JobScheduler Master
PS C:\> Get-Order
PS C:\> Get-JobChain
PS C:\> Get-Job
PS C:\> Get-Task
- retrieves the list of avaiable objects
- see complete list of cmdlets with the cmdlet:
Get-Command -Module JobScheduler
...