My Cheat Sheets

Reading Time: 8 minutes

Here you will find my collection of cheatsheets. This is mainly because I find it hard to remember every command. So i make a note here and refer back to it when needed.

If you like it please leave a comment, or if you have a command to recommend then please let me know.

VMware Cheatsheet

These cheats sheets are to be used on VMware plaform

Operating SystemApplicationTypeCommandWhat it doesNotes
LinuxFTPLog Location/etc/log/vsftpd.logLocation of FTP logs
VmwarePowerCLIVmkernel/etc/init.d/hostd restart
/etc/init.d/vpxa restart
Restart Management services on Host
VmwarePowerCLIVM # Check if your VM has (Change Block Tracking) enabled or not
(Get-VM -Name Server_Name).ExtensionData.Config.ChangeTrackingEnabled
(Get-VM-Name Server_Name).ExtensionData.Config.ChangeTrackingEnabled
# Find VMs where CBT (Change Block Tracking) is Enabled
Get-VM| Where-Object{$_.ExtensionData.Config.ChangeTrackingEnabled-eq $true}
Check if CBT enabled on VMAmend server names as appriopriate
VmwarePowerCLIVM-NeworkGet-VM | Get-NetworkAdapter | Select @{N=’VM’;E={$_.Parent.Name}},@{N=’AdapterName’;E={$_.Name}},@{N=’Type’;E={$_.Type}} | Where-Object{$_.Type -eq “e1000”}Get VM NIC with E1000
VmwarePowerCLIVMGet-vm | Select Name, @{N=”IP Address”;E={@($_.guest.IPAddress[0])}}Get VM IP
VmwarePowerCLIVMGet-VM | Select Name, @{N=”Cluster”;E={Get-Cluster -VM $_}}, @{N=”ESX Host”;E={Get-VMHost -VM $_}}, @{N=”Datastore”;E={Get-Datastore -VM $_}} |sort-object Datastore Get VM Name, cluster, ESX , Datastore – and sort by Datastore
VmwarePowerCLIVM-NeworkGet-VM | Get-NetworkAdapter | Select-Object Parent,TypeQuery the nic type of all virtual machines
VmwarePowerCLIVM-Datastoreget-vm | foreach-object -process {get-harddisk $_} | select-object storageformat | format-listQuery the disk type of all virtual machines
VmwarePowerCLIVMGet-VM | Get-Snapshot | Where {$_.Created -lt (Get-Date).AddDays(-90)} | Select-Object VM, Name, Created, SizeMBGet snapshots older than 3 months
VmwarePowerCLIVMGet-VM | Get-Snapshot | Where {$_.Created -lt (Get-Date).AddDays(-120)} | Remove-Snapshot -Confirm:$falseGet snapshots then remove them
VmwarePowerCLIVMGet-VM | Format-Table Name, @{Label=”NumSnapshots”;Expression={(Get-Snapshot -VM $_ | Measure-Object).Count}}Count number of snapshots
VmwarePowerCLIVMget-vm |% { get-view $_.id } | select Name, @{ Name=”;ToolsVersion”;; Expression={$_.config.tools.toolsVersion}}Get Vmware tools version
VmwarePowerCLIHostget-vmhost | select Name,@{Name=”Time”;Expression={(get-view $_.ExtensionData.configManager.DateTimeSystem).QueryDateTime()}}Get time off hosts
VmwarePowerCLIVMForEach ($VM in Get-VM ){($VM.Extensiondata.Guest.Disk | Select @{N=”Name”;E={$VM.Name}},DiskPath, @{N=”Capacity(MB)”;E={[math]::Round($_.Capacity/ 1MB)}}, @{N=”Free Space(MB)”;E={[math]::Round($_.FreeSpace / 1MB)}}, @{N=”Free Space %”;E={[math]::Round(((100* ($_.FreeSpace))/ ($_.Capacity)),0)}})}Get Vms and free disk space
VmwarePowerCLIHostGet-VMHost | Sort Name | Get-View | Select Name, @{N=”CPU”;E={$_.Hardware.CpuPkg[0].Description}}Get Host CPU info
VmwarePowerCLIHostGet-Vmhost *Lists Vmhost 
VmwarePowerCLIHost get-vmhost -datastore Datastore_NameGet Vmhosts on particular datastore
VmwarePowerCLIHost$esxihost | Get-VMHostServiceGet Vmhosts services
VmwarePowerCLIHost$esxihost | Get-VMHostService | where {$_.key -eq “TSM-SSH”}Find $vmhosts with SSH running
VmwarePowerCLIHost$esxihost | Get-VMHostService | where {$_.key -eq “TSM-SSH”} | Start-VMHostServiceStart SSH service on $exsihost
VmwarePowerCLIHost$esxihost | Get-VMHostService | where {$_.key -eq “TSM-SSH”} | Stop-VMHostServiceStop SSH service on $esxihost
VmwarePowerCLIVMGet-VM | Get-View | Select-Object Name, @{name=”toolsVersions”; Expression={$_.config.tools.toolsversion}}Get Vmware Tools versions
VmwarePowerCLIHost$esxihost | Get-VM | Get-SnapshotGet list of snapshots on $esxihost
VmwarePowerCLIHost$esxihost | Get-VM | Get-VMGuest | format-tableGet list of Guest Operating systems on $esxihost
VmwarePowerCLIHostget-vmhost | select Name,@{Name=”Time”;Expression={(get-view $_.ExtensionData.configManager.DateTimeSystem).QueryDateTime()}}Get time on all hosts
VmwarePowerCLIHost$esxihost |Get-VM |Where {$_.PowerState -eq “PoweredOn“} |Sort Name |Select Name, NumCPU, @{N=“OSHAL“;E={(Get-WmiObject -ComputerName $_.Name-Query “SELECT * FROM Win32_PnPEntity where ClassGuid = ‘{4D36E966-E325-11CE-BFC1-08002BE10318}’“ |Select Name).Name}}, @{N=“OperatingSystem“;E={(Get-WmiObject -ComputerName $_ -Class Win32_OperatingSystem |Select Caption).Caption}}, @{N=“ServicePack“;E={(Get-WmiObject -ComputerName $_ -Class Win32_OperatingSystem |Select CSDVersion).CSDVersion}}Get Detailed VM informationMust have permissions on Guest-VMs to propagate all information
VmwarePowerCLIHost Get-VMHost | Select @{N=”Cluster”;E={Get-Cluster -VMHost $_}}, Name, @{N=”NumVM”;E={($_ | Get-VM).Count}} | Sort Cluster, NameList how many VMs are running on a Host
VmwarePowerCLIVMForEach ($VM in Get-VM ){($VM.Extensiondata.Guest.Disk | Select @{N=”Name”;E={$VM.Name}},DiskPath, @{N=”Capacity(MB)”;E={[math]::Round($_.Capacity/ 1MB)}}, @{N=”Free Space(MB)”;E={[math]::Round($_.FreeSpace / 1MB)}}, @{N=”Free Space %”;E={[math]::Round(((100* ($_.FreeSpace))/ ($_.Capacity)),0)}})}List all VM’s and their disk sizes
VmwarePowerCLIHostGet-VMHost | Sort Name | Get-View | Select Name, @{N=”CPU”;E={$_.Hardware.CpuPkg[0].Description}}Get Host CPU details
VmwarePowerCLIHostGet-VMHost |Sort Name |Get-View |Select Name, @{N=“Type“;E={$_.Hardware.SystemInfo.Vendor+ “ “ + $_.Hardware.SystemInfo.Model}},@{N=“CPU“;E={“PROC:“ + $_.Hardware.CpuInfo.NumCpuPackages + “ CORES:“ + $_.Hardware.CpuInfo.NumCpuCores + “ MHZ: “ + [math]::round($_.Hardware.CpuInfo.Hz / 1000000, 0)}},@{N=“MEM“;E={“” + [math]::round($_.Hardware.MemorySize / 1GB, 0) + “ GB“}} Get Host Hardware information
VmwarePowerCLIHostGet-VMHost | Get-VMHostNetwork | Select Hostname, VMKernelGateway -ExpandProperty VirtualNic | Where {$_.ManagementTrafficEnabled} | Select Hostname, PortGroupName, IP, SubnetMaskThis will then dump the ESXi Hostnames, IPs and Subnets – For the Management Network
VmwarePowerCLIHostGet-VMHost | Get-VMHostNetwork | Select Hostname, VMKernelGateway -ExpandProperty VirtualNic | Where {$_.vMotionEnabled} | Select Hostname, PortGroupName, IP, SubnetMaskThis will then dump the ESXi Hostnames, IPs and Subnets – For the vMotion Network
VmwarePowerCLIHostGet-VMHost | Get-Cluster | Select Name, DrsEnabled, DrsMode, DrsAutomationLevelDump DRS status
VmwarePowerCLIHostGet-VMHost | Get-Cluster | Select Name, VMSwapfilePolicyDump VMSwapfilePolilcy
VmwarePowerCLIHostGet-VMHost | Get-Cluster | Select Name, HAAdmissionControlEnabledCheck status of HA Admission Control
VmwarePowerCLIHostGet-VMHost | Get-Cluster | Select Name, HAFailoverLevel, HARestartPriority, HAIsolationResponseCheck HA Status Levels
VmwarePowerCLIVM-NeworkGet-VMHost | Get-VMHostNetwork | Select Hostname, VMKernelGateway -ExpandProperty VirtualNic | Select Hostname, PortGroupName, IP, MTUCheck for MTU Mismatches
VmwarePowerCLIVM-NeworkGet-VirtualSwitch | Select VMHost, Name, MTUShows what the MTU settings on the Virtual Switches are
VmwarePowerCLIVM-NeworkGet-VMGuestNetworkInterface –VM VMNAME | Select VM, IP, SubnetMask, DefaultGateway, DnsDumps a hosts Name, IP, Subnet, Gateway and DNS configuration 
VmwarePowerCLIHostGet-VMHost | Get-ScsiLun | Select VMHost, ConsoleDeviceName, Vendor, MultipathPolicyThis will dump the Multipath Policy of the storage on the systems to determine what the MP configuration is. 
VmwarePowerCLIHostGet-VMHost | Sort Name | Select Name, @{N=”NTP”;E={Get-VMHostNtpServer $_}}This will dump NTP Configuration settings
VmwarePowerCLIHostGet-View -ViewType HostSystem | Sort Name | Select Name,@{N=”BIOS version”;E={$_.Hardware.BiosInfo.BiosVersion}}, @{N=”BIOS date”;E={$_.Hardware.BiosInfo.releaseDate}}This will dump the hosts BIOS version and date(s)
VmwarePowerCLIHostget-vmhost | Get-VMHostAdvancedConfiguration -Name Syslog.global.logHostDump the current SYSLOG Configuration
VmwarePowerCLIVM-Nework $esxihost | Get-VM | Get-NetworkAdapter | Select @{N=’VM’;E={$_.Parent.Name}},@{N=’AdapterName’;E={$_.Name}},@{N=’Type’;E={$_.Type}} | Where-Object{$_.Type -eq “e1000”}Detailed E1000 details of $esxihost
VmwarePowerCLIVMGet-VIEvent -maxsamples 10000 |where {$_.Gettype().Name-eq “VmCreatedEvent” -or $_.Gettype().Name-eq “VmBeingClonedEvent” -or $_.Gettype().Name-eq “VmBeingDeployedEvent”} |Sort CreatedTime -Descending |Select CreatedTime, UserName,FullformattedMessage -First 10Find Vm’s Created last 10 days
VmwarePowerCLIVM-Snapshot$esxihost | Get-VM | Get-Snapshot | Select VM,Name,Created,sizegb,descriptionGet Snapshot details of $esxihost and list name, vmname, sizegb and snapshot description
VmwarePowerCLIVM-Nework$myvm | Get-NetworkAdapter | Select parent, name, type, networkname, connectionstate |Format-Table -AutoSizeDefine $myvms – lists network adapter details
Windows ServerCommand PromptPersistant Routesroute add -P 195.118.166.0 MASK 255.255.255.0 172.20.204.20Adds Persistant Route example
Windows ServerCommand PromptPersistant Routesroute add -P 194.201.103.0 MASK 255.255.255.0 172.20.204.20Adds Persistant Route example
Windows ServerCommand PromptActive DirectoryNetdom computername %computername% /add:serverfqnAdd Computer to AD
Windows ServerCommand PromptActive DirectoryNetdom computername %computername% /remove:serverfqnMake Primary
Windows ServerCommand PromptActive DirectoryNetdom computername %computername% /remove:serverfqnRemove from AD
Windows ServerCommand PromptDHCPipconfig /all | find /i “DHCP Server”Find DHCP Server
Windows ServerCommand PromptDHCPnetsh dhcp show serverList all authorsed DHCP servers
Windows ServerCommand PromptPersistant RoutesAdds static Routes to the SDN
Windows ServerCommand PromptPersistant RoutesAdds static Routes to the SDN
Windows ServerPowerShellPS Core Command$psversiontableWhich version of powershell and I running
Windows ServerPowerShellPS Core CommandSet-ExecutionPolicy -Scope Process -ExecutionPolicy BypassAllow execution of commandsUse with caution
Windows ServerPowerShellPrinterGet-Printer | select Name, DriverName, PortName | Export-Csv Printers.csv -NoTypeInformationList printers on a server
Windows ServerPowerShellPS CommandGet-ItemProperty HKLM:\Software\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\* | Select-Object DisplayName, DisplayVersion, Publisher, InstallDate | Format-Table –AutoSize >C:\temp\installed.txtList installed programs on server
Windows ServerPowerShellActive DirectoryGet-ADDomainController -Filter * | Format-table name,domain, forest,site, ipv4address, operatingsystemFind Domain Controllers
Windows ServerPowerShellFile SystemGet-Childitem -Path C:\windows -Recurse -Filter *.dllFind any *dll* on filesystem – recursive
Windows ServerPowerShellFile System Get-ItemProperty .\install.xml | select *Get Detailed File information
Windows ServerPowerShellActive DirectorySearch-ADAccount -LockedOut | Format-Table name,lastlogondate, lockedout, objectclass, passwordexpired, passwordneverexpiresFind locked out users
Windows ServerPowerShellActive DirectorySearch-ADAccount -AccountDisabled -UsersOnly | FT Name,ObjectClass -AFind disabled users
Windows ServerPowerShellActive DirectorySearch-ADAccount -AccountInactive -TimeSpan 90.00:00:00 -UsersOnly  | FT Name,ObjectClass -AFind Users not logged in for 90 days
Windows ServerPowerShellActive DirectorySearch-ADAccount -AccountInactive -TimeSpan 90.00:00:00 -UsersOnly |Sort-Object | FT Name,ObjectClass -AFind Users not logged in for 90 days & Sort
Windows ServerPowerShellActive DirectorySearch-ADAccount -AccountInactive -TimeSpan 90.00:00:00 -UsersOnly |Sort-Object -property lastlogondate | FT Name,ObjectClass,lastlogondate, lockedout,  -AFind Users not logged in for 90 days & Sort by last logon 
Windows ServerPowerShellActive DirectoryGet-ADGroupMember -identity “Domain Admins” -recursive | select name | Export-csv -path C:\temp\Groupmembers.csv -NoTypeInformationFind “domain admins”Change group as required
Windows ServerPowerShellActive DirectoryGet-ADComputer -Filter ‘Name -like “gbsyn*”‘ -Properties canonicalName,CN,created,IPv4Address,objectclass,OperatingSystem,OperatingSystemServicePackFind Computer with GBSYN* in the nameChange as required
Windows ServerPowerShellActive DirectoryGet-ADPrincipalGroupMembership -identity ssi_rbailey | Sort-object | FT -property name, samaccountname -AutoSizeFind which AD groups a user is member ofChange as required
Windows ServerPowerShellActive DirectoryGet-ADGroupMember -Identity “Domain Admins” -Recursive | %{Get-ADUser -Identity $_.distinguishedName -Properties Enabled | ?{$_.Enabled -eq $false}} | Select DistinguishedName,Enabled | Export-Csv c:\temp\result.csv -NoTypeInformationFind Disabled Domain admins
Windows ServerPowerShellActive DirectoryGet-ADGroupMember -Identity “Domain Admins” -Recursive | %{Get-ADUser -Identity $_.distinguishedName -Properties Enabled | ?{$_.Enabled -eq $false}} | Select Name,SamAccountName,Enabled, objectclass | sort-object -Property nameFind Disabled Domain admins & Sort
Windows ServerPowerShellActive DirectoryGet-ADGroupMember -Identity “Domain Admins” -Recursive | %{Get-ADUser -Identity $_.distinguishedName -Properties Enabled | ?{$_.Enabled -eq $false}} | Select Name,SamAccountName,Enabled, objectclass | sort-object -Property name | Export-CSV C:\temp\DisabledDomainAdmins.csvFind Disabled Domain admins & Sort & Export to CSV
Windows ServerPowerShellActive DirectoryGet-ADGroupMember -Identity “GROUPNAME” -Recursive | %{Get-ADUser -Identity $_.distinguishedName -Properties Enabled | ?{$_.Enabled -eq $true}} | Select Name,EnabledFind members in a group
Windows ServerPowerShellEvent  LogGet-Eventlog application -Newest 2000 | Where-Object {$_.entryType -Match “Error”}Find Latest errors in EventlogApplication log
Windows ServerPowerShellEvent  LogGet-Eventlog system -Newest 2000 | Where-Object {$_.entryType -Match “Error”}Find Latest errors in EventlogSystem Log
Windows ServerPowerShellRegistrycd hkcu:Navigate Registry like filesystemAdmin rights needed
Windows ServerPowerShellProcessesps | sort –p ws | select –last 5Find the five processes using the most memory
Windows ServerPowerShellServicesRestart-Service DHCPRestar DHCP serviceAmend as required
Windows ServerPowerShellFile SystemGet-ChildItem – ForceList all items within a folder
Windows ServerPowerShellFile SystemGet-ChildItem –Force c:\directory –RecurseList all items within a folder & all subfoldersCan take a long time to complete
Windows ServerPowerShellServicesGet-WmiObject -Class Win32_Service -Filter “state = ‘running’ and startmode = ‘auto'” | Select-Object name, startmode, description | Format-table -AutoSizeGet list of Services that start automatically
Windows ServerPowerShellSQL[System.Reflection.Assembly]::LoadWithPartialName(‘Microsoft.SqlServer.SMO’)Load SQL modules into memory Must be done on server will SQL installed (2008 or greater)
Windows ServerPowerShellSQL[System.Reflection.Assembly]::LoadWithPartialName(‘Microsoft.SqlServer.SMO’) | out-null
$s = New-Object (‘Microsoft.SqlServer.Management.Smo.Server’) “servername”
$dbs=$s.Databases
$dbs | SELECT Name, Collation, CompatibilityLevel, AutoShrink, RecoveryModel
Discover SQL instancesedit “servername” accoringly
Windows ServerPowerCLIVMGet-VIEvent -maxsamples 10000 | where {$_.Gettype().Name -eq”VmRemovedEvent”} | Sort CreatedTime -Descending | Select CreatedTime, UserName, FullformattedMessage -First 19Find Vm’s Remove last 10 days
Windows ServerPowerShellPatching$wu = new-object -com “Microsoft.Update.Searcher”
 $totalupdates = $wu.GetTotalHistoryCount()
 $all = $wu.QueryHistory(0,$totalupdates)
 # Define a new array to gather output
 $OutputCollection=  @()        
