列出Powershell中的所有设备,分区和卷 [英] List all devices, partitions and volumes in Powershell

查看:246
本文介绍了列出Powershell中的所有设备,分区和卷的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有多个卷(如今几乎像每个人一样):在Windows上,它们最终指定为C:,D:等.如何在Powershell中使用"ls/mnt/"的Unix机器上列出所有这些信息?

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?

推荐答案

要获取所有文件系统驱动器,可以使用以下命令:

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

gdr -PSProvider 'FileSystem'

gdr Get-PSDrive 的别名.包括注册表的所有虚拟驱动器"等.

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

这篇关于列出Powershell中的所有设备,分区和卷的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