Who's Online
9 visitors online now
3 guests, 6 bots, 0 members
Support my Sponsor
  • An error has occurred, which probably means the feed is down. Try again later.

Archive for the ‘SharePoint’ Category

SharePoint DeadLock high CPU\Memory usage caused by SQL server

Yesterday there was a resource Dead lock in our environment. Here is the analysis of same.

In the log files I see below error:
Exception returned from back end service. System.ServiceModel.ServiceActivationException: The requested service, ‘http://SPserver:32843/cebdf111573e42e68f08f730c2273460/MetadataWebService.svc‘ could not be activated. See the server’s diagnostic trace logs for more information.    Server stack trace:      at System.ServiceModel.Channels.HttpChannelUtilities.ValidateRequestReplyResponse(HttpWebRequest request, HttpWebResponse response, HttpChannelFactory1 factory, WebException responseException, ChannelBinding channelBinding)     at System.ServiceModel.Channels.HttpChannelFactory1.HttpRequestChannel.HttpChannelRequest.WaitForReply(TimeSpan timeout)     at System.ServiceModel.Channels.RequestChannel.Request(Message message, TimeSpan timeout)     at System.ServiceModel.Channels.Securit…     0e0e6254-6880-426a-97ce-03d3bc471eba
…yChannelFactory1.SecurityRequestChannel.Request(Message message, TimeSpan timeout)     at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)     at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)     at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)    Exception rethrown at [0]:      at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)     at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)     at Microsoft.SharePoint.Taxonomy.IMetadataWebServiceApplication.GetServiceSettings(Guid rawPartitio...  0e0e6254-6880-426a-97ce-03d3bc471eba
...nId)     at Microsoft.SharePoint.Taxonomy.MetadataWebServiceApplicationProxy.<>c__DisplayClass32.<ReadApplicationSettings>b__31(IMetadataWebServiceApplication serviceApplication)     at Microsoft.SharePoint.Taxonomy.MetadataWebServiceApplicationProxy.<>c__DisplayClass2f.<RunOnChannel>b__2d() 0e0e6254-6880-426a-97ce-03d3bc471eba
Exception returned from back end service. System.ServiceModel.ServiceActivationException: The requested service, '<a href="https://mex07a.emailsrvr.com/owa/redir.aspx?C=KRbZSeF9uU29V-5zxS1tsTPNGKdIwdFIXZhCLbBay6Qs_9lUFUpcvQ2u__5EYKOJ_IUe70_2VYM.&amp;URL=http%3a%2f%2fsynhnjseza1521%3a32843%2fcebdf111573e42e68f08f730c2273460%2fMetadataWebService.svc" target="_blank">http://SPserver:32843/cebdf111573e42e68f08f730c2273460/MetadataWebService.svc</a>' could not be activated. See the server's diagnostic trace logs for more information.    Server stack trace:      at System.ServiceModel.Channels.HttpChannelUtilities.ValidateRequestReplyResponse(HttpWebRequest request, HttpWebResponse response, HttpChannelFactory
1 factory, WebException responseException, ChannelBinding channelBinding)     at System.ServiceModel.Channels.HttpChannelFactory1.HttpRequestChannel.HttpChannelRequest.WaitForReply(TimeSpan timeout)     at System.ServiceModel.Channels.RequestChannel.Request(Message message, TimeSpan timeout)     at System.ServiceModel.Channels.Securit...     81aba100-3f92-4c5b-9d20-53923c8db760
...yChannelFactory
1.SecurityRequestChannel.Request(Message message, TimeSpan timeout)     at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)     at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)     at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)    Exception rethrown at [0]:      at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)     at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)     at Microsoft.SharePoint.Taxonomy.IMetadataWebServiceApplication.GetServiceSettings(Guid rawPartitio…  81aba100-3f92-4c5b-9d20-53923c8db760
…nId)     at Microsoft.SharePoint.Taxonomy.MetadataWebServiceApplicationProxy.<>c__DisplayClass32.<ReadApplicationSettings>b__31(IMetadataWebServiceApplication serviceApplication)     at Microsoft.SharePoint.Taxonomy.MetadataWebServiceApplicationProxy.<>c__DisplayClass2f.<RunOnChannel>b__2d() 81aba100-3f92-4c5b-9d20-53923c8db760

When try to browse “‘http://SPserver:32843/cebdf111573e42e68f08f730c2273460/MetadataWebService.svc‘” I got message which indicate resources are not available. I found that CPU usage on server is 80 % and RAM usage 95 %. SQL server alone was using 9 GB out of 12 GB.

Cause: SQL server has a default behavior to not release RAM after it is consumed. It stores recent transaction in RAM to increase server performance. But if you have other application running on same machine then those application(e.g. Sharepoint) will not get resource to perform their operation hence causing a deadlock. Soon due to repeated request from the server effect SQL server and we start getting error “SqlError: ‘A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections.”

