<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Can't attach PDF - ssName and pdfViewID unavailable in Reporting</title>
    <link>https://community.splunk.com/t5/Reporting/Can-t-attach-PDF-ssName-and-pdfViewID-unavailable/m-p/28181#M504</link>
    <description>&lt;P&gt;I'm trying to generate PDF reports with this search:&lt;/P&gt;

&lt;P&gt;source="/var/log/messages" host="ejabber-1" | head 1 | sendemail sendpdf=true to=&lt;EM&gt;email address&lt;/EM&gt;&lt;/P&gt;

&lt;P&gt;I get the email, but I also get a PDF error in python.log:&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;An error occurred while generating a PDF of this report: Can't attach PDF - ssName and pdfViewID unavailable&lt;/STRONG&gt;&lt;/P&gt;

&lt;P&gt;PDF email &lt;EM&gt;does&lt;/EM&gt; work  via the scheduled PDF function.&lt;/P&gt;

&lt;P&gt;I'm running Splunk 5.0.1 and CentOS 6.2.&lt;/P&gt;</description>
    <pubDate>Tue, 12 Feb 2013 00:29:57 GMT</pubDate>
    <dc:creator>atayarani_impri</dc:creator>
    <dc:date>2013-02-12T00:29:57Z</dc:date>
    <item>
      <title>Can't attach PDF - ssName and pdfViewID unavailable</title>
      <link>https://community.splunk.com/t5/Reporting/Can-t-attach-PDF-ssName-and-pdfViewID-unavailable/m-p/28181#M504</link>
      <description>&lt;P&gt;I'm trying to generate PDF reports with this search:&lt;/P&gt;

&lt;P&gt;source="/var/log/messages" host="ejabber-1" | head 1 | sendemail sendpdf=true to=&lt;EM&gt;email address&lt;/EM&gt;&lt;/P&gt;

&lt;P&gt;I get the email, but I also get a PDF error in python.log:&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;An error occurred while generating a PDF of this report: Can't attach PDF - ssName and pdfViewID unavailable&lt;/STRONG&gt;&lt;/P&gt;

&lt;P&gt;PDF email &lt;EM&gt;does&lt;/EM&gt; work  via the scheduled PDF function.&lt;/P&gt;

&lt;P&gt;I'm running Splunk 5.0.1 and CentOS 6.2.&lt;/P&gt;</description>
      <pubDate>Tue, 12 Feb 2013 00:29:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/Can-t-attach-PDF-ssName-and-pdfViewID-unavailable/m-p/28181#M504</guid>
      <dc:creator>atayarani_impri</dc:creator>
      <dc:date>2013-02-12T00:29:57Z</dc:date>
    </item>
    <item>
      <title>Re: Can't attach PDF - ssName and pdfViewID unavailable</title>
      <link>https://community.splunk.com/t5/Reporting/Can-t-attach-PDF-ssName-and-pdfViewID-unavailable/m-p/28182#M505</link>
      <description>&lt;P&gt;Did you ever find a solution to this problem? I am getting the same error.&lt;BR /&gt;
Thanks.&lt;/P&gt;</description>
      <pubDate>Sun, 10 Mar 2013 18:24:37 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/Can-t-attach-PDF-ssName-and-pdfViewID-unavailable/m-p/28182#M505</guid>
      <dc:creator>bfinney</dc:creator>
      <dc:date>2013-03-10T18:24:37Z</dc:date>
    </item>
    <item>
      <title>Re: Can't attach PDF - ssName and pdfViewID unavailable</title>
      <link>https://community.splunk.com/t5/Reporting/Can-t-attach-PDF-ssName-and-pdfViewID-unavailable/m-p/28183#M506</link>
      <description>&lt;P&gt;@bfinney, I still haven't heard back on this one.  The answer would definitely be appreciated.&lt;/P&gt;</description>
      <pubDate>Thu, 14 Mar 2013 18:26:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/Can-t-attach-PDF-ssName-and-pdfViewID-unavailable/m-p/28183#M506</guid>
      <dc:creator>atayarani_impri</dc:creator>
      <dc:date>2013-03-14T18:26:42Z</dc:date>
    </item>
    <item>
      <title>Re: Can't attach PDF - ssName and pdfViewID unavailable</title>
      <link>https://community.splunk.com/t5/Reporting/Can-t-attach-PDF-ssName-and-pdfViewID-unavailable/m-p/28184#M507</link>
      <description>&lt;P&gt;Some other people ran into a problem with this message after upgrading, perhaps you customized some email settings in alert_actions.conf in a previous version? Seems we have a migration oopsie with that. Try commenting out any custom "command = " in your local/alert_actions.conf. &lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 14:07:33 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/Can-t-attach-PDF-ssName-and-pdfViewID-unavailable/m-p/28184#M507</guid>
      <dc:creator>feorlen</dc:creator>
      <dc:date>2020-09-28T14:07:33Z</dc:date>
    </item>
    <item>
      <title>Re: Can't attach PDF - ssName and pdfViewID unavailable</title>
      <link>https://community.splunk.com/t5/Reporting/Can-t-attach-PDF-ssName-and-pdfViewID-unavailable/m-p/28185#M508</link>
      <description>&lt;P&gt;anyone with any answer on this?&lt;/P&gt;</description>
      <pubDate>Wed, 19 Jun 2013 08:21:54 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/Can-t-attach-PDF-ssName-and-pdfViewID-unavailable/m-p/28185#M508</guid>
      <dc:creator>batcave</dc:creator>
      <dc:date>2013-06-19T08:21:54Z</dc:date>
    </item>
    <item>
      <title>Re: Can't attach PDF - ssName and pdfViewID unavailable</title>
      <link>https://community.splunk.com/t5/Reporting/Can-t-attach-PDF-ssName-and-pdfViewID-unavailable/m-p/28186#M509</link>
      <description>&lt;P&gt;This was answered for me in a ticket, but since I can't really explain why it works now, I'm going to leave this open for the others that need help.&lt;/P&gt;</description>
      <pubDate>Fri, 21 Jun 2013 15:05:48 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/Can-t-attach-PDF-ssName-and-pdfViewID-unavailable/m-p/28186#M509</guid>
      <dc:creator>atayarani_impri</dc:creator>
      <dc:date>2013-06-21T15:05:48Z</dc:date>
    </item>
    <item>
      <title>Re: Can't attach PDF - ssName and pdfViewID unavailable</title>
      <link>https://community.splunk.com/t5/Reporting/Can-t-attach-PDF-ssName-and-pdfViewID-unavailable/m-p/28187#M510</link>
      <description>&lt;P&gt;Hi, we still have a similar problem. We upgraded from 4.3.3. to 5.0.6 directly. After this we only got this message in the python.log if we try to generate scheduled reports from our views/dashboards.&lt;/P&gt;

