Alex Rivera | Logout

List all devices, partitions and volumes in Powershell

Asked 2009-11-02T20:42:18.077
96

I have multiple volumes (as nearly everybody nowadays): on Windows they end up specified as C:, D: and so on. How do I list these all like on a Unix machine with "ls /mnt/" with Powershell?

Edit
Report

1 Answer

120

To get all of the file system drives, you can use the following command:

gdr -PSProvider 'FileSystem'

gdr is an alias for Get-PSDrive, which includes all of the "virtual drives" for the registry, etc.

answered 2009-11-02T20:52:23.693

Your Answer