Users Guide
Table Of Contents
- Table of Contents
- Chapter 1: Introduction
- Chapter 2: Installing and Uninstalling
- Chapter 3: Configuration
- 3.1 FC Driver Configuration
- 3.2 vPort Configuration
- 3.3 FC Driver Performance Tuning
- Chapter 4: Configuring NVMe over FC
- Chapter 5: Troubleshooting
- Appendix A: FCP Driver BlockGuard Functionality
- Appendix B: Configuring NVMe over FC on a Target
- Appendix C: Native NVMe Multipathing
- Appendix D: Trunking Support
- Appendix E: FC-SP-2 Authentication (DH-CHAP) Support
- Appendix F: ARM Support
Broadcom DRVLin-UG128-100
21
Emulex Drivers for Linux User Guide
3.1.2.3 Configuring Parameters with the sysfs Command
sysfs is a virtual file system that exposes the structure of the system. It also includes interfaces to driver parameters
through which the FC driver parameters can be viewed and modified. Because these interfaces are available only after driver
load, only dynamic FC driver parameters can be changed. However, both static and dynamic FC driver parameters can be
read through sysfs.
NOTE: The following information applies to sysfs:
sysfs changes exist only during driver load and are lost when the FC driver is unloaded or the system is
rebooted.
Driver parameters that are set through module parameters are global; setting them through sysfs is on a
SCSI-host (adapter port) basis.
For example:
echo 0x7f > /sys/class/scsi_host/host7/lpfc_log_verbose only affects host 7.
modprobe lpfc lpfc_log_verbose=0x7F applies to all SCSI hosts (ports) managed by the FC driver.
Viewing Parameters with sysfs:
The sysfs file system is mounted and available as /sys. You must first identify the scsi_host that represents the adapter
for which you want to modify the FC driver parameters. All scsi_hosts bound to the FC driver can be viewed with the
following command:
ls -d /sys/bus/pci/drivers/lpfc/*/host*
Assuming that you are interested in adapter scsi_host 7, you can list the FC driver parameters for this particular adapter
as follows:
ls -l /sys/class/scsi_host/host7/lpfc*
An example output follows:
-r--r--r-- 1 root root 4096 Feb 28 17:03 /sys/class/scsi_host/host7/lpfc_ack0
-r--r--r-- 1 root root 4096 Feb 28 17:03 /sys/class/scsi_host/host7/lpfc_fcp_class
-rw-r--r-- 1 root root 4096 Feb 28 17:03 /sys/class/scsi_host/host7/lpfc_fdmi_on
-r--r--r-- 1 root root 4096 Feb 28 17:03 /sys/class/scsi_host/host7/lpfc_link_speed
-rw-r--r-- 1 root root 4096 Feb 28 15:34 /sys/class/scsi_host/host7/lpfc_log_verbose
-r--r--r-- 1 root root 4096 Feb 28 17:03 /sys/class/scsi_host/host7/lpfc_lun_queue_depth
-rw-r--r-- 1 root root 4096 Feb 28 17:03 /sys/class/scsi_host/host7/lpfc_max_luns
-rw-r--r-- 1 root root 4096 Feb 28 17:03 /sys/class/scsi_host/host7/lpfc_devloss_tmo
-rw-r--r-- 1 root root 4096 Feb 28 17:03 /sys/class/scsi_host/host7/lpfc_scan_down
-r--r--r-- 1 root root 4096 Feb 28 17:03 /sys/class/scsi_host/host7/lpfc_topology
-rw-r--r-- 1 root root 4096 Feb 28 17:03 /sys/class/scsi_host/host7/lpfc_use_adisc
Temporary Configuration Parameters with sysfs:
In the previous example, notice that the FC driver parameters are available as files. Reading a file displays the current value
of a driver parameter. If the permissions allow it, you can write a value to the file and it will take effect immediately.
Reading the lpfc_log_verbose file might show that its value is 0:
cat /sys/class/scsi_host/host7/lpfc_log_verbose
0