&lt;P&gt;2013-11-27 07:35:01,371 ERROR local variable 'ssName' referenced before assignment while sending mail to: &lt;A href="mailto:my.mail@address.com"&gt;my.mail@address.com&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;Does anybody found a solution to fix it?&lt;/P&gt;</description>
      <pubDate>Wed, 27 Nov 2013 06:38:08 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/Can-t-attach-PDF-ssName-and-pdfViewID-unavailable/m-p/28187#M510</guid>
      <dc:creator>krusty</dc:creator>
      <dc:date>2013-11-27T06:38:08Z</dc:date>
    </item>
    <item>
      <title>Re: Can't attach PDF - ssName and pdfViewID unavailable</title>
      <link>https://community.splunk.com/t5/Reporting/Can-t-attach-PDF-ssName-and-pdfViewID-unavailable/m-p/28188#M511</link>
      <description>&lt;P&gt;I tried your solution but nothing happens. &lt;/P&gt;

&lt;P&gt;Before I read this article our local/alert_actions.conf Shows like this:&lt;/P&gt;

&lt;P&gt;[email]&lt;BR /&gt;
reportServerEnabled = 1&lt;BR /&gt;
reportServerURL =&lt;BR /&gt;
from = &lt;A href="mailto:splunk@domain.com"&gt;splunk@domain.com&lt;/A&gt;&lt;BR /&gt;
mailserver = localhost&lt;/P&gt;

&lt;P&gt;I changed it to this and restart the splunk server process.&lt;/P&gt;

&lt;P&gt;[email]&lt;BR /&gt;
from = &lt;A href="mailto:splunk@domain.com"&gt;splunk@domain.com&lt;/A&gt;&lt;BR /&gt;
reportServerURL =&lt;/P&gt;

&lt;P&gt;But unfortnately we have the same problem.&lt;/P&gt;</description>
      <pubDate>Wed, 27 Nov 2013 06:39:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/Can-t-attach-PDF-ssName-and-pdfViewID-unavailable/m-p/28188#M511</guid>
      <dc:creator>krusty</dc:creator>
      <dc:date>2013-11-27T06:39:44Z</dc:date>
    </item>
    <item>
      <title>Re: Can't attach PDF - ssName and pdfViewID unavailable</title>
      <link>https://community.splunk.com/t5/Reporting/Can-t-attach-PDF-ssName-and-pdfViewID-unavailable/m-p/560447#M9356</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/70189"&gt;@atayarani_impri&lt;/a&gt;&amp;nbsp; This problem typically occurs when the name of the custom command does not match the name defined in the sendemail.py file. I encountered this when I made a copy of the default sendemail.py file to make our own custom sendemail command. I named the new command newsendemail (with the file newsendemail.py).&amp;nbsp;&lt;/P&gt;&lt;P&gt;In the file newsendemail.py, there is a piece of code:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;sendemailRegex = r'\|\s*sendemail'
if (re.findall(sendemailRegex, searchToRun)):
  parameters['input-search'] = re.split(sendemailRegex, searchToRun)[0]
  parameters['et'] = jsonJob.get('earliestTime')
  parameters['lt'] = jsonJob.get('latestTime')
else:
  raise PDFException("Can't attach PDF - ssName and pdfViewID unavailable")&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is where that error is generated. For us, I had to change the&amp;nbsp;&lt;/P&gt;&lt;P&gt;r'\|\s*sendemail'&lt;/P&gt;&lt;P&gt;part to&lt;/P&gt;&lt;P&gt;r'\|\s*newsendemail'&lt;/P&gt;&lt;P&gt;The regex is searching for 'sendemail' in the search query, but the name of the custom command has been changed to 'newsendemail', so the regex needs to be updated. The error occurs if the regex does not find anything in the search query.&lt;/P&gt;</description>
      <pubDate>Thu, 22 Jul 2021 09:28:20 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Reporting/Can-t-attach-PDF-ssName-and-pdfViewID-unavailable/m-p/560447#M9356</guid>
      <dc:creator>BernardEAI</dc:creator>
      <dc:date>2021-07-22T09:28:20Z</dc:date>
    </item>
  </channel>
</rss>

