Ghosts in the Azure DevOps machine

0

Whilst preparing to present an Azure DevOps based training day at SQLBits I encountered an interesting problem, which I nicknamed ‘Ghosts in the Azure DevOps machine’. Mostly due to the theme of this year’s SQLBits conference which was classic arcade games.

For our training day I had setup an Azure DevOps organization and setup the billing before the event. So that we could add all the attendees to the same Azure DevOps organization.

We wanted to add all the attendees to the same organization so that they could view the Data Platform projects we had in place. Plus, the special Wiki that we had setup for them, included various exercises.

In addition, I decided not to add the organization to an Azure Active Directory. So that we could cleanly remove users afterward.

401 error

What should happen when you add a new user in Azure DevOps is that when you add a new user, they get an email. From there they click on the link in the email and join the new organization.

However, whilst testing adding new users before our training day, we discovered that some of them got a 401 error when they clicked on the link in the email to join the organization. Like the one below.

At first, I found it frustrating as there did not appear to be a set pattern. It worked for some accounts and not others.

Whilst waiting for a response from Microsoft I kept on investigating. After a while I found out that there were two potential fixes for this. One for those with personal accounts and one for those with work accounts.

Because it took me a while to figure this out, I have decided to share these fixes in this post to help others.

Ghosts in the Azure DevOps machine for personal accounts

If you get the 401 error whilst using a personal email account for Azure DevOps follow the below steps:

  1. Open up Azure DevOps as normal in one tab, then in another new tab and type in URL for the organization which you want to join. For example, https://dev.azure.com/{ORGANIZATION NAME}.
  2. When you get the 401 error go back into your original tab click on your account manager in the top right-hand corner. Select ‘Switch Directory‘.
  1. Afterwards, select the first ‘Default Directory’ entry that you see.
  1. If it says ‘Welcome to Azure DevOps’ ignore that screen. Instead, go to your new tab that has the URL of the new organization and press ‘Refresh’. Your new organization should appear.
  2. If the above steps do not work then repeat the above steps with any other Default Directories your account has access to until it works.

Ghosts in the Azure DevOps machine for work accounts

If you get the 401 error whilst using a personal email account for Azure DevOps follow the below steps:

  1. Open up Azure DevOps in Private/Incognito mode.
  2. Enter the https://dev.azure.com and log back into Azure DevOps.
  3. If the new organization does not appear on the left-hand side straight away open up a new tab and enter the URL for the new organization. For example, https://dev.azure.com/{ORGANIZATION NAME}. You should then have access to your new organization.

Final words

I hope my tips on how to fix ‘Ghosts in the Azure DevOps machine’ helps some of you.

In addition, I would like to personally thank Sander Stad, Kay Cordewener and Gregor Suttie for helping me test the issues with personal and work accounts. Without these tests, I would never have figured out how to resolve these two separate issues before SQLBits.

On that note, those who attended our SQLBits training day will be pleased to know that I have now uploaded the slides. So that the SQLBits team can make them available,

Of course, if you have any comments or queries about this post feel free to reach out to me.

Please note – This blog was originally published on my personal blog here.

Kevin Chant

About

Lead BI & Analytics Architect originally from the UK and now living in the Netherlands. Currently Microsoft Data Platform MVP and Microsoft Certified Trainer Alumni. Many years experience in the IT sector, and has supported databases for companies in the top 10 of the fortune 500 list. In addition to a lot of Data Platform experience also has a fair few Microsoft Certifications, and was probably the last ever person in the world to gain the MCSD Azure Architect certification. Real life experience with Microsoft Data Platform and Azure Devops. Previously SQL Server Product Owner of around 1,900 instances. In addition, done various things for the Data Platform Community. With one of the last being one of the organizers of the online DataWeekender conference.

More on Kevin Chant.

Related Posts

Your email address will not be published.