<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet type="text/xsl" href="https://skynorthsoftware-com.azurewebsites.net/blog/rss/xslt"?>
<rss xmlns:a10="http://www.w3.org/2005/Atom" version="2.0">
  <channel>
    <title>SkyNorth</title>
    <link>https://skynorthsoftware-com.azurewebsites.net/blog/</link>
    <description>Blog</description>
    <generator>Articulate, blogging built on Umbraco</generator>
    <item>
      <guid isPermaLink="false">1175</guid>
      <link>https://skynorthsoftware-com.azurewebsites.net/blog/posts/intermittent-workflow-failures-the-workflow-failed-to-start-due-to-an-internal-error/</link>
      <category>SharePoint</category>
      <title>Intermittent Workflow failures – ‘The workflow failed to start due to an internal error’</title>
      <description>&lt;p&gt; &lt;/p&gt;
&lt;p&gt;I just got through working a pretty nasty workflow issue that had  nothing to go on with verbose ULS logging.   Our issue was that even the most basic workflow’s were failing on a brand new custom list, with the first item created.  After the first item was created the workflow would work fine for X amount of time.   This issue was ugly, and intermittent, and it probably would have helped if I read this first - &lt;a href="http://support.microsoft.com/kb/2001370"&gt;http://support.microsoft.com/kb/2001370&lt;/a&gt;&lt;/p&gt;
&lt;p&gt; We found a way to reproduce the error with the following:&lt;/p&gt;
&lt;p&gt;1.)   Create a new list&lt;/p&gt;
&lt;p&gt;2.)   Create a new workflow with SharePoint Designer&lt;/p&gt;
&lt;p&gt;             a.)   Step 1: Email user X&lt;/p&gt;
&lt;p&gt;3.)   Create a new list item&lt;/p&gt;
&lt;p&gt;4.)   Start the workflow&lt;/p&gt;
&lt;p&gt;5.)   Watch the failure&lt;/p&gt;
&lt;p&gt;&lt;span style="text-decoration: underline;"&gt;&lt;strong&gt;Note:&lt;/strong&gt;&lt;/span&gt; Every other attempt after this work would fine  (restarting the workflow)&lt;/p&gt;
&lt;p&gt; &lt;img style="width: 500px; height: 230.96026490066225px;" src="https://skynorthsoftware-com.azurewebsites.net/media/1005/2451_error.jpg?width=500&amp;amp;height=230.96026490066225" alt="" data-udi="umb://media/1b5d7946a151428caed617e34f3fa0cb" /&gt;&lt;a href="https://msdnshared.blob.core.windows.net/media/TNBlogsFS/prod.evol.blogs.technet.com/CommunityServer.Blogs.Components.WeblogFiles/00/00/00/95/77/2451.error.jpg"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt; Like I said – the ULS logs were clean, tracking the correlation ID we came up with nothing.    Right when we took a break to review the final 3 sets of logs, my friend Wes had attempted a fix he used in the past with another workflow problem.&lt;/p&gt;
&lt;p&gt;&lt;span style="text-decoration: underline;"&gt;&lt;strong&gt;Disabling the &lt;a href="http://support.microsoft.com/kb/2001370"&gt;OffWfCommon&lt;/a&gt; feature&lt;/strong&gt;.&lt;/span&gt; &lt;/p&gt;
&lt;p&gt;disable-spfeature -identity  "OFFWfCommon" –url &lt;a href="http://yoursitehere/sites/site"&gt;http://yoursitehere/sites/site&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;enable-spfeature –identify “OffWfCommon”    –url  &lt;a href="http://yoursitehere/sites/site"&gt;http://yoursitehere/sites/site&lt;/a&gt;&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;After doing this the workflow consistently worked - but had me questions as to why, so I did some checking and I have found this to be a fix for other similar workflow issues such as a modified “Workflow Task” content type version that contains this error:  &lt;/p&gt;
&lt;p&gt;&lt;span style="color: #ff0000;"&gt;&lt;strong&gt;The requested workflow task content type was not found on the SPWeb&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;If you have a modified "Workflow Task" version greater then 0 and are seeing this same issue, the steps above may be relevant.  I would always recommend testing this in a test environment fully before doing it.   Here is some sample PowerShell code to help find versions that are not 0.  Again, to be used in a test environment.&lt;/p&gt;
&lt;p&gt; $site = get-spsite &lt;a href="http://yoursitehere/sites/site"&gt;http://yoursitehere/sites/site&lt;/a&gt;  &lt;br /&gt;$site = $site.RootWeb &lt;br /&gt;foreach ($sites in $site) &lt;br /&gt;{ &lt;br /&gt;   foreach ($ctype in $site.ContentTypes) &lt;br /&gt;  { &lt;br /&gt;       if ($ctype.name -eq "workflow Task" -and $ctype.version -gt "0") &lt;br /&gt;           {&lt;/p&gt;
&lt;p&gt;              $ctype.Scope,$ctype.name,$ctype.version } &lt;br /&gt;            }&lt;/p&gt;
&lt;p&gt;  }&lt;/p&gt;
&lt;p&gt;}&lt;/p&gt;
&lt;p&gt; Please only use these steps if you are experience the exact scenarios listed above, and I hope this helps you!&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;</description>
      <pubDate>Tue, 03 Oct 2017 14:15:16 Z</pubDate>
      <a10:updated>2017-10-03T14:15:16Z</a10:updated>
    </item>
  </channel>
</rss>