Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Qlik Sense Task Failure Notifications

Hi,

Is there a verifiable solution for configuring task failure notifications/emails? I have seen a few posts about this in the past, but haven't come across anyone having success.

18 Replies
ekech_infomotio
Partner - Creator II
Partner - Creator II

kevincase‌ : followed your instructions, but it still doesn't work. Do we need to restart some services? (which one?)

kevincase
Creator II
Creator II

Edgar,

Not sure if you ever got this working.  Sorry for the delay.  You can restart the scheduler service but I do not believe that it is a requirement.

Validate that the file location and name are correct.  Also make sure you do not have any restrictions sending email from the Qlik server.  Many times for security purposes, ports may be closed or sending email to/from a particular address is prohibited from the server.

This is supported by Qlik so if you are unable to get it to function, you should be able to open a support ticket.

Kevin

elizabethbamber
Partner - Contributor II
Partner - Contributor II

Hi Edgar

If you are still looking at this I got this working by making a very minor tweak to the XML to simply remove the duplicated last line "</configuration>" in larger font .

Thanks to Kevin for this info.

kevincase
Creator II
Creator II

Elizabeth,

Sorry about the typographical error.  I must have done the Copy/Paste incorrectly.

To all:  This is what the code should look like but you will still need to follow steps 1 through 6 from above.

<?xml version="1.0"?>

<configuration>

<!-- Mail appender-->

<appender name="MailAppender" type="log4net.Appender.SmtpAppender">

  <filter type="log4net.Filter.StringMatchFilter">

    <param name="stringToMatch" value="ReloadResult" />

    <param name="acceptOnMatch" value="false" />

  </filter>

  <filter type="log4net.Filter.LevelRangeFilter">

    <param name="levelMin" value="ERROR" />

  </filter>

  <filter type="log4net.Filter.DenyAllFilter" />

  <evaluator type="log4net.Core.LevelEvaluator">

    <param name="threshold" value="ERROR"/>

  </evaluator>

  <param name="to" value="kevin@MyEmail.com" />

  <param name="from" value="Qlik@MyQlikServer.com" />

  <param name="subject" value="Qlik Job Failure" />

  <param name="smtpHost" value="MySMTPAddress" />

  <param name="port" value="25" />

  <param name="bufferSize" value="0" /> <!-- Set this to 0 to make sure an email is sent on every error -->

  <param name="lossy" value="true" />

  <layout type="log4net.Layout.PatternLayout">

    <param name="conversionPattern" value="%newline%date %-5level %newline%property{TaskName}%newline%property{AppName}%newline%message%newline%newline%newline" />

  </layout>

</appender>

<!--Send mail on task failure-->

<logger name="System.Scheduler.Scheduler.Slave.Tasks.ReloadTask">

  <appender-ref ref="MailAppender" />

</logger>

</configuration>

kavitha_qlik
Contributor II
Contributor II

thanks Kevin, how can i update to include task name in the subject instead of Qlik Sense Job Failure.

kevincase
Creator II
Creator II

Kavitha,

I'm not sure you can do this.  Since the following is building the subject line, you would need a variable.  You can try putting property{AppName} in the subject.  Just a guess.

<param name="subject" value="Qlik Job Failure - property{AppName}" />

Not sure this will work but you can give it a try.

Dinesh2387
Partner - Contributor II
Partner - Contributor II

Thanks for the code Kevin!!

 

Is it possible to get the TaskName in the line 18?

for e.g., Task Name - 1_Active Directory Qlik Users QVD Extract

 // <param name="subject" value=%property{TaskName}"-Qlik Job Failure" />

Expected O/p: "1_Active Directory Qlik Users QVD Extract - Qlik Job Failure"

 

Can I get the suggestion for the code change to get the expected output as above

wajiha
Contributor
Contributor

Hello Kevin,

Thanks for sharing the code.

I have entered the code in the file and replaced "to" and "from" to my email address.

Now when any job fails, i dont get any email alert.

Can you please guide how your code worked?

Regards,

Wajiha

Serkan
Partner - Creator
Partner - Creator

Hi,

currently I have an issue because I want to stop the mail notification - so I deleted the LocalLogConfig.xml file from the path C:\ProgramData\Qlik\Sense\Scheduler and restarted the scheduler service.

Still getting some email notification.

Do you have any idea to solve the issue?

Regards