When I tried to deploy a SharePoint Solution, I got the following error:
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 Visual Studio is not running as Administrator.
- The current user is not a site collection Administrator.
- The SQL Server service is not running.
- The SharePoint web application pool is stopped.
- The SharePoint web application pool Account is locked.
- The current user (the user used to run visual studio and deploy your solution) didn’t have ‘db-owner on
- Content Database.
- SharePoint Config database.
- 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.
SQL Server service is not running:
Application Pool is stopped:
- Open IIS Manager
- Select your application pool of your web application
- Click advanced settings
- Under identity click to reset the application pool account
- Click set to update the user name and password of your account
- Run IISRESET command.
The current logged-in user may not be the “db owner” on the content databases.:
- Content Databases of your web application that you need to deploy your solution.