Solution: It is a permanent solution to put a cap on SQL server RAM\Memory utilization. To do so follow below steps:
1. Open SQL server management Studio > Connect to SQL server instance. You can connect it using SQL or windows credentials
0072

  1. Right Click server go to Properties
    0073

  2. Select Memory

  3. For Max server Memory (in MB) Set Value which is about 40 % of total Memory available. I set it to 3500
    0074

  4. Click OK

  5. Right Click server and select restart
    0075
  6. You will get 2 prompt to stop and start the service. Click on Yes(Incase of SQL server 2012, you will get only 1 prompt to restart instead of 2)
    0071

Note: This will make sure SQL does not use more then assigned memory even if it is available. This is recommended only for environment which as DATABASE and Other APPLICATION on same system.

Understanding of Application pools

Application pools define a set of Web applications that share one or more worker processes, they provide a convenient way to administer a set of Web sites and applications and their corresponding worker processes.

Web Site = IIS Virtual Server = SharePoint Web Application
Web Applications have Application Pools… You can manage your web apps in IIS manager.
Application Pools have Worker processes… You’ll see a section in your IIS manager for managing your app pools.

  1. Application Pool is more in relation to IIS than of SharePoint

  2. As you create and manage web applications using SharePoint, it gives you to create, manage and associate web applications with Application Pool. So you see the Application Pool creation and configuration options in SharePoint but its more related to IIS

  3. An application pool provides you with a way of isolating Web sites from each other even though they are being hosted on a common server. Each application pool is given its own set of server resources. That way, if a Web site crashes, it won’t effect sites in other application pools.

Example:

A good example of this is a Web site with a memory leak. If all of the Web sites hosted on a particular server were to share system resources, and one of the Web sites had a memory leak, it could potentially take memory away from the other hosted sites. If the leaky site were in its own application pool though, the memory leak would not effect any other site because each application pool has its own server resources (including memory).

Applicationpool

 Reference : http://skdeveloper.wordpress.com/2013/10/09/application-pools/

Differences Between Sandboxed and Farm Solutions Process

Farm Solutions:

Farm solutions, which are hosted in the IIS worker process (W3WP.exe), run code that can affect the whole farm. When you debug a SharePoint project whose Sandboxed Solution property is set to “farm solution,” the system’s IIS application pool recycles before SharePoint retracts or deploys the feature so as to release any files locked by the IIS worker process. Only the IIS application pool serving the SharePoint project’s site URL is recycled.

 

Sandboxed Solutions:

Sandboxed solutions, which are hosted in the SharePoint user code solution worker process (SPUCWorkerProcess.exe), run code that can only affect the site collection of the solution. Because sandboxed solutions do not run in the IIS worker process, neither the IIS application pool nor the IIS server must restart. Visual Studio attaches the debugger to the SPUCWorkerProcess process that the SPUserCodeV4 service in SharePoint automatically triggers and controls. It is not necessary for the SPUCWorkerProcess process to recycle to load the latest version of the solution.

Back Up a Content Database from SharePoint 2010 and Restore it to SharePoint 2013

Have you recently upgraded to SharePoint 2013 from SharePoint 2010 and need to migrate your content database?  In this article, we will walk through the process of backing up all the lists, sites, databases, etc. that you created using your Bamboo products in SharePoint 2010 and restore them in SharePoint 2013.

Before you begin:

You will need to have two servers which have the same environment:

  • Server 1: Windows 2008; SQL Server 2008; SharePoint 2010.
  • Server 2: Windows 2008; SQL Server 2008; SharePoint 2013.

Back up your content Database in SharePoint 2010 and restore it in SharePoint 2013 in just five steps:

1.    Back up your database from SharePoint 2010 Server through SQL Server 2008:

  • Right-click the database of the port which you want to back up, then Tasks, then Back Up…
  • See the example below; the database of port 80 is WSS_Content:

  • Click the Add button.

Make sure you note the Destination path to get the WSS_Content.bak file:

2.    Create a new Web application on SharePoint 2013 server:

  • Create a new Web application with any port (Example: port 88)
  • After the new Web application has been successfully created, go to Central Administration -> Application Management -> Manage content databases, and remove the current database of the newly created Web application:

  • Select the Remove content database checkbox. Click the OK and Save buttons:

  • After you have removed the content database, Content Database should show that “There are no items to show in this view,” as pictured below:

3.   Restore your database to the SharePoint 2013 server:

  • Copy the WSS_Content.bak file in the SharePoint 2010 Server to your SharePoint 2013 Server. Select your source and destination as follows:

  • Open SQL Server 2008 in SharePoint 2013 Server, right-click the Database node, and select Restore Database:

  • Input the Database Name and select the From device radio button:

  • Browse to the .bak file which you copied from SharePoint 2010 Server in SharePoint 2013 Server (in this example, we are using the file WSS_Content.bak):

  • Click OK:

  • Select the Options tab. Next select the Overwrite the existing database checkbox. Click OK:

  • A dialog box will appear that states that your restore was successful:

