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

Welcome Forums General PowerShell Q&A 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

 
Participant
2 years, 1 month ago.

  • Author
    Posts
  • #56804

    Participant
    Points: 0
    Rank: Member

    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

    Participant
    Points: 10
    Rank: Member

    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
    

The topic ‘Get total one drive for business storage usage for list of users’ is closed to new replies.