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

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