Foreach ($update in $all)
    {
    $string = $update.title
    $Regex = “KB\d*”
    $KB = $string | Select-String -Pattern $regex | Select-Object {$_.Matches }
     $output = New-Object -TypeName PSobject
     $output | add-member NoteProperty “HotFixID” -value $KB.‘ $_.Matches ‘.Value
     $output | add-member NoteProperty “Title” -value $string
     $OutputCollection += $output
    }
 # Output the collection sorted and formatted:
$OutputCollection | Sort-Object HotFixID | Format-Table -AutoSize
Write-Host “$($OutputCollection.Count) Updates Found”
Command to get all Installed KB (Windows Update) from ServerBest run for Powershell ISE
Windows ServerCommand PromptMcAffeefrminst.exe /remove=agentForce uninstall McAffee when managed by another server (managed mode)First, try typing the following: cd “C:\Program Files (x86)\McAfee\Common Framework”
If that worked, then continue to the next step. Otherwise, if you got a message saying the system cannot find the path specified, then type the following: cd “C:\Program Files\McAfee\Common Framework”
Windows ServerPowerShell
Windows ServerPowerShell
Windows ServerPowerShell

Linux Cheatsheet

These cheats sheets are to be used on Linux Servers (Typically RHEL)

Networking

CommandWhat is does?
route add -net 10.98.208.40 netmask 255.255.255.255 gw 172.31.191.254
Add a static root - substitute for your IP information
route del -net 10.98.208.40 netmask 255.255.255.255 gw 172.31.191.254
Remove static route
ifconfig eth1 192.168.1.2 netmask 255.255.240.0 gw 192.168.1.1
Configure Ethernet
/etc/sysconfig/network-scripts
Location for Networking boot configuration
ifup eth1 boot

