Sometimes you need to do troubleshooting about storage connectivity but you don’t have access to datacenter or SAN switches and you need to shutdown one of HBA ports to check server side problem. If the port was a network adapter port, disabling was to easy but what about HBA port on operating system?
Possible Solutions About Disabling HBA Port on Server
You can disable a HBA port via:
- Disable PCI Device in BIOS utility or PCI Device setup utility (Server reboot is required).
- Disable connected switch port
- Disconnect the port by remove cable connection
- Disable port via FC driver
Disable HBA Port via FC Driver
Disabling devices is too easy on Windows but Linux has own ways for administration. The below commands will works if you have QLogic adapter on RHEL/CentOS/Oracle Linux. Other vendors may have same ways on their FC driver.
Unbind HBA Port
First, you should have each port’s PCI bus number. So you can find that by the below commands:
ls -l /sys/class/fc_host
The output would be something like the below:
Run the below command to unbind and disabling port, put PCI bus ID of each port in a single command:
echo “0000:3c:00.0” > /sys/bus/pci/drivers/qla2xxx/unbind
Bind HBA Port
To active port again:
echo “0000:3c:00.0” > /sys/bus/pci/drivers/qla2xxx/bind