Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
reshma_km
Partner - Creator III
Partner - Creator III

Email alerts on Reload task failure - Qlik sense

Hi,

I am trying to configure email alerts whenever a reload task fails using SmtpAppender. I am using Qlik sense November 2017 version. I found various discussions on this topic, but wasn't able to achieve it yet. Please find the code I am using for LocalLogConfig xml file below.

<?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="myname@domain.com" />

  <param name="from" value="myname@domain.com" />

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

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

  <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>

Could you please guide me?

kevincaseelizabethbamberltu

30 Replies
reshma_km
Partner - Creator III
Partner - Creator III
Author

Hi,

Please refer to the below link.

Qlik Branch

balabhaskarqlik

Did you resolved the issue, post the Solution and close the thread.

vicobi123
Contributor III
Contributor III

Hi, how would you then run this file after it's been created and saved to the right folder? Does this automatically send you an email when the apps have failed in the Tasks? 

 

 

Many thanks

martinpohl
Partner - Master
Partner - Master

Hi,

you need to restart the scheduler services, then it will automatically send an email.

Regards

vicobi123
Contributor III
Contributor III

Hi, how would i please do that? is that restarting the server itself?

martinpohl
Partner - Master
Partner - Master

logon to your Qlik Sense server by remote desktop session as an admin

start services

klick on Qlik Sense Scheduler service / restart

it only will restart this single service!

vicobi123
Contributor III
Contributor III

Hi, i tried that and i haven't gotten an email yet. I even re-ran one of my automatic tasks on QMC that fails and i didn't get an email. Any help would be useful please.

 

Thank you

kevincase
Creator II
Creator II

Vicobi,

There are a few things that must be correct.

1.  The xml file needs to be named LocalLogConfig.xml

2.  Verify that there are no rules preventing you from sending email internally from your Qlik server.  You may need a valid 'from' email address as well.

3.  Verify that the 'to' email is a valid email address.  I use a group email address and then use rules in exchange to distribute emails to specific users that are not part of the group.

4.  Verify that the file is in the correct location.  For me, it is  c:\programdata\qlik\sense\Scheduler

5. Verify that the email server and port are correct. 

Let us know how you make out.  If these are all correct, please attach a copy of your xml file.

Kevin .....

 

Serkan
Partner - Creator
Partner - Creator

Hi, 

does anyone know why I get an email after deleting the xml file from the path C:\ProgramData\Qlik\Sense\Scheduler and after restart of the scheduler service? It's strange and I couldn't found the issue.

Any idea?

Regards

kevincase
Creator II
Creator II

Serkan,

I tried to re-create this issue on my development Qlik server and after removing the file, I do not get an email.  You may possible need to open a case with support.  

I am running the February 2020 release of Qlik Sense.

Kevin .....