Tag Archives: PowerShell

Azure automation FTW!

Published by:

Azure automation is, in my opinion, one of the heavily underrated offerings in the Microsoft Azure platform. During my time at Microsoft I had the opportunity to work with some great partners on Azure automation projects and also talk about it at the Microsoft Partner Days in Munich. So I thought it might be worth writing a few words about it on my blog and move away from the .NET Core topic. A huge challenge is to keep this as short as possible.

Microsoft Azure Automation provides a way for users to automate the manual, long-running, error-prone, and frequently repeated tasks that are commonly performed in a cloud and enterprise environment. It saves time and increases the reliability of regular administrative tasks and even schedules them to be automatically performed at regular intervals. You can automate processes using runbooks or automate configuration management using Desired State Configuration. I will not give the entire “Intro” talk here :). If you are not familiar at all with this topic, you may check the official Microsoft getting started guide. Continue reading

Azure AD Connect – how to manually trigger a synchronization

Published by:

Update: Azure AD Connect default sync intervals and manual sync process have totally changed starting with version released in February 2016. Please refer to THIS article to find out how to manually trigger a synchronization cycle.

I don’t know if you have noticed so far, but I am a very  big fan of Azure AD and everything that surrounds it, like Azure AD Connect, ADFS an all features that come together with Azure AD like password write back (only with Azure AD Premium), Azure AD join, Azure AD B2C, Enterprise State Roaming and the list could go on. I also noticed that I wrote very little about Azure AD on this blog, so I decided to concentrate more on this the coming days. And since this week I had a partner engagement where this question showed up, I decided to explain here how can you manually trigger a synchronization cycle using Azure AD Connect.

First of all, this question arises because in older versions of DirSync we used to do this in a certain way, but with Azure AD Connect this process has changed. So administrators that were very familiar with this process in DirSync start to get confused.

Secondly, before starting a synchronization, we would have to decide if we need a full synchronization or a delta synchronization, right? As you may know, a full synchronization imports once again all your objects and synchronizes them again to Azure AD. A delta synchronization will synchronize only objects that have changed in Active Directory since the last synchronization, so users for which you may have changed an attribute, new users or deleted users (applies also to groups and contacts, of course).

So assuming that we need to trigger a full synchronization, we have one great option: PowerShell. Only that this is a little bit different now. So first of all, you would need to open PowerShell and navigate to the following location: C:\Program Files\Microsoft Azure AD Sync\Bin. So the very basic PowerShell cmdlet to do this would be:  Continue reading

Some PowerShell magic with Office 365 licenses

Published by:

PowerShell is a great tool when we have to manage a lot of resources, because it enables automation. Most of you may be already aware that we can use PowerShell also with Office 365. So let’s see some PowerShell magic with Office 365 licenses.

These days one of my colleague had to deal with a very interesting scenario. A customer moved to Exchange Online and therefore assigned only Exchange Online licenses to the users that were synchronized from the local Active Directory. After the whole migration process was ended, the customer decided to also use the powerful features of SharepointOnline. So he wanted an automated option to assign to some users also the SharePoint Online licenses, without removing the Exchange Online license first. (Removing an Exchange Online license would disconnect the mailbox and put it into a soft deleted state. Assigning the license back would re-connect the mailbox, but in some cases this process causes some big problems).  Continue reading

Office 365 tenant to tenant migrations. Some things you should know about

Published by:

With cloud adoption going at a fast pace, Office 365 tenant to tenant migrations are scenarios that IT pros have to face more and more often. When a company using Office 365 acquires another company that also uses Office 365, it is obvious that the resources have to be consolidated in a certain way. Being cloud-only organizations, the only choice is a tenant to tenant migration. As this process is pretty painful, I thought to blog about it and point out some things you should know about.

At first, we would have to migrate the users and mailboxes from one tenant to another, including the used mail domain, like domain.com. My recommendation is to start the verification process of the mail domain in the target tenant and to create the necessary DNS record to prove domain ownership. Sure, we won’t be able to completely verify the domain since it is still present on the source tenant, but by doing this we can make sure that the new DNS record will be appropriately propagated in DNS by the time we have removed it from the source tenant.  Continue reading