O365 – Tips & Tricks in Powershell


For those who are starting to work on O365 using powershell, here below are some short lines to help you.

Prerequisites :


Connect to O365 :

Add a licence to a user :



Read more

Defending Against PowerShell Attacks

Read more

O365 – Check Sync batch

When you are doing a migration from Exchange to O365, there are two ways :

  • Direct Migration
  • Two step migration (provisioning then migrating)

If you choose the second way, you’ll have to check if all mailboxes are synced and not failed.

Read more

Open a file with its default application

Hey there !

A little tip I’ve just found, really usefull.

If you need to open a file through Powershell with the default application set up in Windows parameter, just use “Start-process” and the full path of your file

In this short example, this command will launch Excel and your file !

Read more

Group-Object is magic !

I had to create a script that sort a whole csv, each line is an extract of a computer scan, one extract per day, and get only the last extract per computer AND per user.

Indeed, a user can use multiple computers, and several users can use the same computer, the extract result is not the same !

Read more

How to wish a birthday using Powershell

It’s easy to surprise someone, setting sound to mute=off and sound at 100% using that code :


Read more

Remote Check Memory Usage

When you have to do a lot of stuff on remote servers, the best you have, you MUST do is to check is the Ram usage is not too high.

Here is a little function that can help

On some powershell version (V3.0…) if the returned value is below 10, an error could happen if you try to compare that returned value with a number.

Read more

Sort files by extension with total size

For several reasons, it could be awesome to sort a folder and sub by extension, with the associated size for each.



Read more

Get all pst files set up in Outlook ?

Then you just have to call that function such as :


Read more

LAN Speedtest in Powershell

Sometimes it may be usefull to monitor the network speed on your LAN/WAN network. This little script needs to acces to the c$ admin share to work.

That works as the famous Speedtest.net website, uploading and then downloading a simple file, calculating then the average speed.

Enjoy !

Read more
How to whitelist website on AdBlocker?

How to whitelist website on AdBlocker?

  1. 1 Click on the AdBlock Plus icon on the top right corner of your browser
  2. 2 Click on "Enabled on this site" from the AdBlock Plus option
  3. 3 Refresh the page and start browsing the site