Skip to Content

Solved: How to add name labels for each PowerShell entry?


Does anyone have experience with this PowerShell script? We are close to completion, however, we are encountering an issue where the PowerShell script does not include the server name for each entry. Any assistance would be greatly appreciated.

$servers = @("server 1", "server2", "server3")


It appears that the current command is not functioning as intended. The same (local) volumes are being queried three times. To ensure the command is executed correctly, it is necessary to include the server names:

$servers = @("server 1", "server2", "server3")
Get-Volume -CimSession $servers

Note: It is not necessary for this small snippet, but if you wish to store the server names in an array, it can be done.

    Ads Blocker Image Powered by Code Help Pro

    It looks like you are using an adblocker.

    Ads keep our content free. Please consider supporting us by allowing ads on