4.    Verifying the content database:

Launch the SharePoint 2013 Management Shell and type this command:

Test-SPContentDatabase -Name <database name> -WebApplication <URL>

For example:

Test-SPContentDatabase -Name WSS_Content_88 -WebApplication http://chauo15sql:88

5.    Add the restored content database to the new Web application (port 88):

Run the stsadm command line as shown below:

  • cd “C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\15\BIN\”

stsadm.exe -o addcontentdb -url <URL> -databasename <database name>

For example:

stsadm .exe-o addcontentdb -url http://chauo15sql:88-databasename WSS_Content_88

  • After the upgrade has completed successfully, go back to Central Administration -> Application Management -> Manage content databases, and under your content databases, you will now see the upgraded database listed under your designated Web Application:

  • Go to the SharePoint 2013 site. By default, your site will retain the SharePoint 2010 theme. You will need to manually change this for 2013. This can be done by following these steps:

1.    Click on the Start now hyperlink at the top of the site:

2.    Click on the Upgrade this Site Collection button:

3.    Click on I’m ready:

4.    Once the upgrade has completed (FYI – this may take a few minutes), a dialog box will appear to let you know that the upgrade completed successfully:

5.    Rest assured that if you see the error message below in regards to your Bamboo Products that you were successful in completing the steps above! But wait, there’s more….

6.    Before your Bamboo Products are installed on your SharePoint 2013 Server, you will need to have accepted the terms and conditions presented in the End-User Software License Agreement:

7.    Once accepted, your installation is complete!  You will see that now all of your Bamboo Products are activated in Site Collection Features and it’s back to business as usual!

 

Refernce : http://skdeveloper.wordpress.com/2014/09/28/back-up-a-content-database-from-sharepoint-2010-and-restore-it-to-sharepoint-2013/

Troubleshoot SharePoint Service Application \ Website issue from IIS

Topic details:

Today we will understand and troubleshoot more about SharePoint Service Application outside of SharePoint Central Admin. I came across multiple Forum issues who face service application issue but cannot troubleshoot it from IIS. Now this is an article which will help us understand more about issues and troubleshoot it.

 

Service Application and its properties in IIS:

Click Start > Run >Type “Inetmgr” > click ok > It will open the IIS screenshot for you.

0046

Expand server you will see:

Application Pool : Application pools allow you to isolate your applications from one another, even if they are running on the same server. This way, if there is an error in one app, it won’t take down other applications. Additionally, applications pools allow you to separate different apps which require different levels of security.

Sites:  These are Virtual Directory which actually hosts the HTML, ASPX, etc files which will be accessed by users.

0047

Lot of times users see some error message in ULS logs which refer to a service URL which is either timed out or some wired issue. Let check more about the URL’s we seen in those ULS Logs.

When you expand Site > “SharePoint Web Services”, you will see number of Virtual Directories. These are service applications connection used by SharePoint

0048

Now let us check which GUID belong to which Service Application. To do so we will click on each GUID and select Content view on bottom page. Here we see GUID “4ae5be2ba3ad4452826c338528a0aca3” is hosting Search Admin service.

0049

Similarly we can see GUID “c9f7fec2839a4e5c8056d4f30e00b8ea” host App management service and “ef2a78b8e67747e9aaeb708ae0230e5e” host WorkManagementService and so on.

 

0050

0051

 

We can check the Application Pool used by these services. To do so let’s right click on GUID > Manage Application > Advance Settings

0052

Here we can see the Application Pool used by GUID and physical path of the service files.

0053

We can Browse the service by clicking on any .svc file > select browse. This help us to understand if the service is working fine.

0054

If we get a screen with below metadata, it means it is working fine. If we see any error on any of them, then we need to troubleshoot that issue.

0055

To check Application Pool datails of the website we will go to Application pool screen and select the Application Pool > Right click > Select Advance settings. You would notice the .net framework version, identity (account used by application pool) and other IIS setting of that application pool

0056

Incase if the Application pool is stopped we need to start it. Application pool may stop due to password change of account used in identity, IISReset, etc

0057

 

 

Some Basic troubleshooting steps:

  1. Create DisableLoopbackCheck registry on all SharePoint servers.
  • Click Start, click Run, type regedit, and then click OK.
  • In Registry Editor, locate and then click the following registry key:
  • HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa
  • Right-click Lsa, point to New, and then click DWORD Value.
  • Type DisableLoopbackCheck, and then press ENTER.
  • Right-click DisableLoopbackCheck, and then click Modify.
  • In the Value data box, type 1, and then click OK.

 

  1. Sometimes some Application pool properties are edited. One of them is support for 32 but application. Make sure it is always set to False for all SharePoint Application pool. You need to go to IIS Manager > Application Pool > Select Application Pool > Advanced Settings > set “Enable 32-bit applications” to “False”.