enable NIC at boot
ifdown eth1 boot
disabled NIC at boot
ip -s link
enable overview of traffic
dhclient eth01
dhclient ens33
get new IP from DHCP
/etc/sysconfig/network
basic Network config
cat /etc/resolv.confDNS server details
cat /etc/hostsLocal host file
cat /etc/services
Ports used for Firewall
iptable -F
Flush IPtables
iptables -I INPUT -p tcp --dport 48000 -j ACCEPTOpen port 48000 on firewall

Aix Cheatsheet

I’m a big fan of the verstility of of AIX. Its such a reliable OS and once you get your head around the concepts its very easy to manage and maintain. If you know Linux you can apply the majority of that knowledge to AIX.

Most of these commands will also work on Linux

CommandWhat it does
find / -xdev | xargs ls -ld | sort -rnk 5 | moreSearch AIX Filesystem for files
egrep –p “ Search string “ –f filename.loguseful for grep very large dsmsched.logs
q vol devclass=lto_tapeQueries Tape Library and Lists Scratch tapes
q reqlists requests to reply to
lscfg –vl fcs3Get details of a fibre card fcs3
nohup /opt/Tivoli/tsm/client/ba/bin/rc.tsmclient >/dev/null 2>&1Starts TSM Process
dd if=/dev/cdrom of=line500v7.1WindowsServer.iso bs=1024Command how to copy ISO on AIX
ls |sort |awk ‘{name=toupper($1);if(name==pre1) printf(“** %s  %s\n”,$1,pre2); pre1=name;pre2=$1}’AIX command used to find the duplicate files
find /var -xdev | xargs ls -ld | sort -rnk 5 | moreFinding large files in AIX (EG /VAR)
startsrc -s qdaemonrestart error daemon

