So, in my infinite wisdom I decided to try and resolve an issue (Working on 2 issues at a time, important point.)

First issue: I noticed that one of our CRM services wasn’t actually using one of our production service accounts, no issue at all. Quick fix and a service restart. (ProTip 2: Don’t do this during production hours. Do as I say not as I do). Never an issue. Not actually sure who configured this the first time around, but stuff happens.

The second issue, I was trying to resolve a stupid issue regarding a CRM user account (See where this is going?). Cool, open CRM, settings, administration, add user, save. This is where my heart rate jumped 100BPM.

In my infinity wisdom, I copied the service account into the username, let it populate then hit save.

INSUFFICIENT PERMISSIONS. Contact an administrator.

[Lots of swearwords]+[Panic attack]+[Emotional breakdown as I don’t want to do any sort of restoration during production hours]

O WAIT, I R ADMIN AND KNOW CRM DATABASE. THIS COULD BE WORSE.

  1. Open up SSMS
  2. use [CRM DB]
  3. SELECT * From SystemUserBase where DomainName = ‘domain\serviceaccount
  4. Copy the SystemUserID

Run the following scripts (Taken from: https://markuserlandsson.wordpress.com/2014/10/02/adding-dynamics-crm-service-account-as-a-crm-user/ ) – With a modification

Note: This SQL will error regarding table references, delete from said tables too.

Restart services / Reboot as required.

ProTip: ONE TASK AT A TIME.
ProTip 2: DON’T ADD SERVICE ACCOUNTS AS USERS UNLESS YOU WANT TO BE LOCKED OUT OF ALL PERMISSIONS.
ProTip 3: BREATHE.

November 6, 2019

Dynamics CRM ProTip: NEVER add a service account as a user account

So, in my infinite wisdom I decided to try and resolve an issue (Working on 2 issues at a time, important point.) First issue: I noticed […]
June 5, 2017

Dynamics CRM – Creating an instance of the COM component with CLSID {080D0D78-F421-11D0-A36E-00C04FB950DC} from the IClassFactory failed due to the following error: 800401e4 Invalid syntax (Exception from HRESULT: 0x800401E4 (MK_E_SYNTAX))

TL;DR: Reboot your web front end and reboot where the deployment manager is located. EDIT: TL;DR-2: Make sure the services you’re trying to connect to are […]
April 25, 2017

Get Dynamics CRM Organisation ID to manage AD groups

Once again, I’ve taken control of a (few) Dynamics environments, each having been setup slightly differently (Account per service, single account across all services, user accounts […]
April 6, 2017

CRM 2011 – SSRS – The target principal name is incorrect

It’s not considered stealing if I wrote it myself – Putting it here for self-self-self reference as this bit me in the ass today. [crayon-5f079fa4eb571378791145/] My original post […]
November 28, 2016

Note to Self – Search through sql syscomments

select distinct OBJECT_NAME(id) from sys.syscomments where text like ‘%6%’
January 28, 2016

Dynamics CRM | SSRS – Error Uploading Report

Over the last week I’ve been tweaking some of our logic in CRM and totally forgot to update our reports to show our statistics..  A week […]
January 13, 2016

CRM SQL – sp_dropserver / sp_addserver

Had an instance after doing a VM clone where the CRM installer couldn’t see the server I wanted. Did some digging… Open the database you want […]
January 12, 2016

SQL Server – Change table ownership

We’ve got a 3rd party application we’re having to upgrade which generates tables on the fly, the issue with this is that the database owner (Which […]
December 16, 2015

SilverPop (CoreMotives) – Dynamics CRM 2013 SQL – Campaign Interactions

Had a request today to pull interactions for a certain campaign today. CoreMotives has a great interaction section which allows you to view information about clicks, […]
December 15, 2015

Dynamics CRM 2013 SQL – System Jobs Monitoring

Last one for today.. Another instance of me using SSRS to send me emails every day, just so I can keep track of system wide errors. […]