0058

  1. If password used in Application pool account is changed, you may go to IIS Manager > Application Pool > Select Application Pool > Identity > Click on … near Application Pool username > Update the password for the application pool

0059

0060

  1. Make sure Application pool account is present in WSS_WPG and WSS_ADMIN_WPG

0062

  1. I see a lot of time that IIS Hardening done by Windows admin cause this issue. Make sure that if you get an error e.g. 401, enable advance logging and check the exact error code like 401.1, 401.2, etc. This will help you troubleshoot issue. In below screenshot you can see all of them have a different reasoning.

0063

 

  1. Last but not least enable IIS logging. Logging specific details from IIS is the most important step

Select the web application > Select “Failed Request Tracing” on right pane >Enable the tracing.

0064

Just by enabling you will not see the log files, now you will have to configure Error code. Again select Web Application > Select “Failed request tracing rules” > Select Add >Select All content > In Status code type 401(If you have something else you can put that) > Next > Finish. Now you will be able to see all failed request.

0066

 

  1. I some cases I have seen that due to antivirus or some other reason Application Pool account does not have permission on C:\InetPub folder. Make sure we have proper permission on Inetpub folder for service account and Application pool account.

0067

During SharePoint Solution deployment or if we make any changes to IIS setting, it will generate a new web.config file. If we get some web.config errors, use tools like examdiff to check difference between old web.config and new web.config. This will help you narrow down issue track changes done in web.config. It is not recommended to modify any web.config unless necessary. Web.config should be in C:\inetpub\wwwroot\wss\VirtualDirectories\IIS site\ folder

0068

Hope this was helpful to you all.

SharePoint search when browse Content Source, crawl log, etc I get error “The remote procedure call failed” (Exception from HRESULT: 0x800706BE)

Issue: Today I faced a weird issue that when I try to browse my Content Source, crawl log, etc I get error “The remote procedure call failed” (Exception from HRESULT: 0x800706BE). On Search admin page I could see All Error.

0042

0035

Analysis: 

  • I ULS Log file I got below error :

The gatherer object cannot be initialized. Context: Application ‘Search_Service_Application’, Catalog ‘Portal_Content’ Details: Access is denied. (0x80070005)
The application cannot be initialized. Context: Application ‘Search_Service_Application’ Details: Access is denied. (0x80070005)
pplication error when access /_admin/search/CrawlLogContentSources.aspx, Error=The remote procedure call failed. (Exception from HRESULT: 0x800706BE) at Microsoft.Office.Server.Search.Internal.UI.SearchCentralAdminPageBase.ErrorHandler(Object sender, EventArgs e) at Microsoft.Office.Server.Search.Internal.UI.SearchCentralAdminPageBase.OnError(EventArgs e) at System.Web.UI.Page.HandleError(Exception e) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest() at System.Web.UI.Page.ProcessRequest(HttpContext context) at System.Web.HttpApplication.CallH…
System.Runtime.InteropServices.COMException: The remote procedure call failed. (Exception from HRESULT: 0x800706BE) at Microsoft.Office.Server.Search.Internal.UI.SearchCentralAdminPageBase.ErrorHandler(Object sender, EventArgs e) at Microsoft.Office.Server.Search.Internal.UI.SearchCentralAdminPageBase.OnError(EventArgs e) at System.Web.UI.Page.HandleError(Exception e) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest() at System.Web.UI.Page.ProcessRequest(HttpContext context) at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.Htt… 8037bb9c-5f8c-d098-ef4d-e03a32dc9bf8
09/23/2014 12:25:37.81* w3wp.exe (0x3490) 0x2784 SharePoint Foundation Runtime tkau Unexpected …pApplication.IExecutionStep.Execute() at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

The gatherer object cannot be initialized. Context: Application ‘Search_Service_Application’, Catalog ‘Portal_Content’ Details: Access is denied. (0x80070005)
The application cannot be initialized. Context: Application ‘Search_Service_Application’ Details: Access is denied. (0x80070005)
pplication error when access /_admin/search/CrawlLogContentSources.aspx, Error=The remote procedure call failed. (Exception from HRESULT: 0x800706BE) at Microsoft.Office.Server.Search.Internal.UI.SearchCentralAdminPageBase.ErrorHandler(Object sender, EventArgs e) at Microsoft.Office.Server.Search.Internal.UI.SearchCentralAdminPageBase.OnError(EventArgs e) at System.Web.UI.Page.HandleError(Exception e) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest() at System.Web.UI.Page.ProcessRequest(HttpContext context) at System.Web.HttpApplication.CallH…
System.Runtime.InteropServices.COMException: The remote procedure call failed. (Exception from HRESULT: 0x800706BE) at Microsoft.Office.Server.Search.Internal.UI.SearchCentralAdminPageBase.ErrorHandler(Object sender, EventArgs e) at Microsoft.Office.Server.Search.Internal.UI.SearchCentralAdminPageBase.OnError(EventArgs e) at System.Web.UI.Page.HandleError(Exception e) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest() at System.Web.UI.Page.ProcessRequest(HttpContext context) at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.Htt… 8037bb9c-5f8c-d098-ef4d-e03a32dc9bf8
09/23/2014 12:25:37.81* w3wp.exe (0x3490) 0x2784 SharePoint Foundation Runtime tkau Unexpected …pApplication.IExecutionStep.Execute() at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

