Error occurred in deployment step ‘Recycle IIS Application Pool’: Remote SharePoint site connections are not supported


Problem/Error:

I have a SharePoint 2016 On-premises farm. I got bellow error while I am deploying a SharePoint 2016 solution with Visual Studio 2017

Error occurred in deployment step ‘Recycle IIS Application Pool’: Remote SharePoint site connections are not supported

Solution:

  • Edit the hosts file located at ‘C:\Windows\System32\drivers\etc’ folder
  • Place site collections URL pointing at 127.0.0.1    Lets say my SharePoint site collection URL is http://spportal.abc.com

  • Save and Close. Then retry to deploy again.

An attempt to communicate with Azure DevOps failed because a token could not be retrieved. Please re-enter your credentials.


Problem: Few days ago I have alias my office account/email address and after that I can not login to Azure Devops/VSTS from Visual Studio 2017 & 2019. When I was trying to login it is asking my credentials several times but after that I got below error message
An attempt to communicate with Azure DevOps failed because a token could not be retrieved. Please re-enter your credentials.

Solution: I just deleted the .IdentityService folder from %LOCALAPPDATA%

Reference : https://stackoverflow.com/questions/52261545/how-do-i-connect-to-my-teamproject-after-i-changed-my-primary-account-alias