Removing Paths
You have a few different methods for removing a path. In this demonstration, I’ll use the following format where hdiskX is the hdisk number, fscsiX is the fibre adapter the path hangs off and connection is the connection string that identifies the path:
rmpath –dl <hdiskX> -p <fscsiX> -w <connection>
The connection string is taken from the lsattr and lscfg command output when run against the hdisk path to remove. The first part of the string is the ww_name and the second is part of the string is taken from the location code of the hdisk. We will look at these in more detail to follow.
Listing the missing paths can be achieved using the following:
# lspath |grep –i missing
Missing hdisk20 fscsi0
Missing hdisk20 fscsi0
Missing hdisk20 fscsi1
Missing hdisk20 fscsi1
The output shows we have four missing paths. For this demonstration, we will stick with only four paths, though in reality it would be higher depending on the number of disks and paths to each disk. Looking at the path locations in more detail, again using lspath but specifying for each hdisk, let’s get the name, parent connection and the status returned with:
# lspath -l hdisk20 -H -F "name:parent:connection:status"
hdisk20:fscsi0:5001738065920143,6000000000000:Missing
hdisk20:fscsi0:5001738065920151,6000000000000:Missing
hdisk20:fscsi1:5001738065920183,6000000000000:Missing
hdisk20:fscsi1:5001738065920171,6000000000000:Missing
Note in the output the connection string is in two parts separated by a comma. This gives us all the information we need to remove a path. I could now use the following to remove the first path in the output:
rmpath –dl hdisk20 –p fscsi0 –w 5001738065920143,6000000000000