Part 1 : Useful Office 365 commands

List of useful Office 365 commands :

1.To get the list of O365 users : get-msoluser

msol user

2.To create a new user: new-msoluser -UserPrincipalName -displayname “Test User”

new user

3.To remove an existing user: remove-msoluser -UserPrincipalName

4.To get the Office 365 license information : get-msolaccountsku

msol accountsku

5.To get the details about the enterprise pack and the services included in it: Get-MsolAccountSku | Where-Object {$_.SkuPartNumber -eq “ENTERPRISEPACK”} | ForEach-Object {$_.ServiceStatus}

Enterprise pack

6. To get the details of the users and the license assigned to them : get-msoluser -all | ft displayname, licenses | Out-file “C:\userlicenses.csv”

Note : *Running this command will generate a csv file in the specified path  which has the details in it .

7. To assign license to a specific user : set-msoluserlicense -UserPrincipalName -AddLicenses “vign:enterprisepack”

8. To remove license assigned to a specific user: set-msoluserlicense -UserPrincipalName -RemoveLicenses “vign:enterprisepack”

9. To create a new security group: new-msolgroup -DisplayName “Groupname” -Description “Group Description”

New group

Note : *Specify the Groupname in the “Groupname” field and mention the group description in the “Group Description” field .In the above case “Vignesh” is the group name and “Desktop Technicians” is the group description.

10. To get the list of security groups: get-msolgroup


11. To get the list of roles in your tenant: get-msolrole


12. To add a user to a roleadd-msolrolemember -rolename “User Account Administrator” -rolememberemailaddress “”

13. To set a password for a user : set-msoluserpassword -UserPrincipalName “” -newpassword “P@ssw0rd2015”


Deprecated or removed features in SharePoint Server 2016 IT Preview

This  technet link gives a detailed explanation of the deprecated or removed features in SharePoint Server 2016 IT Preview.

Note: Since this is only the preview version I think this list is subjected to change in the mere future . Also please be mindful that the “Tags” and “Notes” feature is removed in SharePoint Online too.

SharePoint 2013 Permission Report: Check Access Rights for a Specific User

I’m pretty sure that by now many of the SharePoint SME’s out there would have tried the “Check access rights script for a specific user” . Now if you’re new to this , please take a look at the link below to understand what this script is all about .It’s a very powerful tool with some limitations.  I happened to work with this script recently and listed below is my experience with this script .

  1. It doesn’t get really granular and looks for all the bits and pieces and retrieve the complete information we are looking for .For instance it can’t get the permission assigned on a list item and its just stops at the list level .In addition to that it doesn’t look for the security groups too. 
  2. The script takes atleast not less than 30 mins to 1 hour to run depending upon the size of the FARM and the contents it has as it has to go through all the contents in the FARM . So its better you run this script on a server which is properly scaled out .
  3. Another annoying fact about this script is , the final report displays the list of all the sites where the “NTAuthority\Authenticates users” group and the “Everyone” group is added . For sure every user in the domain would be a part of this group and its really annoying to see the  report displaying  all those results which we don’t really need . Moreover it would be  great if the result just displays the list of the sites where the user was explicitly added . 

Powershell command to manually create a user’s “My site” in SharePoint

Powershell command to manually create a “My site” in SharePoint:

The “My site” in SharePoint normally gets created by the instantiation process when a user tries to access his/her “My site” for the first time .Now this process depends on how you have configured this functionality to work in your environment. It could either be configured in a way such that the “My site” is already created for the users in the FARM or may be the users need to access their “My site” for the first time and then the instantiation process would run which will then create a “My site” for the user.

This can also be done manually using Powershell .

Mentioned below is the Powershell command which is used to manually create a user’s “My site” …

$site=Get-SPSite “”
$serviceContext = Get-SPServiceContext -Site $site
$userProfileConfigManager = New-Object Microsoft.Office.Server.UserProfiles.UserProfileManager($serviceContext)
$testuser = $userProfileConfigManager.GetUserProfile(“domain\username”)

Note: Please make sure that you’re logged into the SharePoint server using the FARM account while running this command .Also make sure that the account running this command has enough permissions in the user profile service application too. 

SharePoint Server 2016 IT Preview


SharePoint Server 2016 IT Preview:

Ever since Microsoft announced the next on-premises of SharePoint ( i.e. SharePoint Server 2016) on Ignite this May , the term ” SharePoint 2016″ has caught the attention of many SharePoint geeks and everyone is keenly looking for its release date ….Now its quite obvious and a well known fact that Microsoft has added many advanced features to this release version which can add more value to the business and also offer a lot to IT Pros and Developers .

Today Microsoft has announced the availability of both SharePoint Server 2016 IT Preview and the new cloud hybrid search preview for SharePoint Server 2013 and 2016. Please check the Blog below for complete info:

Download link for SharePoint Server 2016 Preview :

Some useful documentation on SharePoint Server 2016 IT Preview :