Skip to main content

Get-USBStorageDevice

SYNOPSIS​

Shows USB storage devices that have connected to a computer.

SYNTAX​

Get-USBStorageDevice [[-ComputerName] <String[]>] [<CommonParameters>]

DESCRIPTION​

Shows USB storage devices that have connected to a local or remote computer. Limitations apply. Only shows devices that are listed in the registry. Sometimes, depending on the computer that is only the most recent device.

EXAMPLES​

EXAMPLE 1​

Get-USBStorageDevice

Runs Get-USBStorageDevice on a local computer.

EXAMPLE 2​

Get-USBStorageDevice -ComputerName COMP1
Shows the USB storage devices that have connected to the remote computer COMP1.

PARAMETERS​

-ComputerName​

Specifies the name of one or more computers.

Type: String[]
Parameter Sets: (All)
Aliases: Host, Name, Computer, CN

Required: False
Position: 1
Default value: "$env:COMPUTERNAME"
Accept pipeline input: True (ByPropertyName, ByValue)
Accept wildcard characters: False

CommonParameters​

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

INPUTS​

OUTPUTS​

System.Object​

NOTES​

ALIASES​

None.

PLATFORM APPLICABILITY​

Windows only. The platform-aware loader does not export this command on Linux or macOS.

POWERSHELL COMPATIBILITY​

See PowerShell compatibility for the supported runtime policy. PowerShell 7.6 LTS is preferred.

https://docs.keldor.dev/powershell/keldor/Get-USBStorageDevice