Essential troubleshooting command lines every Storage Administrator should know

A CLI (Command Language Interpreter or Command Line Interface) is a program which handles the interface using text in lines (command lines). The usage of Command Lines dates back from from the mid-1960s where computer terminals were widely used as the standard technology.

Today, almost every platform or software’s fundamentals are based on the command line. Starting from Windows Server 2012, any Linux distribution or even computer or storage networks (SAN).

Below we will cover some command line commands which are essential for every Storage Administrator. If you think there’s more interesting to be added, feel encouraged to contact us.

Microsoft Windows Powershell

Determine a Virtual Machine’s underlying physical host (Command execution: Guest computer)

(get-item "HKLM:\SOFTWARE\Microsoft\Virtual Machine\Guest\Parameters").GetValue("HostName")

Get a VM’s .VHD(X) location files and .VHD details (Command execution: On the host computer)

Get-VM | Select-Object VMID | Get-VHD | Select-Object Path
Get-VHD <.VHDX file path>

Get a Host Adapter’s WWN (Command execution: On the host computer)

Get-InitiatorPort | Select-Object -Property PortAddress | Format-List -Property PortAddress

Get Host Adapter’s WWN remotely or for a whole cluster (Command Execution: On the host computer)

Get-InitiatorPort -CimSession <Computer name>
Get-ClusterNode | %{Get-InitiatorPort -cimsession $_.Name}

Show MPIO disk paths of a volume / vlun (Command execution: On the host computer)

(gwmi -Namespace root\wmi -Class mpio_disk_info).driveinfo | % {Write-host "Name: $($_.name) Paths: $($_.numberpaths)"}

Brocade OS CLI

Find a host Alias name using WWN

nodefind <Host's wwn>

Find a host alias using a wildcard ” ”

nsaliasshow | grep -i "<alias name>"

Display zone information of an alias

zoneshow | grep -i "<alias name>"

Display error information of a single port of all switch ports

porterrshow
porterrshow <port number>

Any suggestion or question? Leave a reply below, or feel free to contact us. Make sure to subscribe to our mailing list to get the latest.

Share Article on:

Facebook
Twitter
LinkedIn

One Response

Leave a Reply

Your email address will not be published. Required fields are marked *