Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Table of Contents
outlinh1. true
outlinh1. true
1printablefalse
2stylh1. none
3indent20px

...

Introduction

When a backup Job Scheduler Backup JobScheduler instance in a Job Scheduler JobScheduler Backup /Failover cluster takes over, it could be usefull that someone will be informed about this. Here comes a simple approach how to get achieve this.

JobScheduler Clusters. Sending email on take over

The idea is to make a job that starts once on Job Scheduler JobScheduler start and sends an email e-mail on certain conditions. One condition in a backup /failover cluster could be the host name of the server that the backup Job Scheduler is runningBackup JobScheduler is operated for.

Here is the xml for configurationfor this kind of job.:

Code Block
 <job  title="Send Mails" order="no" name="CheckStart">
     <description >
         <include  file="jobs/JobSchedulerManagedMailJob.xml"/>
     </description>
 
     <params >
         <param  name="to" value="admin@company.com"/>
         <param  name="subject" value="Job Scheduler has been startet."/>
         <param  name="host" value="smtp.server"/>
         <param  name="body" value="Job Scheduler has been startet"/>
     </params>
 
     <script  language="java" java_class="sos.scheduler.managed.JobSchedulerManagedMailJob"/>
 
     <monitor  name="check" ordering="0">
         <script  language="java:javascript">
             <![CDATA[
 function spooler_process_before() {
     spooler_log.info(spooler.hostname);
     return (spooler.hostname == "js_backup");
 }
              ]]>
         </script>
     </monitor>
 
     <run_time  once="yes"/>
 </job>