Get total one drive for business storage usage for list of users

This topic contains 1 reply, has 2 voices, and was last updated by  random commandline 1 year, 7 months ago.

  • Author
  • #56804


    Good day fellow powershell'ers. I have what I hope is a simple question. How do I get the total one drive for business storage used by a group of users? We can skip the basics...I am connected to O365/Sharepoint online, I am able to get the storage usage for a single user, and I have a CSV list of users I just don't know how to use the list to get thier total (or list of) one drive for business storage used?

  • #56815

    random commandline

    I am not familiar with Office365 cmdlets, but something like this should work.

    $users = Get-Content \\path\to\userlist.csv
    $results = foreach ($user in $users){
            # Code to get $user storage usage
    $results | Measure-Object -Property storage-property

You must be logged in to reply to this topic.