Getting Error Message for Exception System.Runtime.InteropServices.COMException (0x800706BE): The remote procedure call failed. (Exception from HRESULT: 0x800706BE) at Microsoft.Office.Server.Search.Internal.UI.SearchCentralAdminPageBase.ErrorHandler(Object sender, EventArgs e) at Microsoft.Office.Server.Search.Internal.UI.SearchCentralAdminPageBase.OnError(EventArgs e) at System.Web.UI.Page.HandleError(Exception e) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest() at System.Web.UI.Page.ProcessRequest(HttpContext context) at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()     at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

0036

 

  • In Event Viewer I got below error:

1. Event Log

Log Name: Application
Source: Microsoft-SharePoint Products-SharePoint Server Search
Date: 9/23/2014 1:14:21 PM
Event ID: 1311
Task Category: Crawler:Gatherer Plugin
Level: Error
Keywords:
User: domain\user
Computer: computer.domain.com
Description:
The gatherer object cannot be initialized. Context: Application ‘Search_Service_Application’, Catalog ‘Portal_Content’ Details: Access is denied. (0x80070005)

Log Name: Application
Source: Microsoft-SharePoint Products-SharePoint Server
Date: 9/23/2014 1:14:08 PM
Event ID: 6482
Task Category: Shared Services
Level: Error
Keywords:
User: domain\user
Computer: computer.domain.com
Description:
Application Server Administration job failed for service instance Microsoft.Office.Server.Search.Administration.SearchServiceInstance (7041cac9-78a8-4e9d-9b68-7fd58e549e36).
Reason: The remote procedure call failed. (Exception from HRESULT: 0x800706BE)
Technical Support Details:
System.Runtime.InteropServices.COMException (0x800706BE): The remote procedure call failed. (Exception from HRESULT: 0x800706BE)
at Microsoft.Office.Server.Search.Administration.MSSITLB.IGatherManagerAdmin3.get_ConfigurationVersion()
at Microsoft.Office.Server.Search.Administration.Gatherer.ProvisionGlobalProperties()
at Microsoft.Office.Server.Search.Administration.SearchServiceInstance.Synchronize()
at Microsoft.Office.Server.Administration.ApplicationServerJob.ProvisionLocalSharedServiceInstances(Boolean isAdministrationServiceJob)

2. Event Log

Log Name: Application
Source: Application Error
Date: 9/23/2014 1:14:21 PM
Event ID: 1000
Task Category: (100)
Level: Error
Keywords: Classic
User: N/A
Computer: computer.domain.com
Description:
Faulting application name: OWSTIMER.EXE, version: 15.0.4420.1017, time stamp: 0x50674330
Faulting module name: clr.dll, version: 4.0.30319.18063, time stamp: 0x526767d0
Exception code: 0xc00000fd
Fault offset: 0x0000000000004823
Faulting process id: 0x29c
Faulting application start time: 0x01cfd7021e388d0f
Faulting application path: C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\15\BIN\OWSTIMER.EXE
Faulting module path: C:\Windows\Microsoft.NET\Framework64\v4.0.30319\clr.dll
Report Id: 6de8ab5a-42f5-11e4-b954-1078d249c51f

3. Event Log

Log Name: Application
Source: .NET Runtime
Date: 9/23/2014 1:14:21 PM
Event ID: 1026
Task Category: None
Level: Error
Keywords: Classic
User: N/A
Computer: computer.domain.com
Description:
Application: mssearch.exe
Framework Version: v4.0.30319

Description: The process was terminated due to an unhandled exception.
Exception Info: exception code c0000005, exception address 000007FEBE7EFCAC

4. Event Log

Log Name: Application
Source: Application Error
Date: 9/23/2014 1:14:21 PM
Event ID: 1000
Task Category: (100)
Level: Error
Keywords: Classic
User: N/A
Computer: computer.domain.com
Description:
Faulting application name: mssearch.exe, version: 15.0.4420.1017, time stamp: 0x50674115
Faulting module name: MSSrch.dll, version: 15.0.4420.1017, time stamp: 0x50674168
Exception code: 0xc0000005
Fault offset: 0x00000000000efcac
Faulting process id: 0x2d48
Faulting application start time: 0x01cfd7022f675638
Faulting application path: C:\Program Files\Microsoft Office Servers\15.0\Bin\mssearch.exe
Faulting module path: C:\Program Files\Microsoft Office Servers\15.0\Bin\MSSrch.dll
Report Id: 6e18e456-42f5-11e4-b954-1078d249c51f

