SharePoint Experts, Information Architects, Expert Witness

We provide consulting in a broad array of business and technology from architecture to design to deployment of global systems with a focus on surfacing data in the enterprise. Specialists in Microsoft, we are a premier provider of SharePoint Expertise (including 2016 and Office 365). We also provide Expert Witness/Legal Expert in eDiscovery, source discovery, patent infringement, piracy and more! We also have established SICG DLDS s.a. - our counterpart in Costa Rica that specializes in water systems (http://www.crwatersolutions.com) - Contact me direct: david_sterling@sterling-consulting.com or call 704-873-8846 x704.

Search This Blog

Saturday, October 28, 2017

Event 6398 - The Execute method of job definition Microsoft.Office.Server.UserProfiles.UserProfileImportJob

Like many of you know, SharePoint 2013 and 2016 comes up with some recurring issues from time to time - one of these is Event ID 6398:

"The Execute method of job definition Microsoft.Office.Server.UserProfiles.UserProfileImportJob..."

Seen in the event log, it looks like this:


I myself forget about this occasionally (thus why I am posting here!).

Fortunately, this is not a big deal - this just means that the Forefront Identity Manager Service is not running. From Administrative Tools, open the Services (or use Start > Run and enter services.msc). Look for the two Forefront services - you will see the Manager service is stopped:


Right click on the service and select Start - problem solved!

NEW RELATED ISSUE:

Started getting various errors in a User Profile Service:

Detection of product '{90150000-104C-0000-1000-0000000FF1CE}', feature 'PeopleILM', component '{1C12B6E6-898C-4D58-9774-AAAFBDFE273C}' failed

Fix is easy - just add the NETWORK SERVICE account to the WSS_WPG Group: Technet Fix



Monday, October 23, 2017

Using LdapConnection and Checking account status in Active Directory

Dual purpose post here - I needed to set up a test to determine if users had an expired password the most efficient way. I found a number of ways but the best was using LdapConnection.

First issue was knowing what to use for the LDAP connection string - I usually use LDAP://<server>/OU=<ou>,DC=<domain>,DC=<extension> - for example:

LDAP://MyADServer/OU=users,DC=testdom,DC=com

and sometimes simply:

LDAP://DC=testdom,DC=com

(Note the OU is optional)

However these didn't work for LdapConnection - examples I found showed "ldap.domain.com" - that didn't work either. The easiest was simply to use the LdapDirectoryIdentifier:

// NO GOOD:
        //LdapConnection connection = new LdapConnection("ldap.testdom.com");
// NO GOOD:
        //LdapConnection connection = new LdapConnection("LDAP://myadcontroller/DC=testdom,DC=com");
// This works:
        LdapDirectoryIdentifier LDI = new LdapDirectoryIdentifier("myadcontroller");
        LdapConnection connection = new LdapConnection(LDI);
        NetworkCredential credential = new NetworkCredential("TheAccountWODomain", "ThePassword");
        connection.Credential = credential;
        connection.Bind();




Sunday, August 6, 2017

Adding a Description to your Timer Jobs (SharePoint 2013/2016)

I know, been a while since I needed one but had to build a few timer jobs for an On Premise location. As in the past, there's a 'bug' in the Timer Job namespace where in you cannot add a 'description' (it's read only due to crappy development).

I had to do some research having not touched these for quite a while so posting here so I don't have to remember (again).

To add a description, you have to override the "Description" in the timer job and provide your own, then you have to add it to all three of the class definitions. In this case it was a timer job to purge documents after 72 hours.

The Override and new description property:

        /// <summary>
        /// Description - Override built-in Description property
        /// </summary>
        public override string Description
        {
            get
            { return CustomDescription; }
        }
        /// <summary>
        /// CustomDescription - Used to provide "Set" to the Job Description
        /// </summary>
        private string CustomDescription
        {
            get;
            set;
        }

Adding to the the class def

             public PurgeAfter72HoursClass() : base()
        {
            this.Title = JobName;
            this.CustomDescription = JobDescription;
        }

        public PurgeAfter72HoursClass(string jobName, SPService service, SPServer server, SPJobLockType targetType)
            : base(jobName, service, server, targetType)
        {
            this.Title = JobName;
            this.CustomDescription = JobDescription;
        }

        public PurgeAfter72HoursClass(string jobName, SPWebApplication webApplication, string strUrl)
            : base(jobName, webApplication, null, SPJobLockType.ContentDatabase)
        {
            this.Title = JobName;
            this.CustomDescription = JobDescription;
        }