Terraform Cheatsheet

CommandWhat it does?
terraform -install-autocompleteEnables tab completion
-helpShows the help files
applyapply the changes
consolecreates and interactive console
destroydestroys the Terraform-managed infrastructure
fmtused to rewrite Terraform configuration files
force-unlockused to remove lock on the state for the current configuration
getused to download and update modules
graphused to generate a a graph
importused to import existing resources
initused to initilize a working directory
outputused to extract the value of an output variable
planused to create an execution plan
providersused to print information about providers (eg VMware, AWS, HyperV etc etc etc)
pushused to upload your configuration
refreshused to update the state of a file
showuseds to provide output from a state or plan file
stateused for advanced state management
taintused to mark resources as tainted
validateused to validate the syntax of terraform files
untaintused to unmark a resourse as tainted
workspaceused to manage workspaces
Type or VariableWhat it does
"var" prefixUser String Variable
Interpolate
"var.MAP["KEY"]User Map Variable
Value of Key
"${var.LIST}"Value of the list as a list
List elements by Index
"self.ATTRIBUTE"Own Resource
"TYPE.NAME.ATTRIBUTE"Other Resource
"data.TYPE.NAME.ATTRIBUTE"Data Source
MODULE.NAME.OUTPUT"Module outputs
"Count.FIELD"Count
"path.TYPE"Path
"terraform.FIELD"Terraform Meta