5. Event Log

Log Name: Application
Source: Windows Error Reporting
Date: 9/23/2014 1:14:22 PM
Event ID: 1001
Task Category: None
Level: Information
Keywords: Classic
User: N/A
Computer: computer.domain.com
Description:
Fault bucket , type 0
Event Name: APPCRASH
Response: Not available
Cab Id: 0

Problem signature:
P1: mssearch.exe
P2: 15.0.4420.1017
P3: 50674115
P4: MSSrch.dll
P5: 15.0.4420.1017
P6: 50674168
P7: c0000005
P8: 00000000000efcac
P9:
P10:

Attached files: These files may be available here: C:\ProgramData\Microsoft\Windows\WER\ReportQueue\AppCrash_mssearch.exe_ad41854ae647fa879c781a7c75bbda4cb9d73d74_614ef624

Analysis symbol:
Rechecking for solution: 0
Report Id: 6e18e456-42f5-11e4-b954-1078d249c51f
Report Status: 4

Found all search services are started in Central admin

0037

Service “Sharepoint server search 15 service” was stopped so tried to start “Sharepoint server search 15 service” from services.msc console got error

Windows could not start the SharePoint Server Search 15 service on computername.
Error 1067: The process terminated unexpectedly

0038

 

Did not find any issue with Search Topology

0039

 

Got Upgrade available in Central admin. So planned to update the server by running PSconfig wizard.

0040

 

Troubleshooting steps followed:

Open SharePoint PowerShell as administrator and run below:

psconfig -cmd upgrade inplace b2B wait

Got below error

SharePoint Products Configuration Wizard version 15.0.4420.1017. Copyright (C) Microsoft Corporation 2012. All rights reserved.
Performing configuration task 1 of 4
Initializing SharePoint Products upgrade…
Waiting to get a lock to upgrade the farm.
Successfully initialized the SharePoint Products configuration.
Performing configuration task 2 of 4
Initiating the upgrade sequence…
Successfully initiated the upgrade sequence.
Performing configuration task 3 of 4
Upgrading SharePoint Products…
Failed to upgrade SharePoint Products.
An exception of type Microsoft.SharePoint.Administration.SPUpdatedConcurrencyException was thrown. Additional exception information: An update conflict has occurred, and you must re-try this action. The object SPUpgradeSession Name=Upgrade-20140923-132412-856 was updated by domain\user, in the PSCONFIG (8960)process, on machine computername. View the tracing log for more information about the conflict.
Total number of configuration settings run: 3
Total number of successful configuration settings: 2
Total number of unsuccessful configuration settings: 1
Successfully stopped the configuration of SharePoint Products.Configuration of SharePoint Products failed. Configuration must be performed before you use SharePoint Products. For further details, see the diagnostic log located at C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\15\LOGS\PSCDiagnostics_9_23_2014_13_23_25_265_114189745.log and the application event log.

In SharePoint powershell ran “IISReset” and above command. Still got same error

Reboot the server and tried above command. Still got same error

 

Solution I found

In SharePoint powershell tried below command:

PSConfig.exe -cmd upgrade -inplace b2b -force -cmd applicationcontent -install -cmd installfeatures

Now I got below message:

10.00% : Failed to start service SearchServiceInstance on this server after completing upgrade. Please start it manually.

Successfully upgraded SharePoint Products.

Performing configuration task 6 of 6
Finalizing the SharePoint Products configuration…

Tried to run SharePoint Products and configuration wizard from UI and now search service was started.

0043

Confirmed that search is also working fine.

0042

0041

 

Also I don’t have the upgrade error anymore

0044

 

Common issue when using SharePoint 2013 Multi Tenant environment (Apps and User Profile Synchronization)

Scenario :  When using SharePoint 2013 Multi Tenant environment you may come across multiple issue. Below are very important and commons issue I have troubleshoot till date.

Issue 1 : When users try to access SKYdrive and Newsfeed. Get below error message:
Error : Exception occurred loading user profile (/mysite/default.aspx): System.ArgumentNullException: Value cannot be null.  Parameter name: userProfileApplicationProxy

Solution:
Here the site subscription is not added to the tenant site. To resolve the issue we need to follow below steps:

$sub = get-spsitesubscription “yourGUID”;
$site = get-spsite “https://youronedrivesite.yourdomain.com/personal/user”
set-spsite -identity $site -SiteSubscription $sub

Issue 2 : When users try to add app to their SharePoint site. they get below error:
Error : “apps are turned off if you know who runs the server tell them to enable apps”

Solution:
Every Tenant Admin will require a new App Catalog. It is different from app catalog created in central admin(Make sure Self site creation is enabled in order for App Catalog to get created)

$Sub = Get-SPSiteSubscription http://hhmodeSite (This CMDlet will help in fetching the subscription ID of the HH mode site collection)
Set-SPAppSiteSubscriptionName -Name “Name for Subscription” -SiteSubscription $Sub

