Forum Discussion
AAD PowerShell Commands not working (get-msol ...)
- Oct 06, 2016These cmdlets are not supported in the Azure Active Directory Module for Windows PowerShell GA (v.1.1.166.0) which you have installed. Instead you can install V1.1.130.0 public preview and use it. See release notes from below link for more details.
http://connect.microsoft.com/site1164/Downloads/DownloadDetails.aspx?DownloadID=59185
Hi Dean, thanks for your response and feedback.
I'm currently working on a cross reference document between V1 and V2 cmdlets, I hope to get this out soon. I'm also working on an article that better explains the migration plan from V1 to V2 and what sort of timelines we're thinking about for the deprecation of V1.
The question about Preview vs GA, version numbers and which cmdlets are where came up several times now so I'm adding some additional content to the documentation there as well. But here's the short version:
We release our PowerShell in modules on the PowerShell Gallery. A module consists of a set of DLLs, one for each API endpoint we call. Which cmdlet goes where is determined by a configuration file for each of the modules - so a release consists of a subset of all the DLLs that came out of the build, and all of these DLLs have the same version number, e.e. 2.0.0.89
We have a build system that creates a daily build for 3 V2 module releases: a private build, a public preview build and a general availability build.
The idea here is that if we have something brand new that someone either internally or externally needs to try out we can get them the private build. THis build will always contain the latest and greatest of everything we have, but may not be completely tested and documented.
All cmdlets that have been approved for release always go into the public preview build, and this build is usually published on the PowerShell gallery as soon as there are changes. So when you're looking for a certain cmdlet and want to be sure you have the latest version, this will always be on https://www.powershellgallery.com/packages/azureadpreview, which will redirect you to the latest version. Note that preview cmdlets can still change and these changes may potentially break any scripts or preocesses in which they are used, so we recommend not using them in a production environment.
The General Availability release needs to pass certain gates first: fully tested,fully documented, all; API's it uses must be GA too, only using public API's etc. As soon as a cmdlet passes these gates in can be promoted into the GA release. GA also means "fully supported by Microsoft". The GA release is always a subset of the Public Preview release.
So this is why the version numbers are independent of the release types. We could potentially release a preview and a GA version at the same time and they would have the same version numbers - but the module names would be different - AzureAD vs AzureADPreview.
What I can do to help clarify which cmdlet is in which release is add, to the preview release notes, a list of all cmdlets that are in preview and not in the GA version. Would that help?
Any other suggestions to help create more clarity?
Thanks,
Rob
What is most maddening is that even when we see which versions have the PS cmdlet's we need, it redirects to the latest release to download which may not have them. Higher version number, but oddly enough drops previous version cmdlets in the same version branch. Really? Took me a while to figure that out and then how to get an older preview release to use the cmdlet's I needed to control O365 Group Creation. Nevermind that many blog posts on this topic, most importantly those created by Microsoft, refer to a specific v1 preview version of MSOL module cmdlets that is not available for download anywhere right now. The adding and dropping of these critical cmdlets is maddening to anyone simply trying to follow some instructions. I'd appreciate if MS paid a little closer attention to older versions that have cmdlets that were not brought forward. Leave those as available. Don't take them down/redirect please.
- Rob de JongMar 23, 2017Former Employee
Hi Christopher, thanks for your feedback.
Please note: the MSOL preview cmdlets for Settings have not stopped working and can be used just as before. However, since we have deprecated these cmdlets and replaced them with newer cmdlets in the V2 module we no longer publish the module in in which they were exposed.
To answer your question about releases and versions:
There are two releases for Azure AD PowerShell that our team publishes: the preview release and the GA release. As I mentioned in my previous comment, the GA release is a subset of the preview release.These two releases have separate download links: https://www.powershellgallery.com/packages/azureadpreview for the preview release, and https://www.powershellgallery.com/packages/azuread for the GA release.
Both these links will redirect to the latest version. If you scroll down the download page you will see all older versions and can go to their respective module pages. There are currently 18 older versions of the preview module available for installation.
To install the preview version, you would use Install-module AzureADPreview, to install the GA version use Install-Module AzureAD. The Install-module cmdlet always installs the latest version of a module. If you require a previous version you can install this by specifying the -required version parameter, as in:Install-module AzureADPreview -RequiredVersion 2.0.0.52
The reason we publish preview versions of the module is that we know that for new capabilities, customers often like to get their hands on them as quickly as possible to investigate the new functionality. We encourage this as it often provides valuable feedback that allows us to improve and fine tune our cmdlets based on this feedback. Note that these improvements could potentially introduce breaking changes, so we mention in all of our documentation that preview cmdlets should not be used in a production environment.
A breaking change was introduced for the MSOL Setting cmdlets when we moved those to the Azure AD PowerShell V2 module. The full capability of the cmdlets is available in V2 and has not changed.
I'm sorry if this change has caused confusion.We are working with teams within Microsoft and with 3rd parties that have pubished references to the MSOL Settings cmdlets to get these updated to reflect this change.
Thanks again for your feedback.-Rob
- Ivan54Mar 24, 2017Bronze Contributor
for me the most confusing part was that a lower build number preview had commandlets that a higher version build GA version did not have.
V2 helps in this regard, with the -preview prefix for commands. I believe those were not available in v1, right?
For me it wasn't clear that those were not preview versions in v1, but in reality a completely different release channel. What didn't help either was, that the preview channel didn't include commandlets from previous versions.