Have fun!


Tuesday, August 1, 2017

The Open Procedure for service "BITS" in DLL

As many will know, the following error shows up in the Event Log (Event ID 1008):

Log Name:Application 
Source:Microsoft-Windows-Perflib 
Event ID:1008 
Description:The Open Procedure for service "BITS" in DLL "C:\Windows\System32\bitsperf.dll" failed. Performance data for this service will not be available. The first four bytes (DWORD) of the Data section contains the error code. 

This problem occurs when BITS(Background Intelligent Transfer Service)has been never started.
The error is not recorded if BITS starts by manual operation or Windows Update starts.

Fix: Simply start the dang service - no harm, no foul. Leaving it on automatic startup doesn't hurt either. Resetting the counters as many suggest doesn't work.

From the Administrative Tools, click on Services or click Start > Run then enter services.msc. Find the "Background Intelligent Transfer Service" and start it (and/or set it to start automatically):



While I found MANY references, this one gave the assurance on what the real problem is (and how to fix): http://www.fujitsu.com/global/products/computing/servers/mission-critical/primequest/software/win2012-r2-precautions.html

Sunday, July 16, 2017

SharePoint web application creation - '' is an unexpected token. Expecting white space. Line 1, position 15478f

So this was interesting - a "lesson learned":

Setup of a new farm, all going well - tried to create a web application. It was created but show the message 'MD2' is an unexpected token. Expecting white space. Line 1, position 15478 and there was no link to create a site.

In my case, the "MD2" was the start of the names of the databases that were being created for the services.

What I thought could this be? Turns out the PowerShell scripts I was using was putting a space in the database name - i.e. "MD2 SessionState" due to an edit error.

The workaround is let it create then assign a site - however, the PROPER fix is to rebuild all services and be sure that there is NO space in the name.


The trust relationship between this workstation and the primary domain failed

Everyone's had this problem - I just wasted a day yesterday trying to fix on a set of VM's. An update to VMWare Workstation caused a bunch of network issues - tracking many of them down was a real pain.

Additional note: this has become a common re-occurrence since updating VM Workstation 12 (specifically 12.5.7 build-5813279).

So Kudos to http://implbits.com/active-directory/2012/04/03/dont-rejoin-to-fix.html on how to fix this issue. I recommend using the netdom method - simply login to the box with problem as an administrator, open a command prompt (using Run as administrator) then enter:

netdom resetpwd /s:<domain server name> /ud:<user with permissions, domain\name> /pd:<user password>

Example:

netdom resetpwd /s:SysTestADMachine /ud:SysTest\ADManager /pd:ABC1234!

If not prompted, reboot anyway.

AS A SIDE EFFECT - your accounts might be a bit whacked, particularly if it is a server running application - be aware that you MAY have to reset the password for all system related accounts (application pools, etc.).

Some other issues that were encountered in my foray of fun yesterday:

Using NETDOM - the Target Name is Incorrect - the above corrects.

Using Remote Desktop - "The Local Security Authority Cannot Be Contacted" - simply reset the password of the account in Active Directory (Kudos: http://blog.mnewton.com/articles/solution-rdp-the-local-security-authority-cannot-be-contacted/).

NOTE: There seems another 'fix' per VMWare in which the Computer Password changes automatically which can get out of sync with clean systems. This is a Registry Fix (so if you don't know Regedit, don't try this):

  1. Open Regedit (using Run as administrator)
  2. Navigate to HKLM\System\CurrentControlSet\services\Netlogon\Parameters
  3. Change the DisablePasswordChange key from 0 to 1

A reboot may be required AND you might have to reset the computer password as above (using NetDom). Full explanation can be found here: https://communities.vmware.com/thread/327644






Friday, July 14, 2017

So this one is a question! User Profile Service Page is BLANK!

So here's a question for all - working a development system, I suddenly noticed that I was unable to access Site Settings in any collection despite having full access. 

Took a while looking around but then found this:


Notice? There are NO OPTIONS on the page!

I'd love to get an answer if anyone has it - in the meantime, I rebuilt the User Profile Service - same problem!

I will post an answer if I can find it!