We need to run the above command in order to set the unique name for domain under which these apps will run.More details can be found under http://technet.microsoft.com/en-us/library/jj219503.aspx

Issue: How to check which Active Directory OU is assigned to which Site Collection

Solution :
Normally you can see the details of each site collection using below:
Get-SPSiteSubscription –Identity http://hosted-site-URL

If you want to see details of all tenant at once, try below:
– In “Your_Tenant_Profiles_Service_ProfileDB” run below query

SELECT TOP 1000 [CanonicalMySitePortalUrl],[SynchronizationOU]
FROM [Your_Tenant_Profiles_Service_ProfileDB].[dbo].[Tenants]

 

Reference:
http://blogs.technet.com/b/harmeetw/archive/2013/01/03/sharepoint-2013-you-receive-quot-sorry-apps-are-turned-off-if-you-know-who-runs-the-server-tell-them-to-enable-apps-quot-when-trying-to-add-apps-on-host-header-site-collection.aspx
http://social.technet.microsoft.com/Forums/office/en-US/a04a9163-1f9d-4519-891e-4d6ca8d9528a/setup-mysites-in-a-multitenant-sp2013-farm?forum=sharepointadmin#98a30156-a4ca-46f6-bf1a-47d08f54013d

 

SharePoint 2013 and 2010 : The trial period for this product has expired

You cannot extend the trial. You can license the full product by getting a paid-for license key, then in Central Administration > Upgrade and Migration > Convert Farm License Type. Enter the  product key > Upgrade. Now the license and expiration date are held within the Configuration database, the only way to “extend” a trial is to rebuild the farm from scratch.

Or you can follow below unsupported method.

There is a way we can modifying your SQL Server databases. This is an unsupported method so make sure you backup your config database first before continuing.

To do so follow below steps > Open SQL server management studio > connect your SQL instance.

0029

 

Right click your configuration database (Which by default should be ‘SharePoint_Config’ ) > Select “New Query” on top.

0030

 

0031

 

Copy paste below query in the new query window

0032

UPDATE Objects
SET Properties = Replace(Properties, 9223372036854775807, 92233720368547758)
WHERE ClassId = ‘4274DBC4-7D52-474F-961B-58D84F5C28FF’

 

Execute this query from top.

0033

Now go to Central Administration > Upgrade and Migration > Convert farm license type. You should be able to input your new Product Key now and hit OK.

Capture8

 

Sharepoint 2010 & 2013 issue : The solution cannot be deployed. The feature “” uses the directory “” in the solution. However, it is currently installed in the farm to the directory “”. Uninstall the existing feature before you install a new version of the solution

I get this error when I try to deploy a solution from Visual Studio or user Powershell Add-SPSolution it is a very old issue related to deploying solution. Error message:

The solution cannot be deployed. The feature
‘ea6dd247-b625-4544-bcaa-b944fd2ca448’ uses the directory “feature01” in the solution. However, it is currently installed in the farm to the directory “customfeature1”. Uninstall the existing feature before you install a new version of the solution.

 

Tried to use remove-SPsolution but no luck

Remove-SPSolution -Identity “customfeature1.wsp” -force   (got below error)

Outcome :  Remove-SPSolution : Cannot find an SPSolution object with Id or Name: customfeature1.wsp

Tried below command but still no luck

Remove-SPSolutionDeploymentLock

 

Tried to run below command but still same issue

Uninstall-SPFeature “ea6dd247-b625-4544-bcaa-b944fd2ca448” -force

Outcome : Uninstall-SPFeature : Cannot find a Feature object with Path or Id:
ea6dd247-b625-4544-bcaa-b944fd2ca448 in scope Local farm.

 

Now I tried below command and got message “Operation completed successfully”. But i was still facing same issue:

stsadm -o uninstallfeature -id “ea6dd247-b625-4544-bcaa-b944fd2ca448” -force

Outcome : Operation completed successfully

 

Finally I opened solution in visual studio and remove the feature “feature01” from features folder and tried to deploy solution. This time I was able to deploy solution without any issue.

Now again I added the “Feature01” to features list and was able to deploy the solution with same feature.

 

If you face the same issue with a Timerjob installed in farm. Above steps will not help you resolve the issue. You need to follow below:

  • Navigate to Central Administration
  • Then Operations > Timer Job definitions
  • Find you timer job from the list and click to open the page
  • Copy the JobId from URL eg: http://MyServer:123/_admin/JobEdit.aspx?JobId=XXX-XXX-XXX-XX)
  • Copy to NotePad and replace the %2D characters by a dash “-“
  • Then Open Sharepoint Powershell command window and use below command:

stsadm.exe -o deleteconfigurationobject -id <ObjectGUID>

Missing server side dependencies on SharePoint 2010 and SharePoint 2013

Sample error message in SharePoint Health Analyzer.

