The local SharePoint server is not available Check that the server is running and connected to the SharePoint farm.

The local SharePoint server is not available Visual Studio 2017

In this post, we’ll fix “The local SharePoint server is not available in Visual Studio 2017 / 2015 /2013

An error occurred in deployment step ‘Recycle IIS Application Pool’: The local SharePoint server is not available. Check that the server is running and connected to the SharePoint farm.

The local SharePoint server is not available Check that the server is running and connected

You might also like to read This operation can be performed only on a computer that is joined to a server farm by users who have permissions in SQL Server to read from the configuration database


The local SharePoint server is not available Check that the server is running and connected

The root cause of this issue might be one of the following:

  1. The Visual Studio is not running as Administrator.
  2. The current user is not a site collection administrator.
  3. The SQL Server service is not running.
  4. The SharePoint web application pool is stopped.
  5. The SharePoint web application pool account is locked.
  6. The current user (the user used to run visual studio and deploy your solution) didn’t have ‘db-owner’ role on
    • Content Database.
    • SharePoint_Admin.
    • SharePoint Config database.
  7. The SharePoint web application pool account didn’t have the following role:
    • db-owner‘ and ‘SP_DATA_ACCESS’ on Content Database.
    • WSS_CONTENT_APPLICATION_POOLS‘ on SharePoint_Admin.
    • WSS_CONTENT_APPLICATION_POOLS‘ on SharePoint Config database.

[Solved] The local SharePoint server is not available Visual Studio 2017 / 2015 / 2013

Running Visual Studio as Administrator

If you didn’t run Visual Studio as an administrator, you may get “The local SharePoint server is not available” error.

An error occurred in deployment step ‘Recycle IIS Application Pool’: The local SharePoint server is not available

Therefore, you should run Visual Studio as an Administrator as mentioned below:

Open Visual Studio as Administrator

You may be also like to read Visual Studio requires the application to have elevated permissions.


The current user should be a site collection administrator

Make sure that the current user that runs the Visual Studio is a site collection administrator.

  • Open your SharePoint site.
  • Go to site settings.
  • Below “Users and Permissions“, click on “Site Collection Administrators“.
  • If the current user is not added at “Site Collection Administrators“, try to add it.
Site collection administrator in SharePoint

SQL Server service must be up and running

Make sure that the SQL Server service is up and running properly.

  • Open “Services”.
  • Search for “SQL Server”.
  • Make sure the “SQL Server” service state is running.
SQL Server Service Failed to Start

You may also like to read Unable to start SQL Server service


The SharePoint web application pool account should be unlocked

Make sure that the application pool account of the SharePoint site is unlocked in Active Directory.

The SharePoint web application pool Account is locked.

The SharePoint Application Pool is started

Make sure that the SharePoint Application Pool is running.

  • If it’s started try to restart it.
  • If it is not started properly that means the credential of the current application pool identity has been changed but it’s not reflected on the IIS.
Set Application Pool Identity
  • Open IIS Manager.
  • Select the application pool of your web application.
  • Click on “Advanced settings”.
  • Under identity click to reset the application pool account.
  • Click set to update the username and password of your account.
  • Restart Application pol that should be now started properly.
Change the identity Application pool in IIS

Database permission required to deploy SharePoint Solution

To deploy the solution successfully, you need to map the currently logged-in user as db_owner into the below three databases.

  • SharePoint_Config
  • SharePoint_Admin_[GUID]
  • All Content Databases of your web application that you need to deploy your solution.
content database permissions to deploy SharePoint Solution

You might also like to read SQL Server Best Practices for SharePoint 2019.


Database permission required for SharePoint Application Pool Account

The Application Pool account that runs SharePoint Web Application should have the below database permissions:

  • db-owner‘ and ‘SP_DATA_ACCESS on all web application Content Databases.
Configuration database permissions for SharePoint Application Pool
  • WSS_CONTENT_APPLICATION_POOLS‘ on the SharePoint Config database.
  • WSS_CONTENT_APPLICATION_POOLS‘ on the SharePoint_Admin database.
content database permissions for SharePoint Application Pool

Active Directory permission required for SharePoint Application Pool Account

Make sure that the application pool account is a member of WSS_WPG.

the application pool account is a member of WSS_WPG

Applies To
  • SharePoint 2016.
  • SharePoint 2013.
Conclusion

In conclusion, we have fixed the SharePoint Deployment issue “An error occurred in deployment step ‘Recycle IIS Application Pool’: The local SharePoint server is not available. Check that the server is running and connected to the SharePoint farm.“.

Additionally, we have explored the required database permission for the SharePoint Application pool account.

You may also like to read
Have a Question?

If you have any related questions, please don’t hesitate to Ask it at deBUG.to Community.

6 thoughts on “The local SharePoint server is not available Check that the server is running and connected to the SharePoint farm.”

  1. Pingback: SharePoint: 500 Internal Server Error | SPGeeks

Leave a Reply