<?xml version="1.0" encoding="utf-8"?>
<rss xmlns:atom="https://www.w3.org/2005/Atom" xmlns:sy="https://purl.org/rss/1.0/modules/syndication/" xmlns:dc="https://purl.org/dc/elements/1.1/" xmlns:content="https://purl.org/rss/1.0/modules/content/" xmlns:wfw="https://wellformedweb.org/CommentAPI/" xmlns:slash="https://purl.org/rss/1.0/modules/slash/"
  version="2.0">
  <channel>
    <title>Ritesh Ranjan</title>
    <atom:link
      href="https://docs.microsoft.com/archive/blogs/ritesh_ranjan/feed.xml"
      rel="self"
      type="application/rss+xml" />
    <link>https://docs.microsoft.com/archive/blogs/ritesh_ranjan/feed.xml</link>
    <description>Microsoft Dynamics CRM</description>
    <lastBuildDate>Wed, 17 Apr 2019 03:24:23 GMT</lastBuildDate>
    <language>en-US</language>
    <sy:updatePeriod>hourly</sy:updatePeriod>
    <sy:updateFrequency>1</sy:updateFrequency>
    <item>
      <title>Dynamics 365 Customer Engagement (aka Dynamics CRM) Attachment Management solution – Quick Q &amp; A</title>
      <link>https://docs.microsoft.com/archive/blogs/ritesh_ranjan/dynamics-365-customer-engagement-aka-dynamics-crm-attachment-management-solution-quick-q-a</link>
      <pubDate>Thu, 01 Feb 2018 18:12:30 GMT</pubDate>
      <dc:creator><![CDATA[Ritesh Ranjan - Technical Advisor]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/ritesh_ranjan/?p=285</guid>
      <description><![CDATA[Hello everyone!

Let me first wish you all a very happy and successful year, 2018.

Today, I am...]]></description>
      <content:encoded><![CDATA[Hello everyone!

Let me first wish you all a very happy and successful year, 2018.

Today, I am going to touch upon a common scenario within the Dynamics 365 Customer Engagement application, i.e. attachments, notes, annotations, images and all sort of attachments which you would have enabled in your application. This, from my experience, is inevitably taking a lot of space within your organization database. Especially when it comes to Online space, you are paying a lot for these attachments. Isn’t it? Or, you might be working on a proposal/solution where you would like to deliver an optimal and intuitive solution to your end users/customers from attachments perspective.

So, let me talk about one of the recent <strong>free</strong> solutions provided at the ‘<a href="https://appsource.microsoft.com/en-us/">AppSource</a>’ which was previously known as the Dynamics Market Place. Among the many solutions available there, I am going to talk about the ‘<a href="https://appsource.microsoft.com/en-us/product/dynamics-365/microsoft_labs.96257e65-dbbe-43db-b775-77cf1609530c?tab=Overview">Attachment Management</a>’. Recently, I have been working with a few of my customers across Europe where I had an opportunity to work on Attachment Management PoCs (proof of concepts) for them. Hence, I thought of sharing my learnings and experiences with you all, which could be useful to you for taking your decision quickly on managing the attachments in Dynamics 365 Customer Engagement<strong>. Let’s keep in mind that the Dynamics 365 Customer Engagement Application is meant for managing your customers in the form of sales, services and marketing and we should not treat this as a document management application</strong>. So, it becomes important for you to consider this fact while designing a solution. Also, when you have an Online application tenant, you are required to pay for these attachments storage which is expensive than the blob storage on Azure. Thus, I would recommend you think twice before you decide to keep your attachments within the Dynamics 365 Customer Engagement application organization database.

Let me share my quick thoughts on the above-mentioned solution: (I am only touching upon the scenarios I encountered while working with my customers and I would suggest you to start with looking at the solution first, <a href="https://appsource.microsoft.com/en-us/product/dynamics-365/microsoft_labs.96257e65-dbbe-43db-b775-77cf1609530c?tab=Overview">Attachment Management</a>)
<ul>
 	<li><strong>What happens when we delete a record in CRM after configuring the Attachment Management solution</strong> – it deletes the associated attachments on the blob storage too.</li>
</ul>
&nbsp;
<ul>
 	<li><strong>What are the ways of authenticating the Attachment Management solution with blob storage</strong> – this is completely and only based on SAS token at the moment.</li>
</ul>
&nbsp;
<ul>
 	<li><strong>Does the solution provide image previews</strong> – yes, it does, like below. You could also have previews of word docs, ppts, xls and pdfs.</li>
</ul>
<a href="https://msdnshared.blob.core.windows.net/media/2018/02/attachment-solution1.jpg"><img width="402" height="165" class="alignnone  wp-image-295" alt="" src="https://msdnshared.blob.core.windows.net/media/2018/02/attachment-solution1-300x123.jpg" /></a>

&nbsp;
<ul>
 	<li><strong>Can we use this as a data source to pull records from blob storage</strong> – yes, we can use it like the way we pull any records from CRM using GUIDs (for example: https://&lt;storage account name&gt;.blob.core.windows.net/&lt;container name&gt;/&lt;GUID&gt;_&lt;filename&gt;). We will have to mitigate any authentication challenges though, if any.</li>
</ul>
&nbsp;
<ul>
 	<li><strong>What happens to the existing attachments in the Dynamics 365 after configuration of attachment management solution</strong> - it starts moving the attachments to the blob automatically, but due to Dynamics 365 limitation of moving 140 records at a time, we would need to click on <strong>Move to Blob</strong> button, after every 140 records are moved. However, there is a solution to automate that too, which is using the logic apps, available on Github: <a href="https://github.com/anilvem1/LAMoveCRMAttachmentsToBlob">https://github.com/anilvem1/LAMoveCRMAttachmentsToBlob</a> . This will take care of the 140 limitations and move all the existing attachments automatically to the blob storage. Once all the existing attachments are moved, we don’t have to worry about moving the attachments manually or by using the logic apps, the Attachment Management will take care of moving all the attachments thereafter automatically. The logic apps solution which is built by one of the Microsoftians is required only initially to move all the existing attachments to the blob storage. Once all the attachments are moved, Attachment Management will handle attachments automatically by its own.</li>
</ul>
&nbsp;

&nbsp;
<ul>
 	<li><strong>Who could configure the attachment management solution in CRM</strong> – security is controlled by the Dynamics 365 security model which by default allows system administrators and customizers to make any changes, however this could also be controlled further by controlling the security roles in Dynamics 365.</li>
</ul>
<a href="https://msdnshared.blob.core.windows.net/media/2018/02/attachment-solution2.jpg"><img width="395" height="154" class="alignnone  wp-image-305" alt="" src="https://msdnshared.blob.core.windows.net/media/2018/02/attachment-solution2-300x117.jpg" /></a>

&nbsp;
<ul>
 	<li><strong>What happens once the attachments are moved to blob storage</strong> – Dynamics 365 Customer Engagement holds a reference to the moved attachments but the body (actual attachments) moves to the blob storage, freeing up the storage in the Dynamics 365 Customer Engagement organization database.</li>
</ul>
I guess, you would be now curious to test the solution and work on it, so I would highly recommend to refer the solution at <a href="https://appsource.microsoft.com/en-us/product/dynamics-365/microsoft_labs.96257e65-dbbe-43db-b775-77cf1609530c?tab=Overview">https://appsource.microsoft.com/en-us/product/dynamics-365/microsoft_labs.96257e65-dbbe-43db-b775-77cf1609530c?tab=Overview</a> . It includes a quick video about the configuration and usability, please do go through it to understand the solution well.

If you have any questions, I would encourage you to reach out to the Attachment Management support team at appsnotify@microsoft.com . I am always ready to answer your questions, but I know the Attachment Management is very active &amp; supportive and you would be taken care of by them well.

<strong>Disclaimer: </strong>

<strong>This blog post is solely written based on my experiences and learnings. There could be other solutions as well which you might want to try out, but I haven’t reviewed them yet. The idea is to share my learnings and experiences so far on this solution.</strong>]]></content:encoded>
    </item>
    <item>
      <title>Is Dynamics CRM (On-Premise as well as Online) Server-Side Sync filling up your ORG_MSCRM database and you wonder why?</title>
      <link>https://docs.microsoft.com/archive/blogs/ritesh_ranjan/dynamics-crm-on-premise-as-well-as-online-server-side-sync-filling-up-your-org_mscrm-database-and-you-wonder-why</link>
      <pubDate>Fri, 20 Oct 2017 13:17:03 GMT</pubDate>
      <dc:creator><![CDATA[Ritesh Ranjan - Technical Advisor]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/ritesh_ranjan/?p=195</guid>
      <description><![CDATA[Well, if you are wondering, looking at the TraceLogBase table size, that there is a problem with the...]]></description>
      <content:encoded><![CDATA[<p>Well, if you are wondering, looking at the TraceLogBase table size, that there is a problem with the Dynamics CRM Server-Side Sync, then I would say ‘NO’. There is no problem with the product but the fact that you might have ignored the fact that you are capturing all the logs, Information, Warnings &amp; Errors!</p>
<p>Dynamics CRM Server-Side Sync allows you to capture logs which could help in troubleshooting any issues with users mailboxes in regards to the Server-Side Sync. The alerts are shown on the Alerts wall or the Alerts section in the mailbox or email server profile records.</p>
<p>The following table shows how to view the alerts and the actions you can take on these alerts.</p>

<table>
<tbody>
<tr>
<td><strong>To</strong></td>
<td><strong>Do this</strong></td>
</tr>
<tr>
<td>View all alerts</td>
<td>
<p>Go to <strong>Sales</strong> &gt; <strong>Alerts</strong>.</p>

<ul>
 	<li>To delete all alerts at once, click or tap the Delete all alerts icon on the alerts wall.</li>
 	<li>To view just errors, warnings, or information, click or tap <strong>Errors</strong>, <strong>Warnings</strong>, or <strong>Information</strong> respectively.</li>
</ul>
<strong>If you are also synchronizing appointments, contacts, and tasks through server-side synchronization, you’ll see alerts for the following:</strong>
<ul>
 	<li>When one or more duplicate records are found in Microsoft Dynamics 365 when saving a record from Exchange to Microsoft Dynamics 365.</li>
 	<li>When a scheduling conflict is found when saving an appointment from Exchange to Microsoft Dynamics 365 because a mailbox is unavailable at the time.</li>
 	<li>When previously linked items are found for a specific mailbox.</li>
</ul>
<p>You’ll be prompted to take actions on the errors about the appointment, contacts, and tasks synchronization.</p>
</td>
</tr>
<tr>
<td>View alerts specific to mailbox</td>
<td>
<ol>
 	<li>Go to <strong>Settings</strong> &gt; <strong>Email Configuration</strong>.</li>
 	<li>Click <strong>Mailboxes</strong>.</li>
 	<li>Open a mailbox record, and on the left navigation bar, under <strong>Common</strong>, click or tap <strong>Alerts</strong>.</li>
</ol>
</td>
</tr>
<tr>
<td>View alerts specific to an email server profile</td>
<td>
<ol>
 	<li>Go to <strong>Settings</strong> &gt; <strong>Email Configuration</strong>.</li>
 	<li>Click <strong>Email Server Profiles</strong>.</li>
 	<li>Open an email server profile record, and on the left navigation bar, under <strong>Common</strong>, click or tap <strong>Alerts</strong>.</li>
</ol>
</td>
</tr>
</tbody>
</table>
&nbsp;
<p>Now I believe you would have got an idea on what is going wrong and once you decide to uncheck the Check Boxes for Warnings and Information those data would not be captured thereafter. However, you still need to clean the database with these unwanted data, isn’t it? So, you could use the Bulk Delete Job to clean the data like this.</p>

<ul>
 	<li>Login to Dynamics CRM Application as an administrator and then navigate to Settings--&gt;Data Management</li>
</ul>
<a href="https://msdnshared.blob.core.windows.net/media/2017/10/Data-Management.jpg"><img width="239" height="97" class="alignnone wp-image-246 " alt="" src="https://msdnshared.blob.core.windows.net/media/2017/10/Data-Management-300x122.jpg" /></a>
<ul>
 	<li>Then click on Bulk Record Deletion</li>
</ul>
<a href="https://msdnshared.blob.core.windows.net/media/2017/10/Bulk-Delete.jpg"><img width="173" height="44" class="alignnone wp-image-255 " alt="" src="https://msdnshared.blob.core.windows.net/media/2017/10/Bulk-Delete-300x76.jpg" /></a>

&nbsp;
<ul>
 	<li>Click on New--&gt;Click on Next.</li>
 	<li>In ‘Look For’, select Traces</li>
</ul>
<a href="https://msdnshared.blob.core.windows.net/media/2017/10/Traces.jpg"></a><a href="https://msdnshared.blob.core.windows.net/media/2017/10/Traces.jpg"><img width="300" height="227" class="alignnone wp-image-267 size-medium" alt="" src="https://msdnshared.blob.core.windows.net/media/2017/10/Traces-300x227.jpg" /></a>
<ul>
 	<li>Select Level and then make sure to select set it Equals to Information and Warning</li>
</ul>
<a href="https://msdnshared.blob.core.windows.net/media/2017/10/Levels.jpg"><img width="300" height="224" class="alignnone wp-image-266 size-medium" alt="" src="https://msdnshared.blob.core.windows.net/media/2017/10/Levels-300x224.jpg" /></a>
<ul>
 	<li>Click on Ok</li>
</ul>
&nbsp;

<a href="https://msdnshared.blob.core.windows.net/media/2017/10/Filter.png"><img width="285" height="220" class="alignnone wp-image-276 " alt="" src="https://msdnshared.blob.core.windows.net/media/2017/10/Filter-300x232.png" /></a>
<p>Then select the Regarding Object Type (In my example, I was dealing with a lot of data in regards to the Email Server Profile and Mailboxes).</p>
<p>Give this view a name and save it for future usage. If you wish you could also remove or add a few columns to select your data precisely.</p>
<strong>Note: please make sure to start this job during off peak hours and schedule it to run during off peak hours only if the data set is huge. You can start and stop the job manually or schedule it too.</strong>

<strong>Also, you should always take the backup of the ORG_MSCRM database before making any changes.</strong>

<strong>In this case while working with my customer, cleaning up their database we could around delete 2 billion records, which was almost 80-90% of the total volume of data in the TraceLogBase table. However, you might encounter a problem that while deleting these many records you might would like to add more filters so that you don’t get any SQL Timeouts.</strong>

<strong>However, if you still can’t overcome the SQL Timeout errors with this then please work with Microsoft Support Team on this for further assistance.</strong>
<p>Hope this helps and please do share your comments or feedbacks.</p>]]></content:encoded>
    </item>
    <item>
      <title>Dynamics 365 and SharePoint Integration important aspects</title>
      <link>https://docs.microsoft.com/archive/blogs/ritesh_ranjan/dynamics-crm-365-and-sharepoint-integration-important-aspects</link>
      <pubDate>Wed, 09 Nov 2016 12:25:18 GMT</pubDate>
      <dc:creator><![CDATA[Ritesh Ranjan - Technical Advisor]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/ritesh_ranjan/?p=185</guid>
      <description><![CDATA[1.        Introduced with Microsoft Dynamics CRM Online 2015 Update 1, server-based Microsoft...]]></description>
      <content:encoded><![CDATA[<span><span style="color: #000000;font-family: Candara">1.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">        </span></span></span><span lang="EN"><span style="color: #000000;font-family: Candara">Introduced with Microsoft Dynamics CRM Online 2015 Update 1, server-based Microsoft SharePoint integration for document management can now be used to connect Microsoft Dynamics 365 (online) with SharePoint on-premises.</span></span>

<span><span style="color: #000000;font-family: Candara">2.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">       </span></span></span><span style="color: #000000;font-family: Candara">You can store and manage documents in the context of a Dynamics 365 record on a SharePoint Server, and leverage the SharePoint infrastructure to share, manage, and collaborate efficiently.</span>

<span><span style="color: #000000;font-family: Candara">3.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">       </span></span></span><span style="color: #000000;font-family: Candara">As the documents are stored on a SharePoint Server, non-Microsoft Dynamics 365 users can directly access the documents on the SharePoint Server, provided they have the appropriate permissions.</span>

<span><span style="color: #000000;font-family: Candara">4.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">       </span></span></span><span lang="EN"><span style="color: #000000;font-family: Candara">SharePoint integration for Dynamics 365 can only be enabled using the web or Microsoft Dynamics 365 for Outlook. This isn’t supported through SDK.</span></span>

<span><span style="color: #000000;font-family: Candara">5.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">       </span></span></span><span style="color: #000000;font-family: Candara">You can have both, a complete online as well as hybrid integration solution between Dynamics 365 and SharePoint.</span>

<span><span style="color: #000000;font-family: Candara">6.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">      </span></span></span><span style="color: #000000;font-family: Candara">Microsoft Dynamics 365 supports two types of integration with SharePoint: client-to-server and server-to-server (server-based).</span>

<span><span style="color: #000000;font-family: Candara">7.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">       </span></span></span><span style="color: #000000;font-family: Candara">You either enable server-based SharePoint integration (recommended) or install the Microsoft Dynamics CRM List Component, a SharePoint solution, on a site collection in SharePoint. </span><span lang="EN"><span style="color: #000000;font-family: Candara">Although the Microsoft Dynamics CRM List Component is the default document management configuration option, we recommend you enable server-based SharePoint integration.</span></span>

<span><span style="color: #000000;font-family: Candara">8.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">      </span></span></span><span style="color: #000000;font-family: Candara">If you are using server-based integration with SharePoint, you can use Microsoft SharePoint Online or Microsoft SharePoint 2013 SP1 on-premises (or a later version).</span>

<span><span style="color: #000000;font-family: Candara">9.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">      </span></span></span><span style="color: #000000;font-family: Candara">Benefits of server-based SharePoint integration:</span>

<span><span style="color: #000000;font-family: Candara">         a.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">       </span></span></span><span style="color: #000000;font-family: Candara">Users sign-in once and do not have to sign-in to both Microsoft Dynamics 365 and SharePoint.</span>

<span><span style="color: #000000;font-family: Candara">         b.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">      </span></span></span><span style="color: #000000;font-family: Candara">The list component is a SharePoint sandboxed solution. Sandboxed solutions are being deprecated and will no longer be available for both Microsoft SharePoint Online and later versions of SharePoint on-premises.</span>

<span><span style="color: #000000;font-family: Candara">         c.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">       </span></span></span><span lang="EN"><span style="color: #000000;font-family: Candara">Users can perform SharePoint actions from the Dynamics 365 command bar.</span></span>

<span><span style="color: #000000;font-family: Candara">10.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">    </span></span></span><span lang="EN"><span style="color: #000000;font-family: Candara">If you are using the Microsoft Dynamics CRM 2016 List Component for Microsoft SharePoint, one of the following versions of Microsoft SharePoint must be available:</span></span>

<span><span style="color: #000000;font-family: Candara">         a.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">       </span></span></span><span style="color: #000000;font-family: Candara">Microsoft SharePoint 2013 or Microsoft SharePoint 2013 SP1</span>

<span><span style="color: #000000;font-family: Candara">         b.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">      </span></span></span><span style="color: #000000;font-family: Candara">Microsoft SharePoint 2010 SP1 or SP2</span>

<span><span style="color: #000000;font-family: Candara">         c.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">       </span></span></span><span style="color: #000000;font-family: Candara">Microsoft SharePoint Online</span>

<span><span style="color: #000000;font-family: Candara">11.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">     </span></span></span><span style="color: #000000;font-family: Candara">A SharePoint site collection must be available and </span><span lang="EN"><span style="color: #000000;font-family: Candara">configured for Microsoft Dynamics 365</span></span>

<span><span style="color: #000000;font-family: Candara">12.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">     </span></span></span><span style="color: #000000;font-family: Candara">The document management feature requires that Microsoft Dynamics 365 (online) and SharePoint Online subscriptions be under the same tenant, in case you are going for a complete online solution.</span>

<span><span style="color: #000000;font-family: Candara">13.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">    </span></span></span><span style="color: #000000;font-family: Candara">SharePoint Foundation versions aren’t supported for use with Microsoft Dynamics 365 document management.</span>

<span><span style="color: #000000;font-family: Candara">14.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">    </span></span></span><span style="color: #000000;font-family: Candara">About Dynamics 365 list component for Microsoft SharePoint Server:</span>

<span><span style="color: #000000;font-family: Candara">          a.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">       </span></span></span><span style="color: #000000;font-family: Candara">View documents that are stored on the SharePoint Server 2010 server in a Microsoft Dynamics 365 List view (look and feel of Dynamics 365).</span>

<span><span style="color: #000000;font-family: Candara">         b.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">      </span></span></span><span style="color: #000000;font-family: Candara">Automatic creation of the document locations on the SharePoint Server server.</span>

<span><span style="color: #000000;font-family: Candara">         c.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">       </span></span></span><span lang="EN"><span style="color: #000000;font-family: Candara">Users can create and view folders when using document management within Microsoft Dynamics 365.</span></span>

<span><span style="color: #000000;font-family: Candara">         d.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">      </span></span></span><span style="color: #000000;font-family: Candara">Users can create custom content types such as a Sales Contract content type.</span>

<span><span style="color: #000000;font-family: Candara">         e.</span><span style="font: 7pt 'Times New Roman';margin: 0px"><span style="color: #000000">       </span></span></span><span style="color: #000000;font-family: Candara">You can create and view folders when using the Microsoft Dynamics CRM List Component. This is not available in server-based SharePoint integration.</span>

<span lang="EN"><span style="color: #000000;font-family: Candara">For information about how to enable server-based SharePoint integration, see </span></span><a href="https://technet.microsoft.com/en-us/library/dn531154.aspx"><span lang="EN"><span style="color: #0000ff;font-family: Candara">Set up SharePoint integration with Microsoft Dynamics 365</span></span></a><span lang="EN"><span style="color: #000000;font-family: Candara">.</span></span>

<span lang="EN"><span style="color: #000000;font-family: Candara">For more information about the Microsoft Dynamics CRM List Component, see </span></span><a href="https://technet.microsoft.com/en-us/library/hh699758.aspx#BKMK_listComp"><span lang="EN"><span style="color: #0000ff;font-family: Candara">Microsoft Dynamics CRM List Component for Microsoft SharePoint</span></span></a><span lang="EN"><span style="color: #000000;font-family: Candara">.</span></span>

<span style="color: #000000;font-family: Candara">Hope this helps in getting up to a speed on Dynamics 365 and SharePoint integration. For more information on Integration please refer the </span><a href="https://msdn.microsoft.com/en-us/library/gg334768.aspx"><span style="color: #0000ff;font-family: Candara">MSDN article</span></a><span style="color: #000000;font-family: Candara">.</span>]]></content:encoded>
    </item>
    <item>
      <title>Dynamics CRM 2016 Upgrade - Complete Guide</title>
      <link>https://docs.microsoft.com/archive/blogs/ritesh_ranjan/dynamics-crm-2016-upgrade-complete-guide</link>
      <pubDate>Wed, 26 Oct 2016 08:36:07 GMT</pubDate>
      <dc:creator><![CDATA[Ritesh Ranjan - Technical Advisor]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/ritesh_ranjan/?p=175</guid>
      <description><![CDATA[This blog post talks about the possible upgrade paths and provide guidance, which could be followed...]]></description>
      <content:encoded><![CDATA[<span style="line-height: 110%;font-family: 'Candara',sans-serif;font-size: 11pt"><span style="color: #262626">This blog post talks about the possible upgrade paths and provide guidance, which could be followed in order to a successful upgrade to the Dynamics CRM 2016 Sp1. As the only supported upgrade path to Microsoft Dynamics CRM Server 2016 is from Microsoft Dynamics CRM Server 2015, hence this blog post talks about an upgrade from Dynamics CRM 2015. If you have any previous versions of the Dynamics CRM installed then I would suggest upgrading to the Dynamics CRM 2015 first. For more information on upgrade from previous versions of Dynamics CRM, you could refer this: https://technet.microsoft.com/en-us/library/hh699673.aspx . I have tried to </span></span><span style="line-height: 110%;font-family: 'Candara',sans-serif;font-size: 11pt"><span style="color: #262626">covers some basic guidelines on Dynamics CRM Upgrade which could be useful to you.</span></span>

<span style="line-height: 110%;font-family: 'Candara',sans-serif;font-size: 11pt"><span style="color: #262626">The only supported upgrade path to Microsoft Dynamics CRM Server 2016 is from Microsoft Dynamics CRM Server 2015. Microsoft Dynamics CRM 2015 server roles are not compatible with a Microsoft Dynamics CRM Server 2016 deployment. Therefore, after you upgrade the first Microsoft Dynamics CRM Server, other Microsoft Dynamics CRM 2015 servers that are running in the deployment will become disabled. As each server is upgraded, the corresponding server will be enabled.</span></span>

<span style="line-height: 110%;font-family: 'Candara',sans-serif;font-size: 11pt"><span style="color: #262626">You can upgrade Microsoft Dynamics CRM 2015 server roles in any order. However, to have a fully functioning Microsoft Dynamics CRM 2016 deployment, all servers and server roles must be upgraded.</span></span>

<strong>Recommended upgrade steps:</strong>

To ease the upgrade process and minimize downtime, it is recommend that you use the following order when you upgrade Microsoft Dynamics CRM Server.
<ul>
 	<li>Although you can upgrade any version of Dynamics CRM 2015 for Outlook to Microsoft Dynamics CRM 2016 for Outlook, we recommend that you apply the latest update rollup before you begin the upgrade. Microsoft Dynamics CRM 2015 updates and hotfixes</li>
 	<li>Upgrade all Microsoft Dynamics CRM 2015 servers and organizations to Microsoft Dynamics CRM Server 2016.</li>
 	<li>Upgrade Dynamics CRM for Outlook to Microsoft Dynamics CRM 2016 for Outlook to have the Go offline capability.</li>
</ul>
<strong>Microsoft Dynamics CRM Server upgrade options:</strong>

There are three different upgrade options:
<ul>
<ul>
 	<li>Migrate by using a new instance of SQL Server. We recommend this option for upgrading Microsoft Dynamics CRM Server. Although this option requires a different computer for Microsoft Dynamics CRM 2016 and a different instance of SQL Server, it provides the least amount of potential downtime for users since the existing deployment can remain functioning until the upgrade is completed and verified.</li>
 	<li>Migrate by using the same instance of SQL Server. This option requires a different computer for Microsoft Dynamics CRM Server 2016, but will upgrade in-place the configuration and default organization databases using the same instance of SQL Server. If issues occur during the upgrade, you must roll back to the previous Microsoft Dynamics CRM version to avoid significant downtime.</li>
 	<li>In-place upgrade. Although this option doesn’t require a different computer for Microsoft Dynamics CRM Server 2016 or a different instance of SQL Server, it poses the greatest risk if upgrade issues occur because a roll back and reinstall of the previous version of Microsoft Dynamics CRM will be required to avoid potential downtime.</li>
</ul>
</ul>
You could also refer: <a href="https://technet.microsoft.com/en-us/library/hh699669.aspx">https://technet.microsoft.com/en-us/library/hh699669.aspx</a> for detailed information on Upgrade Microsoft Dynamics CRM Server.

In this example I am talking about an In-Place upgrade. There were 4 CRM Servers on a virtual environment (2 Frontend and 2 Backend), hence decided to take the snapshot of the all the servers before making any changes and then proceed with an In-Place upgrade.

<strong>Important:</strong>
<ul>
 	<li><strong>Always run a full backup of the Microsoft Dynamics CRM databases before you upgrade to a new version of the product.</strong> For information about database backups, see <a href="https://technet.microsoft.com/en-us/library/hh699676.aspx">Back up the Microsoft Dynamics CRM System</a>.</li>
 	<li><strong>During an in-place upgrade, only the organization that you specify to upgrade is upgraded.</strong> If the deployment contains additional organizations, those organizations are disabled and are not upgraded. You must upgrade those organizations using the Import-CrmOrganization Windows PowerShell command or by using Deployment Manager. More information: CRM 2016 PowerShell Reference and Import an organization</li>
</ul>
<strong>For each organization that you upgrade, we recommend that the volume have free space that is at least three times the size of the organization database file (organizationName_MSCRM.mdf) and four times the size of the log file (organizationName_MSCRM.ldf).</strong> For example, if a single organization database and log file are located on the same volume where the mdf file is 326 MB and the ldf file is 56 MB, the recommended available space should be at least 1.2 GB to allow for growth ((326 x 3) + (56 x 4)). Notice that the database files that expand during upgrade do not reduce in size after the upgrade is complete.

<strong>Tasks to perform before the upgrade:</strong>
<ul>
 	<li>We recommend that you apply the latest <a href="https://support2.microsoft.com/kb/2917899">Microsoft Dynamics CRM updates</a> before you start the upgrade.</li>
 	<li>Meet all requirements as specified under <a href="https://technet.microsoft.com/en-us/library/hh699840.aspx">Microsoft Dynamics CRM Server hardware requirements</a> and <a href="https://technet.microsoft.com/en-us/library/hh699671.aspx">Software requirements for Microsoft Dynamics CRM Server</a>.</li>
 	<li>Log on to your domain as a user who has administrator-level permission.</li>
 	<li>SQL Server replication isn’t supported with Microsoft Dynamics CRM. If you run SQL Server replication, disable it.</li>
 	<li>Uninstall Microsoft Dynamics CRM Connector for SQL Server Reporting Services if it’s installed on the same computer where Microsoft Dynamics CRM Server is installed. More information: <a href="https://technet.microsoft.com/en-us/library/hh699833.aspx">Uninstall or repair Microsoft Dynamics CRM Reporting Extensions</a></li>
</ul>
To determine the location of the Microsoft Dynamics CRM installation files, see the <a href="https://go.microsoft.com/fwlink/p/?LinkID=624465">Microsoft Dynamics CRM 2016 and Microsoft Dynamics CRM Online Readme</a>.

<strong>Tips for a successful upgrade:</strong>

The following issues, if applicable to your current Microsoft Dynamics CRM 2015 deployment, should be resolved before you start the upgrade.

<strong>Do not exceed the maximum number of fields</strong>

If you have more than 1023 fields defined for an entity, you must delete the additional fields before you run the upgrade, or the upgrade will fail with the following message:

<em>CREATE VIEW failed because column 'column_name' in view 'view_name' exceeds the maximum of 1024 columns.</em>

<strong>Remove custom database objects</strong>

The Microsoft Dynamics CRM databases often change from one major release to the next because of database redesign.

We suggest that, if you have added custom database objects such as triggers, statistics, stored procedures, and certain indexes, you remove those objects from the configuration and organization databases. In many cases, Microsoft Dynamics CRM Server Setup displays a warning when these objects are detected.

<strong>Remove the Ignorechecks registry subkey</strong>

If you have manually added the ignorechecks registry subkey on the Microsoft Dynamics CRM server, remove it before you start the upgrade. More information: <a href="https://support.microsoft.com/kb/974584">You cannot deploy Microsoft Dynamics CRM by using an account that does not have local administrator permissions on Microsoft SQL Server</a>

<strong>Run the upgrade</strong>
<ol>
 	<li>In the folder where the Microsoft Dynamics CRM files are located, go to the Server\amd64 folder, and then double-click SetupServer.exe.</li>
 	<li>On the Welcome to Microsoft Dynamics CRM Server Setup page, we recommend that you select Get updates for Microsoft Dynamics CRM to make sure that Setup has the most recent installation files. Click Next. After Setup is done checking for updates, click Next again.</li>
 	<li><strong>Note</strong>: For the Get updates for Microsoft Dynamics CRM functionality to work you must, have an Internet connection on the computer where Setup is running. Enable Microsoft Update for “other Microsoft products” on the Windows Server computer where Microsoft Dynamics CRM Server Setup is running.</li>
 	<li>On the Product Key Information page, type your product key in the Product key boxes, and then click Next.</li>
 	<li>On the License Agreement page, review the information and if you accept the license agreement, click I accept this license agreement, and then click I Accept.</li>
 	<li>If Setup detects that components are missing, the Install Required Components page appears.
<ul>
 	<li>If you have already installed the required components, this page won’t appear.</li>
 	<li>If you haven’t installed the required components listed, you can install them now. Click Install. When the components are installed, the status column changes from Not Installed to Installed, and you can click Next to continue.</li>
 	<li><strong>Note</strong>: If you’re prompted to restart the computer, do so, and then start Setup again.</li>
</ul>
</li>
 	<li>On the Upgrade to Microsoft Dynamics CRM 2016 page, you can select an organization to upgrade or leave the choice &lt;None&gt; so that no organizations will be upgraded during Setup. Before you select an organization, consider the following:
<ul>
 	<li>Notice that any organization not upgraded will become disabled after the upgrade is complete. To upgrade organizations after Setup is complete, use the Import-CrmOrganization Windows PowerShell command. Alternatively, you can use Deployment Manager.</li>
</ul>
</li>
 	<li>On the Specify Service Accounts page, Setup will add the service accounts used for the Microsoft Dynamics CRM Server services. You can use the existing service accounts or specify new ones. For information about the permissions required to run these services see Minimum permissions required for Microsoft Dynamics CRM Setup and services.</li>
 	<li>If you want to use server-side synchronization and/or Dynamics CRM for Outlook for the deployment, leave this box blank. More information: Integrate your email system with Microsoft Dynamics CRM</li>
 	<li>Otherwise, on the Specify E-mail Router Settings in the, Email router server name box, type the name of the computer where the Email Router will be installed. This computer will route Microsoft Dynamics CRM email messages. If you leave the box blank but decide later you want to use the Email Router, you must add the computer where the Email Router Service is running (part of the Asynchronous Service) when you use Network Service, or if you use a domain user account, the account to the PrivUserGroup security group.</li>
 	<li>Click Next.</li>
 	<li>On the Select Microsoft Update Preference page, select whether you want to use Microsoft Update for checking for updates for your Microsoft products, and click Next. We recommend that you use Microsoft Update to check for updates because this helps keep your computer up-to-date and secure. For more information about the legal terms and privacy with Microsoft Update licensing, see Windows Update FAQ.</li>
 	<li>The System Checks page appears. This page is a summary of all requirements and recommendations for a successful installation. Errors must be resolved before installation can continue. If no errors, or only warnings appear, you can continue with the installation. To do this, click Next.</li>
 	<li>The Service Disruption Warning page appears. This page lists all services that will be stopped or restarted during Setup. Verify the suitability of the services that will be stopped or restarted, and then click Next.</li>
 	<li>Review the Ready to Upgrade the Application page, and click Back to correct any errors. When you are ready to continue, click Upgrade.</li>
 	<li>When Setup completes successfully, the Microsoft Dynamics CRM Server Setup completed page appears. If the Reporting Server instance that you specified during this Setup points to the local computer where Microsoft Dynamics CRM is installed, Setup provides an option to invoke Microsoft Dynamics CRM Reporting Extensions Setup.</li>
 	<li>For a full server deployment running on the Microsoft SQL Server Reporting Services computer, select the Launch Microsoft Dynamics CRM Reporting Extensions Setup check box to install Microsoft Dynamics CRM Reporting Extensions. Click Finish.</li>
</ol>
<strong>Important:</strong>
<ul>
 	<li>After you upgrade, you must install the Microsoft Dynamics CRM Reporting Extensions to create, run, and schedule reports in Microsoft Dynamics CRM. For instructions, see Install Microsoft Dynamics CRM Reporting Extensions in this guide.</li>
 	<li>You can’t install the Microsoft Dynamics CRM Reporting Extensions before you install or upgrade Microsoft Dynamics CRM Server.</li>
 	<li>If you had Language Packs provisioned in your deployment, to continue to use multiple languages, upgrade each language pack to Microsoft Dynamics CRM 2016, and then provision them. More information: Upgrade and enable a Language Pack</li>
 	<li>Notice that Setup turns on HTTP compression on the server that’s running IIS where the web application is installed. If you use another method to compress HTTP communications, you may want to turn this feature off after Setup completes. To do this, start Internet Information Services (IIS) Manager, choose the website, double-click Compression, and then clear the compression check boxes.</li>
</ul>
<strong>Post-upgrade steps for servers</strong>
<ol>
 	<li>If you have additional network load balanced servers or Microsoft Dynamics CRM server roles installed on other computers, upgrade or uninstall and reinstall Microsoft Dynamics CRM on those servers as described in <a href="https://technet.microsoft.com/en-us/library/jj612874.aspx">Install Microsoft Dynamics CRM Front End Server and Back End Server roles</a>.</li>
 	<li>Install the Microsoft Dynamics CRM Reporting Extensions. You must install Microsoft Dynamics CRM Reporting Extensions before you can import and upgrade organizations not upgraded during Microsoft Dynamics CRM Server Setup.</li>
 	<li>If you had Language Packs provisioned in the deployment, download and install Microsoft Dynamics CRM 2016 Language Packs for the languages that you want. More information: <a href="https://technet.microsoft.com/en-us/library/hh699733.aspx">Upgrade and enable a Language Pack</a></li>
 	<li>Install the latest update rollup packages/service packs.</li>
 	<li>If needed, import organizations. During import, each organization will be upgraded. To do this, use the Import-CrmOrganization Windows PowerShell command. Alternatively, you can use Microsoft Dynamics CRM Deployment Manager.</li>
 	<li>In Microsoft SQL Server Reporting Services Report Manager, re-create any custom data sources under the <em>OrganizationName</em>_MSCRM folders.</li>
 	<li>Some organization data is encrypted using encryption keys. These keys should be copied as part of your failure recovery procedures. More information: <a href="https://technet.microsoft.com/en-us/library/dn531199.aspx">Data encryption</a></li>
 	<li>Verify that the system jobs and workflows are running.</li>
</ol>
Although not required, we recommend that you register Microsoft Dynamics CRM.

Thank you!!

Please do share your feedback and let me know if you want me to write on any other topics you encounter often and need some more information.]]></content:encoded>
    </item>
    <item>
      <title>Activity Feeds in Dynamics CRM: Best practices</title>
      <link>https://docs.microsoft.com/archive/blogs/ritesh_ranjan/activity-feeds-in-dynamics-crm-best-practices</link>
      <pubDate>Tue, 07 Jun 2016 09:32:52 GMT</pubDate>
      <dc:creator><![CDATA[Ritesh Ranjan - Technical Advisor]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/ritesh_ranjan/?p=145</guid>
      <description><![CDATA[Hello everyone,

In this post, I am going to talk about the importance of Activity Feeds in...]]></description>
      <content:encoded><![CDATA[Hello everyone,

In this post, I am going to talk about the importance of <strong>Activity Feeds</strong> in Dynamics CRM which was introduced with Dynamics CRM 2011. In my current role, I visit customers who use Dynamics CRM and review their application/architecture, provide proactive guidance towards the overall betterment of the application/architecture and advise them on the optimal usage. During the last few visits, I endeavored to get an understanding from my customers if they really know what <strong>Activity Feeds</strong> are and if they actually need this feature?

Those who are not very familiar with the feature, let me share a quick overview:

<strong>Activity Feeds</strong> monitor real-time updates to help you stay up-to-date with the fast-moving sales, customer projects, and marketing campaigns of your organization, which also includes automatic updates on the activities of your colleagues. You can also choose to “follow” updates of the contacts, colleagues, and customer records you care the most about. In fact, you could achieve a lot of things with this to help you keep track of things within the application you care most about.

For more information, please refer: <a href="https://www.microsoft.com/en-us/dynamics/crm-customer-center/stay-up-to-date-with-customer-news-with-the-activity-feed.aspx">https://www.microsoft.com/en-us/dynamics/crm-customer-center/stay-up-to-date-with-customer-news-with-the-activity-feed.aspx</a>

Besides, this could also help in increasing the overall size of the CRM database every time an event happens. For example, if there is an update on any of your customers/contacts, it has to update certain tables in the database too, i.e. PostBase, PostCommentBase…. In my recent customer engagement, I had to cleanup around 50 GB of data which was quite significant based on the overall size of the database. And, this motivated me to share this experience with the wide audience through my blog.

In order to do the cleanup, steps are very easy:
<ol>
	<li>Check with the business and try to understand the actual need of the feature. Do they really need this?</li>
	<li>There could be a possibility that they only need the Activity rules to be activated on a very few entities or they just don’t need them.</li>
	<li>Now when you have a better understanding, you can follow the following quick steps:</li>
</ol>
&nbsp;
<ol>
<ol>
	<li>Login as a Dynamics CRM System Administrator to the Application.</li>
	<li>Navigate to Settings--&gt;Activity Feeds Configuration.</li>
	<li>Select the configurations which you don’t need. (Please keep in mind that there are few configurations which are there by default and are active). Or, deactivate all the configurations if you don’t need them.</li>
	<li>Once that is done, do remember to Publish the customizations for the changes done, which could be done by clicking on <strong>More Commands …. </strong>and then<strong> Publish Customizations. </strong>Until you Publish the customizations, the changes won’t take effect.</li>
	<li>Now when you are sure that there are no more new entries being created (only in the case when you decide to deactivate all the configurations and rules, it’s time to clean the database, for which you can use the <strong>Bulk Delete</strong> feature to create a rule which would delete all the Posts (it is always a good practice to take the latest backup of the database and then do the cleanup because if at any point in time you would like to refer the data, you would have the backup to fall back on).</li>
</ol>
</ol>
<strong>Note</strong>: I tested these steps with Dynamics CRM 2013 as I was working on the mentioned scenario at a customer site. However, I am sure that it would work the same way in DYCRM 2011 and the later versions. This cleanup could also be very useful when you plan for an upgrade or migration.

Thank you for stopping by. If you have any feedbacks or questions, please do leave your comments below. I shall be happy to answer them.]]></content:encoded>
    </item>
    <item>
      <title>PrincipalObjectAccess with InheritedAccessRightsMask value 135069719 &amp; AccessRightMask value 0</title>
      <link>https://docs.microsoft.com/archive/blogs/ritesh_ranjan/principalobjectaccess-with-inheritedaccessrightsmask-value-135069719-accessrightmask-value-0</link>
      <pubDate>Sat, 14 Feb 2015 09:36:21 GMT</pubDate>
      <dc:creator><![CDATA[Ritesh Ranjan - Technical Advisor]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/ritesh_ranjan/2015/02/14/principalobjectaccess-with-inheritedaccessrightsmask-value-135069719-accessrightmask-value-0/</guid>
      <description><![CDATA[&#160;  I would say last week as CRM database cleanup week, where I was working on cleaning up the...]]></description>
      <content:encoded><![CDATA[<p>&#160;</p>  <p><font size="3" face="Candara">I would say last week as CRM database cleanup week, where I was working on cleaning up the PrincipalObjectAccess with one of my customers. </font></p>  <p><font size="3" face="Candara">Moving ahead after cleaning up the WorkFlowLog entries from POA table which were created due to Dialogs (please refer my previous article for more information on that: </font><a href="https://blogs.msdn.com/b/ritesh_ranjan/archive/2015/02/09/another-experience-with-cleaning-up-the-principalobjectaccess-table-dialogs.aspx"><font size="3" face="Candara">https://blogs.msdn.com/b/ritesh_ranjan/archive/2015/02/09/another-experience-with-cleaning-up-the-principalobjectaccess-table-dialogs.aspx</font></a><font size="3" face="Candara"> ), now I am looking at cleaning up the POA table for the records which are with the value <b>135069719</b> for <strong>InheritedAccessRightsMask</strong> column and value <strong>0 </strong>for <strong>AccessRightsMask</strong>. Don’t be mistaken, it should be the value <b>135069719</b> and <strong>0</strong>&#160; for the same record under associated mentioned columns. </font></p>  <p><font size="3" face="Candara">Let me explain it further for your better understanding of the scenario:</font></p>  <p><font size="3" face="Candara">On a daily basis we were noticing hundred thousands of records in the POA table for the ActivityPointer, SalesOrder, Anotation and lots of other entities. After drilling down further on what is making these entries in the table we found that all of these entries were based on the Reparent attribute set to Cascade All. As Jon clearly mentioned in his blog (</font><a href="https://blogs.msdn.com/b/crminthefield/archive/2010/08/16/excessive-principalobjectaccess-poa-table-growth-in-crm-4-0.aspx"><font size="3" face="Candara">https://blogs.msdn.com/b/crminthefield/archive/2010/08/16/excessive-principalobjectaccess-poa-table-growth-in-crm-4-0.aspx</font></a><font size="3" face="Candara">) that with this setting, sub records would be shared to the owner of the parent record. For example:&#160; Let’s say that User1 owns Account1.&#160; User2 has access to Account1 and creates a case underneath Account1.&#160; With the out of the box Reparent options, a record would be created in the POA table that would give User1 access to the newly created case.&#160; </font></p>  <p><font size="3" face="Candara">After my analysis I understood that these records will have a value (<b>135069719</b>) which decodes to all privileges except ‘Create’ under the column <b>InheritedAccessRightsMask</b>. In order to control the behavior first we really need to understand and explain the behavior, so that we could understand the pros &amp; cons of changing the sharing behavior from Cascade All to Cascade None, which will completely stop those entries into the POA table. For better understanding on this change you can refer Jon’s blog mentioned above. </font></p>  <p><font size="3" face="Candara">By now you would understand the reason behind these entries into the PrincipalObjectAccess table but at the same time you will have a question in mind, i.e. How to clean up existing data which is already created in POA because of cascade share all, right? </font></p>  <p><font face="Candara"><font size="3"><strong>Resolution</strong>: </font></font></p>  <p><font size="3" face="Candara">Try out with this simple test (In my case it was Account entity and Phone Call activity which was filling up POA table) </font></p>  <blockquote>   <p><font size="3" face="Candara">- Assign Account from User 1 to User 3</font></p> </blockquote>  <blockquote>   <p><font size="3" face="Candara">- Then assign Account from User 3 back to User 1</font></p> </blockquote>  <blockquote>   <p><font size="3" face="Candara">- Assign PhoneCall (which was under that account record) from User 2 to User 3</font></p> </blockquote>  <blockquote>   <p><font size="3" face="Candara">- Then assign PhoneCall from User 3 back to User 2</font></p> </blockquote>  <p><font size="3" face="Candara">This sets the value of <b>InheritedAccessRightsMask </b>to <b>0</b>, which means no privileges and this also marks the record to be deleted by the deletion service. Now this was good for testing with a single record but what if you have millions of Accounts and you need to do this ownership reassignment for all of them?&#160; </font></p>  <p><font size="3" face="Candara">The supported way is definitely to do it through SDK, creating a dummy user 3 and assign all the records to that user and then from that user3 assign it back to the user1 and user2. This could be done as a bulk operation using CRM SDK and this would help you clean the PrincipalObjectAccess table up to a great extent. In this case it reduced the table size by 80%, yes you read it right, 80%. </font></p>  <p><font size="3" face="Candara">Hope this helps.</font></p>  <p><font size="3" face="Candara">Stay tuned and happy reading!</font></p>]]></content:encoded>
    </item>
    <item>
      <title>Another experience with cleaning up the PrincipalObjectAccess table - Dialogs</title>
      <link>https://docs.microsoft.com/archive/blogs/ritesh_ranjan/another-experience-with-cleaning-up-the-principalobjectaccess-table-dialogs</link>
      <pubDate>Mon, 09 Feb 2015 10:22:17 GMT</pubDate>
      <dc:creator><![CDATA[Ritesh Ranjan - Technical Advisor]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/ritesh_ranjan/2015/02/09/another-experience-with-cleaning-up-the-principalobjectaccess-table-dialogs/</guid>
      <description><![CDATA[&nbsp;
&nbsp;
&nbsp;
Hey! I am back with yet another interesting yet intriguing situation....]]></description>
      <content:encoded><![CDATA[<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p><span style="font-family: Candara; font-size: small;">Hey! I am back with yet another interesting yet intriguing situation. Without further ado, let me straight away get to explaining the scenario for you all. Happy reading! </span></p>
<p><span style="font-family: Candara; font-size: small;">Today, I was working with one of my customers and got into cleaning up the PrincipalObjectAccess table cleanup. I started looking at some of the references like: </span><a href="https://support.microsoft.com/kb/2664150?wa=wsignin1.0"><span style="font-family: Candara; font-size: small;">https://support.microsoft.com/kb/2664150?wa=wsignin1.0</span></a><span style="font-family: Candara; font-size: small;"> , </span><a href="https://blogs.msdn.com/b/crminthefield/archive/2011/06/09/principalobjectaccess-performance-recommendations.aspx"><span style="font-family: Candara; font-size: small;">https://blogs.msdn.com/b/crminthefield/archive/2011/06/09/principalobjectaccess-performance-recommendations.aspx</span></a><span style="font-family: Candara; font-size: small;"> and </span><a href="https://blogs.msdn.com/b/crminthefield/archive/2010/08/16/excessive-principalobjectaccess-poa-table-growth-in-crm-4-0.aspx"><span style="font-family: Candara; font-size: small;">https://blogs.msdn.com/b/crminthefield/archive/2010/08/16/excessive-principalobjectaccess-poa-table-growth-in-crm-4-0.aspx</span></a><span style="font-family: Candara; font-size: small;"> .</span></p>
<p><span style="font-family: Candara; font-size: small;">These were the best resources I could find in my case to explain and talk about those entries in the POA table. However, I was looking for some action plan on actual possible cleanup of the records from the POA table. Hence, started looking at the number of counts of type of records in the POA table, this would give a good starting point to nail down what is causing the enormous growth of the POA table.</span></p>
<p><span style="font-family: Candara; font-size: small;">Query to find the number of records with the type in POA table:</span></p>
<blockquote>
<p><span style="color: #0000ff; font-family: Candara; font-size: x-small;">USE ORGANIZATION_MSCRM (replace it with your organization database name)</span></p>
<p><span style="color: #0000ff; font-family: Candara; font-size: x-small;">Select e.Name, COUNT(PrincipalObjectAccessId) as 'cnt'</span></p>
<p><span style="color: #0000ff; font-family: Candara; font-size: x-small;">From PrincipalObjectAccess poa with (nolock)</span></p>
<p><span style="color: #0000ff; font-family: Candara; font-size: x-small;">Join EntityLogicalView e with (nolock) on e.ObjectTypeCode=poa.ObjectTypeCode</span></p>
<p><span style="color: #0000ff; font-family: Candara; font-size: x-small;">Where poa.PrincipalTypeCode=8</span></p>
<p><span style="color: #0000ff; font-family: Candara; font-size: x-small;">Group by e.Name</span></p>
<p><span style="color: #0000ff; font-family: Candara; font-size: x-small;">Order by cnt desc</span></p>
<p><span style="color: #0000ff; font-family: Candara; font-size: x-small;">Go</span></p>
</blockquote>
<p><span style="font-family: Candara; font-size: small;">This certainly gave me the record count and that was in millions, as expected :).</span></p>
<p><span style="font-family: Candara; font-size: small;">Now, I had to plan for cleaning up possible records from the table. During the investigation, I also found that there were lots of entries in the AsynOperationBase table and WorkflowLogBase table marked with completed state. So I knew that in this environment AsyncOpeartionBase and WorkflowLogBase cleanup was never done, hence, had to do that too. So, I followed the KB article: </span><a href="https://support.microsoft.com/kb/968520"><span style="font-family: Candara; font-size: small;">https://support.microsoft.com/kb/968520</span></a><span style="font-family: Candara; font-size: small;"> which talks about cleaning up the AsyncOperationBase table which also removes entries from the POA table for the completed workflows.</span></p>
<p><span style="font-family: Candara; font-size: small;">Thankfully, cleanup was successful. But, surprisingly, even now, there were a lot of records for the WorkflowLog in the POA table . Now, I had to investigate and see what is causing these many entries into the POA table. </span></p>
<p><span style="font-family: Candara; font-size: small;">I found out that every execution of a Dialog (Process of category Dialog) creates a number of entries in the PrincipalObjectAccess table and the WorkflowLogBase table. The entries created in the PrincipalObjectAccess table have objecttypecode corresponding to WorkflowLog. The creation of these entries results in an excessive growth of the PrincipalObjectAccess table, which has a negative performance impact on the CRM overall. </span></p>
<p><span style="font-family: Candara; font-size: small;">By now it was clear that I had to focus on cleaning up entries for the Dialogs as well. Worked on this further with a couple of support engineers to confirm on the behavior and could understand that: </span></p>
<p><span style="font-family: Candara; font-size: small;">The creation of these POA entries is expected behavior, as all WorkflowLogBase items also create POA entries.&nbsp; When a dialog is executed, it is similar to a workflow and utilizes the WorkflowLogBase table. When a workflow is fired, it is executed in the AsyncOperationBase table, but entries are also created in WorkflowLogBase and POA.&nbsp; Dialogs work the same way, except that they are executed in the ProcessSessionBase table instead of AsyncOperationBase. </span></p>
<p><span style="font-family: Candara; font-size: small;">Hence, had an action plan to work on which was to cleanup up the POA table, for which, one of my colleagues Erik suggested to clean it up using Bulk Delete operation as following:</span></p>
<p><span style="font-family: Candara; font-size: small;">The Bulk Delete job you would create here is very similar to what you would do to proactively maintain the AsyncOperationBase table via Bulk Delete.&nbsp; Specific steps for Process Sessions are below:</span></p>
<blockquote>
<p><span style="font-family: Candara; font-size: small;">1. Go to Settings &gt; Data Management &gt; Bulk Record Deletion, and click New.</span></p>
</blockquote>
<blockquote>
<p><span style="font-family: Candara; font-size: small;">2. Click Next, then on the Define Search Criteria page set the Look for selection to Process Sessions (in CRM 2013 &amp; 2015, but in CRM 2011, it should be Dialog Sessions).</span></p>
</blockquote>
<blockquote>
<p><span style="font-family: Candara; font-size: small;">3. Define the criteria for you Bulk Delete.&nbsp; For example, you could use Status Reason = Completed; Canceled.</span></p>
</blockquote>
<blockquote>
<p><span style="font-family: Candara; font-size: small;">4. After defining your criteria, click Next to get to the Select Options page.</span></p>
</blockquote>
<blockquote>
<p><span style="font-family: Candara; font-size: small;">5. Provide a name, start time, and recurrence pattern, and then click Next.</span></p>
</blockquote>
<blockquote>
<p><span style="font-family: Candara; font-size: small;">6. Click Submit.</span></p>
</blockquote>
<p><span style="font-family: Candara; font-size: small;">If you already have a bulk delete job for Async Operations, or for anything else, ensure that you do not schedule the jobs to run at the exact same time.&nbsp; For example, if you already have a Bulk Delete job that runs nightly, weekly, etc. at midnight; do not also schedule this one to run at midnight.&nbsp; Specify a different time such as 1:00 am instead.</span></p>
<p><span style="font-family: Candara; font-size: small;">And, finally, this helped a lot in reducing the size of the POA table. It was also a very good learning:</span></p>
<p><span style="font-family: Candara; font-size: small;">Dialogs which are a kind of workflows not running under Async do not hold any entry into the AsyncOperationBase but hold an entry into the WorkFlowLogBase table. However, it was understood that Dialogs work the same way, except that they are executed in the ProcessSessionBase table instead of AsyncOperationBase. And, it also holds entries into the POA table for the associated entries. </span></p>
<p><span style="font-family: Candara; font-size: small;">You can try using the above mentioned steps in your environment but with proper testing and understanding of the issue/scenario. This is completely based on a specific scenario and needs to be verified against the scenario you are analyzing.</span></p>
<p><span style="font-family: Candara; font-size: small;">Hope this helps.</span></p>]]></content:encoded>
    </item>
    <item>
      <title>Network Load Balancer Compression with Dynamics CRM 2013</title>
      <link>https://docs.microsoft.com/archive/blogs/ritesh_ranjan/network-load-balancer-compression-with-dynamics-crm-2013</link>
      <pubDate>Mon, 22 Sep 2014 08:33:40 GMT</pubDate>
      <dc:creator><![CDATA[Ritesh Ranjan - Technical Advisor]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/ritesh_ranjan/2014/09/22/network-load-balancer-compression-with-dynamics-crm-2013/</guid>
      <description><![CDATA[Today, I am writing to share my experience with a hardware network load balancer and Dynamics CRM...]]></description>
      <content:encoded><![CDATA[<p>Today, I am writing to share my experience with a hardware network load balancer and Dynamics CRM 2013. In this case, I am talking about LoadMaster LM-3600 Load Balancer (<a title="https://kemptechnologies.com/en/server-load-balancing-appliances/loadmaster-3600/overview/" href="https://kemptechnologies.com/en/server-load-balancing-appliances/loadmaster-3600/overview/">https://kemptechnologies.com/en/server-load-balancing-appliances/loadmaster-3600/overview/</a>).</p>  <p>I was investigating an issue where a form load in Dynamics CRM 2013 was taking longer than expected resulting in bad user experience. I knew that the environment was highly customized with lots of jscripts, plug-ins, synchronous workflows and everything we could think of. I started monitoring HTTP traffic using IE Developer tools (F12) and Fiddler and I observed the following details in terms of actual performance with the form load:</p>  <blockquote>   <p><a href="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Blogs.Components.WeblogFiles/00/00/01/54/68/metablogapi/2047.image_637B9103.png" original-url="https://blogs.msdn.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-01-54-68-metablogapi/2047.image_5F00_637B9103.png"><img title="image" style="border-top: 0px; border-right: 0px; border-bottom: 0px; border-left: 0px; display: inline" border="0" alt="image" src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Blogs.Components.WeblogFiles/00/00/01/54/68/metablogapi/0383.image_thumb_7B211F4E.png" original-url="https://blogs.msdn.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-01-54-68-metablogapi/0383.image_5F00_thumb_5F00_7B211F4E.png" width="274" height="109" /></a> </p>    <p><a href="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Blogs.Components.WeblogFiles/00/00/01/54/68/metablogapi/8182.image_7811520A.png" original-url="https://blogs.msdn.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-01-54-68-metablogapi/8182.image_5F00_7811520A.png"><img title="image" style="border-top: 0px; border-right: 0px; border-bottom: 0px; border-left: 0px; display: inline" border="0" alt="image" src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Blogs.Components.WeblogFiles/00/00/01/54/68/metablogapi/7446.image_thumb_2C457B51.png" original-url="https://blogs.msdn.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-01-54-68-metablogapi/7446.image_5F00_thumb_5F00_2C457B51.png" width="564" height="25" /></a> </p> </blockquote>  <p></p>  <p>I was focusing at the amount of Bytes received which was 24 MB and it was disturbing me. I looked at the traffic to see what best can be done in order to compress the possible traffic. I also referred ‘Enable WCF Compression to Improve CRM 2011 Network Performance’ written by Jeremy at: <a title="https://blogs.msdn.com/b/crminthefield/archive/2011/12/29/enable-wcf-compression-to-improve-crm-2011-network-performance.aspx" href="https://blogs.msdn.com/b/crminthefield/archive/2011/12/29/enable-wcf-compression-to-improve-crm-2011-network-performance.aspx">https://blogs.msdn.com/b/crminthefield/archive/2011/12/29/enable-wcf-compression-to-improve-crm-2011-network-performance.aspx</a> to make sure all compressions are enabled. While validating it, I noticed that the WCF compression was not enabled, hence, I got it enabled following the steps mentioned by Jeremy. However at the same time, I also noticed that there wasn't much of the WCF calls in the captured web traffic.</p>  <p>Then, I thought of discussing it further with the network team to figure out other possibilities. I noticed that there is a Hardware Network Load Balancer (mentioned above) handling the web traffic and sending the request to the CRM Web Server. I started investigating it further and observed that the ‘compression was not enabled on the Load Balancer’. </p>  <p>I got it enabled and the results were remarkable:</p>  <blockquote>   <p><a href="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Blogs.Components.WeblogFiles/00/00/01/54/68/metablogapi/6560.image_151A00D3.png" original-url="https://blogs.msdn.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-01-54-68-metablogapi/6560.image_5F00_151A00D3.png"><img title="image" style="border-top: 0px; border-right: 0px; border-bottom: 0px; border-left: 0px; display: inline" border="0" alt="image" src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Blogs.Components.WeblogFiles/00/00/01/54/68/metablogapi/4353.image_thumb_506D6691.png" original-url="https://blogs.msdn.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-01-54-68-metablogapi/4353.image_5F00_thumb_5F00_506D6691.png" width="573" height="18" /></a> </p> </blockquote>  <p></p>  <p>Data received was reduced from 24MB to 7MB which certainly helped a lot in gaining the overall form load performance and better user experience.</p>  <p>Hope this helps in investigating any similar issues.</p>  <p>Cheers!!</p>  <p>Ritesh</p>]]></content:encoded>
    </item>
    <item>
      <title>SQL Read Committed Snapshot Isolation and Dynamics CRM</title>
      <link>https://docs.microsoft.com/archive/blogs/ritesh_ranjan/sql-read-committed-snapshot-isolation-and-dynamics-crm</link>
      <pubDate>Fri, 12 Sep 2014 03:32:00 GMT</pubDate>
      <dc:creator><![CDATA[Ritesh Ranjan - Technical Advisor]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/ritesh_ranjan/2014/09/12/sql-read-committed-snapshot-isolation-and-dynamics-crm/</guid>
      <description><![CDATA[Hello everyone,
Today, I would like to talk about something which has been making a lot of buzz...]]></description>
      <content:encoded><![CDATA[<p>Hello everyone,</p>
<p>Today, I would like to talk about something which has been making a lot of buzz lately. Just yesterday, I was reading some interesting stuff around that. Let&rsquo;s begin with Concurrency Effects in SQL. Let&rsquo;s say that there are a lot of users accessing the same set of data on a regular basis, and, if there is no way of maintaining concurrency, then users could face consequences like:</p>
<p><strong>Lost updates &ndash; </strong>occurs<strong> </strong>when two or more transactions select the same row and then updates the row on the basis of the value originally selected. Each transaction is unaware of the other transactions.</p>
<p><strong>Uncommitted dependency (dirty read) &ndash; </strong>occurs when a second transaction selects a row that is being updated by another transaction. The second transaction is reading data that has not been committed yet and may be changed by the transaction updating the row.</p>
<p><strong>Inconsistent analysis (non repeatable read) - </strong>occurs when a second transaction accesses the same row several times and reads different data each time.</p>
<p><strong>Phantom reads</strong> &ndash; occurs when an insert or delete action is performed against a row that belongs to a range of rows being read by a transaction.</p>
<p><strong>Missing and double reads &ndash; </strong>occurs when missing a updated row or seeing an updated row multiple times and missing one or more rows that were not the target of update.</p>
<blockquote>
<p>Extract from: <a title="https://msdn.microsoft.com/en-us/library/ms190805.aspx" href="https://msdn.microsoft.com/en-us/library/ms190805.aspx">https://msdn.microsoft.com/en-us/library/ms190805.aspx</a>&nbsp;</p>
</blockquote>
<p>READ COMMITTED snapshot isolation can be used to minimize potential locking contention while protecting transactions from &ldquo;dirty&rdquo; reads of uncommitted data modifications. With dirty reads, data within the current transaction can potentially be modified by other transactions between individual statements, resulting in non-repeatable reads or phantom data. In simple terms I would say READ COMMITTED snapshot isolation specifies that statements cannot read data that has been modified but not committed by other transactions.</p>
<p>These days production databases are quickly growing in size, and data-retention periods are increasing with changing business and regulatory requirements. Additionally, with drive capacity doubling and storage costs falling, the amount of data users want to keep "online" is increasing. In this scenario we can think of separating transactional data with analysis but that would be little expensive and leaves a question there, should we&hellip;? As we all know, SQL puts a lock on every statement until explicitly mentioned, under read committed transaction isolation, which means an active Select statement releases read locks after a resource is read.</p>
<p>Let me also share some information on isolation levels available in SQL, in this case SQL 2012:</p>
<p>&nbsp;</p>
<table style="width: 600px;" border="2" cellspacing="0" cellpadding="2">
<tbody>
<tr>
<td valign="top" width="159"><strong>Isolation level</strong></td>
<td valign="top" width="437"><strong>Best suited for an application when:</strong></td>
</tr>
<tr>
<td valign="top" width="159">Read uncommitted</td>
<td valign="top" width="437">The application does not require absolute accuracy of data (and could get a larger or smaller number than the final value) and wants performance of OLTP operations above all else. There is no version store to maintain, and no locks are acquired or honored when reading data. Data accuracy of queries in this isolation may see uncommitted changes.</td>
</tr>
<tr>
<td valign="top" width="159"><strong>Read committed</strong></td>
<td valign="top" width="437"><strong>The application does not require point-in-time consistency for long-running aggregations or long-running queries, yet wants data values that are read to be only transactionally consistent. The application does not want the overhead of the version store when reading data with the trade-off of potential incorrectness for long-running queries because of non-repeatable reads. This isolation level is ideally suited to transactions that rely upon the blocking behavior of locks to implement queuing applications or other ordered access to data.</strong></td>
</tr>
<tr>
<td valign="top" width="159">Read committed Using Row Versioning</td>
<td valign="top" width="437">The application requires absolute point-in-time consistency for long-running aggregations or queries. All data values must be transactionally consistent at the point in time where the query begins. The database administrator chooses the overhead of the version store for the benefit of increased throughput because of reduced lock contention. Additionally, the application wants transactional consistency for large queries, not transactions.</td>
</tr>
<tr>
<td valign="top" width="159">Repeatable read</td>
<td valign="top" width="437">The application requires absolute accuracy for long-running multi-statement transactions and must hold all requested data from other modifications until the transaction completes. The application requires consistency for all data that is read repeatedly within this transaction and requires that no other modifications be allowed. This can affect concurrency in a multiuser system if other transactions are trying to update data that has been locked by the reader. This is best when the application is relying on consistent data and plans to modify it later within the same transaction.</td>
</tr>
<tr>
<td valign="top" width="159"><strong>Snapshot</strong></td>
<td valign="top" width="437"><strong>The application requires absolute accuracy for long-running multi-statement transactions but does not plan to modify the data. The application requires consistency for all data that is read repeatedly within this transaction but plans to only read data. Shared locks are not necessary to prevent modifications by other transactions because the changes will not be seen until after the data modification transactions commit or roll back, and the snapshot transaction finishes. Data can be modified within this transaction level at the risk of conflicts with transactions that have updated the same data after the snapshot transaction started. This conflict must be handled by each updating transaction. A system that has multiple readers and a single writer (such as the replicated reporting system in the scenario section earlier in this paper) will not encounter conflicts.</strong></td>
</tr>
<tr>
<td valign="top" width="159">Serializable</td>
<td valign="top" width="437">The application requires absolute accuracy for long-running multi-statement transactions and must hold all requested data from other modifications until the transaction finishes. Additionally, the transactions are requesting sets of data and not just singleton rows. Each set must produce the same output at each request within the transaction, and other users cannot modify the data that has been read and cannot insert new rows into the set. This is best when the application is relying on consistent data, plans to modify it later within the same transaction, and requires absolute accuracy and data consistency up to the end of the transaction.</td>
</tr>
</tbody>
</table>
<blockquote>
<p>Extract from: <a title="https://msdn.microsoft.com/en-us/library/ms345124.aspx#sql2k5snapshotisol_topic05" href="https://msdn.microsoft.com/en-us/library/ms345124.aspx#sql2k5snapshotisol_topic05">https://msdn.microsoft.com/en-us/library/ms345124.aspx#sql2k5snapshotisol_topic05</a></p>
</blockquote>
<p><strong>In nutshell, if I may put it across to you, I would say that please analyze the scenario &amp; work with your DBA to plan it further. Also, please keep in mind that RCSI uses TempDB and enabling it could hinder the performance of your environment if your TempDB configuration is not optimal. For TempDB, ensure you have enough disk space, disk I/O, correct number of TempDB files and that the TempDB files are on a proper physical storage configuration (such as SSD's and separate from the CRM DB Files) will help reduce risk associated with TempDB performance.</strong></p>
<p>Hope I was able to explain well.</p>
<p>Stay tuned and enjoy reading!!</p>
<p>For more understanding you can also refer:</p>
<p><strong>Row Versioning-based Isolation Levels in the Database Engine</strong>: <a title="https://technet.microsoft.com/en-us/library/ms177404(v=sql.105).aspx" href="https://technet.microsoft.com/en-us/library/ms177404(v=sql.105).aspx">https://technet.microsoft.com/en-us/library/ms177404(v=sql.105).aspx</a></p>
<p><strong>Understanding Row Versioning-Based Isolation Levels</strong>: <a title="https://technet.microsoft.com/en-us/library/ms189050(v=sql.105).aspx" href="https://technet.microsoft.com/en-us/library/ms189050(v=sql.105).aspx">https://technet.microsoft.com/en-us/library/ms189050(v=sql.105).aspx</a></p>
<p><strong>Row Versioning-based Isolation Level Example: </strong><a title="https://technet.microsoft.com/en-us/library/ms191190(v=sql.105).aspx" href="https://technet.microsoft.com/en-us/library/ms191190(v=sql.105).aspx">https://technet.microsoft.com/en-us/library/ms191190(v=sql.105).aspx</a></p>
<p><strong>Enabling Row Versioning-Based Isolation Levels</strong>: <a title="https://technet.microsoft.com/en-us/library/ms175095(v=sql.105).aspx" href="https://technet.microsoft.com/en-us/library/ms175095(v=sql.105).aspx">https://technet.microsoft.com/en-us/library/ms175095(v=sql.105).aspx</a></p>]]></content:encoded>
    </item>
    <item>
      <title>Administering Dynamics CRM</title>
      <link>https://docs.microsoft.com/archive/blogs/ritesh_ranjan/administering-dynamics-crm</link>
      <pubDate>Fri, 15 Aug 2014 07:08:52 GMT</pubDate>
      <dc:creator><![CDATA[Ritesh Ranjan - Technical Advisor]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/ritesh_ranjan/2014/08/15/administering-dynamics-crm/</guid>
      <description><![CDATA[Hello everyone,  Today I am writing about a common scenario which I have noticed during my...]]></description>
      <content:encoded><![CDATA[<p><font size="3" face="Candara"></font></p>  <p><font size="3" face="Candara">Hello everyone,</font></p>  <p><font size="3" face="Candara">Today I am writing about a common scenario which I have noticed during my customer visits lately. This is primarily focused on administering Dynamics CRM. I have tried to include almost every aspect that I could recollect from my customer visits. So, whether you would like to prepare your plan for maintaining Dynamics CRM effectively or define a benchmark based on this, you could use the information listed below.</font></p>  <p><font size="3" face="Candara">Happy reading!!</font></p>  <p>   <br /><b><u><font size="3" face="Candara">CRM Server Maintenance:</font></u></b></p>  <p><strong><u><font size="3" face="Candara"></font></u></strong></p>  <ul>   <li><font size="3" face="Candara">Make sure to have windows updates reviewed, tested and installed on the servers, along with validating the common security mis-configurations. You can use </font><a href="https://www.microsoft.com/en-eg/download/details.aspx?id=7558"><font size="3" face="Candara">Microsoft Baseline Security Analyser</font></a><font size="3" face="Candara"> which provides a streamlined method to identify missing security updates and common security mis-configurations.</font> </li>    <li><font size="3" face="Candara">Regular monitoring of event logs. For more information you can refer: </font><a href="https://technet.microsoft.com/en-us/library/hh206051.aspx"><font size="3" face="Candara">https://technet.microsoft.com/en-us/library/hh206051.aspx</font></a>&#160; </li>    <li><font size="3" face="Candara">Regular monitoring of server performance counters.&#160; For more information you can refer: </font><a href="https://msdn.microsoft.com/en-us/library/windows/desktop/aa371643(v=vs.85).aspx"><font size="3" face="Candara">https://msdn.microsoft.com/en-us/library/windows/desktop/aa371643(v=vs.85).aspx</font></a><font size="3" face="Candara"> and </font><a href="https://technet.microsoft.com/en-us/library/bb734903.aspx"><font size="3" face="Candara">https://technet.microsoft.com/en-us/library/bb734903.aspx</font></a> </li>    <li><font size="3" face="Candara">Anti-virus exclusions for Microsoft Dynamics CRM: </font><a href="https://blogs.msdn.com/b/crminthefield/archive/2011/01/24/anti-virus-exclusions-for-microsoft-dynamics-crm.aspx"><font size="3" face="Candara">https://blogs.msdn.com/b/crminthefield/archive/2011/01/24/anti-virus-exclusions-for-microsoft-dynamics-crm.aspx</font></a> </li>    <li><font size="3" face="Candara">Maintaining AsyncOperationBase: </font><a href="https://support.microsoft.com/kb/968520"><font size="3" face="Candara">https://support.microsoft.com/kb/968520</font></a> </li>    <li><font size="3" face="Candara">Maintaining WorkflowLogBase: </font><a href="https://support.microsoft.com/kb/968755"><font size="3" face="Candara">https://support.microsoft.com/kb/968755</font></a> </li>    <li><font size="3" face="Candara">Maintaining PrincipalObjectAccess - you may notice that the size of the SQL table PrincipalObjectAccess grows and could be using a large percentage of the database size. Unmonitored growth in this table can cause performance issues:</font> <a href="https://support.microsoft.com/kb/2664150"><font size="3" face="Candara">https://support.microsoft.com/kb/2664150</font></a><font size="3" face="Candara"> and </font><a href="https://blogs.msdn.com/b/crminthefield/archive/2011/06/09/principalobjectaccess-performance-recommendations.aspx"><font size="3" face="Candara">https://blogs.msdn.com/b/crminthefield/archive/2011/06/09/principalobjectaccess-performance-recommendations.aspx</font></a><font size="3" face="Candara"> and </font><a href="https://community.dynamics.com/crm/b/cinterosab_crmblog/archive/2013/01/22/principal-object-access-table-poa-table-grows-large.aspx"><font size="3" face="Candara">https://community.dynamics.com/crm/b/cinterosab_crmblog/archive/2013/01/22/principal-object-access-table-poa-table-grows-large.aspx</font></a> </li>    <li><font size="3" face="Candara">Dynamics CRM maintenance jobs: </font><a href="https://blogs.msdn.com/b/crminthefield/archive/2012/04/26/avoid-performance-issues-by-re-scheduling-crm-2011-maintenance-jobs.aspx"><font size="3" face="Candara">https://blogs.msdn.com/b/crminthefield/archive/2012/04/26/avoid-performance-issues-by-re-scheduling-crm-2011-maintenance-jobs.aspx</font></a><font size="3" face="Candara"> and </font><a href="https://blogs.msdn.com/b/crminthefield/archive/2013/02/07/more-details-on-dynamics-crm-2011-async-service-maintenance-jobs.aspx"><font size="3" face="Candara">https://blogs.msdn.com/b/crminthefield/archive/2013/02/07/more-details-on-dynamics-crm-2011-async-service-maintenance-jobs.aspx</font></a> </li>    <li><font size="3" face="Candara">Maintaining and managing workflows in Dynamics CRM: </font><a href="https://blogs.msdn.com/b/ritesh_ranjan/archive/2012/08/22/dynamics-crm-troubleshooting-workflows.aspx"><font size="3" face="Candara">https://blogs.msdn.com/b/ritesh_ranjan/archive/2012/08/22/dynamics-crm-troubleshooting-workflows.aspx</font></a> </li>    <li><font size="3" face="Candara">Tips and tricks from </font><a href="https://www.microsoft.com/en-us/download/details.aspx?id=27139"><font size="3" face="Candara">Optimizing and maintaining the performance of a Microsoft Dynamics CRM 2011 server infrastructure</font></a> </li>    <li><font size="3" face="Candara">Keep yourself updated with </font><a href="https://support.microsoft.com/kb/2555051"><font size="3" face="Candara">Microsoft Dynamics CRM 2011 updates and hotfixes</font></a> </li>    <li><font size="3" face="Candara">Understanding of OrgDBOrgSettings tool for Microsoft Dynamics CRM 2011: </font><a href="https://support.microsoft.com/kb/2691237"><font size="3" face="Candara">https://support.microsoft.com/kb/2691237</font></a> </li>    <li><font size="3" face="Candara">Maintaining Dynamics CRM 2011 using PowerShell: </font><a href="https://community.dynamics.com/crm/b/c5insightblog/archive/2011/03/10/manage-dynamics-crm-2011-with-powershell.aspx"><font size="3" face="Candara">https://community.dynamics.com/crm/b/c5insightblog/archive/2011/03/10/manage-dynamics-crm-2011-with-powershell.aspx</font></a><font size="3" face="Candara"> and </font><a href="https://msdn.microsoft.com/en-us/library/hh699700(v=crm.5).aspx"><font size="3" face="Candara">https://msdn.microsoft.com/en-us/library/hh699700(v=crm.5).aspx</font></a> </li>    <li><font size="3" face="Candara">Optimizing and Maintaining a Microsoft Dynamics CRM 2011 Server Infrastructure: </font><a href="https://technet.microsoft.com/en-us/library/hh413200.aspx"><font size="3" face="Candara">https://technet.microsoft.com/en-us/library/hh413200.aspx</font></a> </li>    <li><font size="3" face="Candara">Operating Microsoft Dynamics CRM: </font><a href="https://msdn.microsoft.com/en-us/library/hh699700(v=crm.5).aspx"><font size="3" face="Candara">https://msdn.microsoft.com/en-us/library/hh699700(v=crm.5).aspx</font></a> </li>    <li><font size="3" face="Candara">Known risks and vulnerabilities: </font><a href="https://msdn.microsoft.com/en-us/library/hh699686(v=crm.5).aspx"><font size="3" face="Candara">https://msdn.microsoft.com/en-us/library/hh699686(v=crm.5).aspx</font></a> </li>    <li><font size="3" face="Candara">Cleaning up CRM Sync Entry tables: <a title="https://blogs.msdn.com/b/crminthefield/archive/2012/10/03/cleaning-up-crm-sync-entry-tables.aspx" href="https://blogs.msdn.com/b/crminthefield/archive/2012/10/03/cleaning-up-crm-sync-entry-tables.aspx">https://blogs.msdn.com/b/crminthefield/archive/2012/10/03/cleaning-up-crm-sync-entry-tables.aspx</a></font> </li> </ul>  <p><font size="3"><font face="Candara"><b><u>SQL Server monitoring:</u></b></font></font></p>  <p><strong><u><font size="3" face="Candara"></font></u></strong></p>  <ul>   <li><font size="3" face="Candara">Regular monitoring of event logs. For more information you can refer: </font><a href="https://technet.microsoft.com/en-us/library/hh206051.aspx"><font size="3" face="Candara">https://technet.microsoft.com/en-us/library/hh206051.aspx</font></a> </li>    <li><font size="3" face="Candara">SQL performance counters: </font><a href="https://msdn.microsoft.com/en-us/library/ms137622.aspx"><font size="3" face="Candara">https://msdn.microsoft.com/en-us/library/ms137622.aspx</font></a> </li>    <li><font size="3" face="Candara">Missing Indexes: </font><a href="https://technet.microsoft.com/en-us/library/ms345417(v=sql.105).aspx"><font size="3" face="Candara">https://technet.microsoft.com/en-us/library/ms345417(v=sql.105).aspx</font></a> </li>    <li><font size="3" face="Candara">Index Defragmentation: </font><a href="https://technet.microsoft.com/en-us/library/cc966523.aspx"><font size="3" face="Candara">https://technet.microsoft.com/en-us/library/cc966523.aspx</font></a> </li>    <li><font size="3" face="Candara">Monitoring deadlocks: </font><a href="https://blogs.msdn.com/b/sqlserverfaq/archive/2013/04/27/an-in-depth-look-at-sql-server-memory-part-2.aspx"><font size="3" face="Candara">https://blogs.msdn.com/b/sqlserverfaq/archive/2013/04/27/an-in-depth-look-at-sql-server-memory-part-2.aspx</font></a><font size="3" face="Candara"> and </font><a href="https://technet.microsoft.com/en-us/library/ms178104(v=sql.105).aspx"><font size="3" face="Candara">https://technet.microsoft.com/en-us/library/ms178104(v=sql.105).aspx</font></a> </li>    <li><font size="3" face="Candara">Monitoring SQL blockings &amp; timeouts: </font><a href="https://technet.microsoft.com/en-US/2008.04.blocking.aspx"><font size="3" face="Candara">https://technet.microsoft.com/en-US/2008.04.blocking.aspx</font></a><font size="3" face="Candara"> and </font><a href="https://technet.microsoft.com/en-us/library/ms190181(v=sql.105).aspx"><font size="3" face="Candara">https://technet.microsoft.com/en-us/library/ms190181(v=sql.105).aspx</font></a> </li>    <li><font size="3" face="Candara">Monitoring SQL_Wait_Stats: </font><a href="https://technet.microsoft.com/en-us/library/ms190732(v=sql.110).aspx"><font size="3" face="Candara">https://technet.microsoft.com/en-us/library/ms190732(v=sql.110).aspx</font></a><font size="3" face="Candara"> and </font><a href="https://msdn.microsoft.com/en-us/library/ms179984.aspx"><font size="3" face="Candara">https://msdn.microsoft.com/en-us/library/ms179984.aspx</font></a><font size="3" face="Candara"> and </font><a href="https://www.sqlskills.com/blogs/paul/wait-statistics-or-please-tell-me-where-it-hurts/"><font size="3" face="Candara">https://www.sqlskills.com/blogs/paul/wait-statistics-or-please-tell-me-where-it-hurts/</font></a> </li>    <li><font size="3" face="Candara">Monitoring SQL long running queries: </font><a href="https://technet.microsoft.com/en-us/library/ms177500(v=sql.105).aspx"><font size="3" face="Candara">https://technet.microsoft.com/en-us/library/ms177500(v=sql.105).aspx</font></a><font size="3" face="Candara"> and </font><a href="https://technet.microsoft.com/en-us/library/cc879320(v=sql.105).aspx"><font size="3" face="Candara">https://technet.microsoft.com/en-us/library/cc879320(v=sql.105).aspx</font></a> </li>    <li><font size="3" face="Candara">Regular checks of SQL errors: </font><a href="https://technet.microsoft.com/en-us/library/ms191202(v=sql.105).aspx"><font size="3" face="Candara">https://technet.microsoft.com/en-us/library/ms191202(v=sql.105).aspx</font></a> </li>    <li><font size="3" face="Candara">Frequently validating SQL backups: </font><a href="https://technet.microsoft.com/en-us/library/ms189587(v=sql.105).aspx"><font size="3" face="Candara">https://technet.microsoft.com/en-us/library/ms189587(v=sql.105).aspx</font></a> </li>    <li><font size="3" face="Candara">Monitoring SQL DMVs: </font><a href="https://msdn.microsoft.com/en-us/library/ms188754.aspx"><font size="3" face="Candara">https://msdn.microsoft.com/en-us/library/ms188754.aspx</font></a> </li>    <li><font size="3" face="Candara">Regular checks on the reports error: </font><a href="https://technet.microsoft.com/en-us/library/cc512029.aspx"><font size="3" face="Candara">https://technet.microsoft.com/en-us/library/cc512029.aspx</font></a><font size="3" face="Candara"> and </font><a href="https://msdn.microsoft.com/en-us/library/ms165307.aspx"><font size="3" face="Candara">https://msdn.microsoft.com/en-us/library/ms165307.aspx</font></a> </li> </ul>  <p><font size="3"><font face="Candara"><b><u>IIS maintenance:</u></b></font></font></p>  <p><strong><u><font size="3" face="Candara"></font></u></strong></p>  <ul>   <li><font size="3" face="Candara">View Currently Executing Requests in a Worker Process (IIS 7): </font><a href="https://technet.microsoft.com/en-us/library/c6af847b-4b49-4fd4-b7bf-c2a8152f5f9d"><font size="3" face="Candara">https://technet.microsoft.com/en-us/library/c6af847b-4b49-4fd4-b7bf-c2a8152f5f9d</font></a> </li>    <li><font size="3" face="Candara">Create a Tracing Rule for Failed Requests (IIS 7): </font><a href="https://technet.microsoft.com/en-us/library/3dbee69b-ca3b-4adf-ab9e-81a541fc908c"><font size="3" face="Candara">https://technet.microsoft.com/en-us/library/3dbee69b-ca3b-4adf-ab9e-81a541fc908c</font></a> </li>    <li><font size="3" face="Candara">Enable Trace Logging for Failed Requests (IIS 7): </font><a href="https://technet.microsoft.com/en-us/library/30036297-9b85-40fb-93f4-5d43a48fd7eb"><font size="3" face="Candara">https://technet.microsoft.com/en-us/library/30036297-9b85-40fb-93f4-5d43a48fd7eb</font></a> </li>    <li><font size="3" face="Candara">Core IIS Administration: </font><a href="https://technet.microsoft.com/en-us/library/bb727092.aspx"><font size="3" face="Candara">https://technet.microsoft.com/en-us/library/bb727092.aspx</font></a> </li>    <li><font size="3" face="Candara">High Availability and Scalability: </font><a href="https://www.iis.net/learn/extensions/configuring-application-request-routing-(arr)/achieving-high-availability-and-scalability-arr-and-hardware-load-balancer"><font size="3" face="Candara">https://www.iis.net/learn/extensions/configuring-application-request-routing-(arr)/achieving-high-availability-and-scalability-arr-and-hardware-load-balancer</font></a> </li> </ul>  <p></p>  <p><font size="3" face="Candara">Also, I would like to include an article written by Shawn on CRM Upgrade Best Practices which should always be considered when planning for an upgrade:</font> <a title="https://blogs.msdn.com/b/crminthefield/archive/2012/10/10/crm-upgrade-best-practices.aspx" href="https://blogs.msdn.com/b/crminthefield/archive/2012/10/10/crm-upgrade-best-practices.aspx"><font size="3" face="Candara">https://blogs.msdn.com/b/crminthefield/archive/2012/10/10/crm-upgrade-best-practices.aspx</font></a></p>]]></content:encoded>
    </item>
  </channel>
</rss>