Title Missing server side dependencies.
Severity 1 – Error
Category Configuration
Explanation

[MissingSetupFile] File [Features\Customfeature.SharePoint\feature1\feature.webpart] is referenced [1] times in the database [WSS_Content], but is not installed on the current farm. Please install any feature/solution which contains this file. One or more setup files are referenced in the database [WSS_Content], but are not installed on the current farm. Please install any feature or solution which contains these files.

[MissingWebPart] WebPart class [0e293c29-9caf-6fec-3c02-43e65bdf420d] (class [Customfeature] from assembly [SOMECustomapp, Version=1.0.0.0, Culture=neutral, PublicKeyToken=539e3b144bfb558e1]) is referenced [1] times in the database [WSS_Content], but is not installed on the current farm. Please install any feature/solution which contains this web part. One or more web parts are referenced in the database [WSS_Content], but are not installed on the current farm. Please install any feature or solution which contains these web parts.

[MissingWebPart] WebPart class [28c23aec-2537-68b3-43b6-845b13cea19f] is referenced [5] times in the database [SharePoint_AdminContent_2de70b74-66e7-4c03-9135-e4e7bd6f0491], but is not installed on the current farm. Please install any feature/solution which contains this web part. One or more web parts are referenced in the database [SharePoint_AdminContent_2de70b74-66e7-4c03-9135-e4e7bd6f0491], but are not installed on the current farm. Please install any feature or solution which contains these web parts.
Remedy For more information about this rule, see “http://go.microsoft.com/fwlink/?LinkID=142689”.
Failing Servers Server1, Server2
Failing Services SPTimerService (SPTimerV4)
Rule Settings View

 

Points to notice in above issue:

  1. It will mention the server where this issue was observed. Keep a note of those servers. If it is a single server installation, it might not give names.

Lot of time type of installation done on server and IIS feature enabled on site cause this issue. A workaround to resolve the issue to open web.config on all servers and match it. Make sure they are same on all servers.

  1. Most important you need to note the name of custom features(e.g. [Features\Customfeature.SharePoint\feature1\feature.webpart]) mentioned above.

We should see details of this feature in the content database name associated with feature. To verify same open SQL management studio > connect to SQL server > Expand databases > expand content datbase(e.g. WSS_Content) > Tables > Now right click on dbo.FeatureTracking > Select top 1000 rows > You should see all the feature name and Feature is mentioned here.

To know more details of webpart run below code on SQL content database

SELECT tp_WebPartTypeId, COUNT(1), tp_Assembly, tp_Class FROM AllWebParts
 
 (NOLOCK) WHERE tp_WebPartTypeId IS NOT NULL AND tp_SolutionId IS NULL
 
 GROUP BY tp_WebPartTypeId, tp_Assembly, tp_Class
  1. In another issue you will see only Feature ID and not feature name(e.g. [MissingWebPart] WebPart class [28c23aec-2537-68b3-43b6-845b13cea19f]). Here you can refer below article and check if you are able to find the feature id:

SharePoint 2013 Feature ID with Feature Name

If you see the feature ID in this list, it means it was once activated on some site in this database but it is now deactivated. May be somewhere on some page, the webpart related to that feature is still present which is causing this issue. You need to find that page and remove the webpart from that page or reactivate the feature.

 

  1. Lot of time we will see this issue for Admin content database as shown below.

[MissingWebPart] WebPart class [28c23aec-2537-68b3-43b6-845b13cea19f] is referenced [5] times in the database [SharePoint_AdminContent_2de70b74-66e7-4c03-9135-e4e7bd6f0491],

They are actually search webpart. To validate the same run below query on SQL server:

use [SharePoint_AdminContent_GUID]
select DirName,LeafName from dbo.AllDocs where id in
 (select tp_PageUrlID from dbo.AllWebParts where
 (tp_WebPartTypeID='28c23aec-2537-68b3-43b6-845b13cea19f')
 )
go

Resolutions are:

  • Normally issue is resolved when simply re-analyzing.
  • Browsing to the pages may help
  • Some article state it was a bug in SharePoint 2010.

 

5.Now if the above feature is a Custom solution:

  • If you don’t have that custom solution with you. then I would suggest you to simply ignore the issue.
  • If you have the solution then you can deploy the solution in farm and deactivate the feature in farm and then remove the solution from farm.

 

Once above steps are performed reanalyze and check for error

  1. In Central Administration, navigate to: CA > Application Management > Manage Service Applications > Search Service Application > Manage.  This takes you to the SearchAdministration page.
  2. Next, navigate to: CA > Application Management > Manage Service Applications > Search Service Application > Manage > Farm Search Administration.  This takes you to the SearchFarmDashboard page.
  3. Then, navigate to: CA > Monitoring > Health Analyzer > Review problems and solutions.
  4. Click the issue link, click Reanalyze Now, and then click Close.
  5. Wait a few minutes, and then refresh the page.