San Volume Controller (SVC) Cheat Sheet

Command ▾Common Arguments & DescriptionCommand Description
svcinfo lsclusterDisplays cluster members id, name, location, ip-address etcDisplay info about clusters
svcinfo lscontrollerDisplays controllers id, name etcDisplay info about controllers visible to the system
svcinfo lsfabricDisplays remote_wwpn, remote_nportid, id, node_name, local_wwpn, local_port etcDisplay connectivity between nodes and other controllers and hosts
svcinfo lshostDisplays controllers id, name etcDisplay info about controllers visible to the system
svcinfo lshostvdiskmaphost1 (Obtain a list of the virtual disks that are mapped (visible) to host1, including vdisk_id, vdisk_name, wwpn etc)Obtain a list of the virtual disks that are mapped (visible) to a given host
svcinfo lsmdiskDisplays id, name, status, mode, mdisk_grp_name etc for all MDisksDisplay info about MDisks visible to the cluster
svcinfo lsmdiskgrpDisplays id, name, status, mdisk_count, vdisk_count, capacity etc for all MDisk groupsDisplay info about MDisk groups visible to the cluster
svcinfo lsrcconsistgrpapp_CG1 (Displays a detailed view of consistency group app_CG1 including state, status and sync attributesDisplays a detailed view of Metro or Global Mirror consistency groups visible to the cluster
svcinfo lsrcrelationshipDisplays id, name, master_cluster_name, master_vdisk_name, consistency_group_name etcDisplay information about all the Metro Mirror relationships visible to the cluster
svcinfo lsvdiskDisplays id, name, io_group_name, status, mdisk_grp_id, mdisk_grp_name, capacity etc for all VDisksDisplay information about VDisks recognized by the cluster
svcinfo lsvdiskvdisk1 (Displays detailed information about vdisk1 including mdisk_grp_name and remote copy relationship RC_name)Display detailed information about a specific VDisk recognized by the cluster
svctask mkrcrelationship-master master_vdisk_name -aux aux_vdisk_name -cluster cluster_name -name data_1 (Creates a new rc relationship named data_1)Creates a new Metro or Global Mirror relationship with virtual disks (VDisks)
svctask mkvdisk-mdiskgrp 0 -iogrp 0 -size 50 -vtype striped -unit gb -name app1_1 (Create a vdisk named app1_1)Create a sequential, striped of image mode Vdisk
svctask mkvdiskhostmap-host host1 -scsi 1 app1_1 (Create a new mapping between vdisk app1_1 and host1 assigning SCSI LUN ID 1 to app1_1 on host1)Create a new mapping between a virtual disk and a host making the vdisk accessible for I/O to the specified host
svctask startrcconsistgrp-primary master -force (Start the consistency group copy process, specifying the copy direction (the master becomes the primary) even if the copy process leads to a temporary loss of consistency during synchronisation (-force))Start the Metro or Global Mirror consistency group copy process
svctask startrcrelationshiprc_rel_app1 (Start the remote copy relationship for relationship name rc_rel_app1)Starts the Metro Mirror or Global Mirror relationship copy process
svctask stoprcconsistgrp-access app_CG1 (Stops the copy process for consistency group app_CG1 and allows write access to consistent secondary VDisks in app_CG1 (-access))Stops the copy process for a Metro Mirror or Global Mirror consistency group