GNU/Linux >> Tutoriales Linux >  >> Cent OS

Cómo deshabilitar o habilitar un HBA sin reiniciar en CentOS/RHEL

Pregunta :¿Cómo habilitar o deshabilitar los puertos HBA temporalmente, sin reiniciar?

1. Localice la dirección HBA en el bus PCI:

# lspci -k
...
19:00.0 Fibre Channel: QLogic Corp. ISP2532-based 8Gb Fibre Channel to PCI Express HBA (rev 02)
    Subsystem: QLogic Corp. Device 0171
    Kernel driver in use: qla2xxx
19:00.1 Fibre Channel: QLogic Corp. ISP2532-based 8Gb Fibre Channel to PCI Express HBA (rev 02)
    Subsystem: QLogic Corp. Device 0171
    Kernel driver in use: qla2xxx
...

Método alternativo para dispositivos de bloque:

– Los dispositivos de bloque tienen su dirección de bus PCI disponible por el nombre del disco:

# ls -l /dev/disk/by-path/ | grep -v part
lrwxrwxrwx 1 root root  9 Jan  8 04:03 pci-0000:19:00.0-fc-0x21000024ff49572c-lun-0 -> ../../sdx
lrwxrwxrwx 1 root root  9 Dec 29 10:36 pci-0000:19:00.0-fc-0x21000024ff49572c-lun-1 -> ../../sdy
lrwxrwxrwx 1 root root 10 Jan  8 04:07 pci-0000:19:00.0-fc-0x21000024ff49572c-lun-10 -> ../../sdbx
lrwxrwxrwx 1 root root 10 Jan  8 04:07 pci-0000:19:00.0-fc-0x21000024ff49572c-lun-11 -> ../../sdby
lrwxrwxrwx 1 root root 10 Jan  8 04:07 pci-0000:19:00.0-fc-0x21000024ff49572c-lun-12 -> ../../sdbz
lrwxrwxrwx 1 root root  9 Dec 29 10:36 pci-0000:19:00.0-fc-0x21000024ff49572c-lun-2 -> ../../sdz

2. Desconecte el dispositivo PCI del bus PCI usando el nombre del controlador del dispositivo y la dirección del bus PCI que encontró anteriormente:

# echo '[pci-device-id]' > /sys/bus/pci/drivers/[pci-driver-name]/unbind

Como ejemplo, desconecte el dispositivo /dev/sdy del PCIbus:

# echo '0000:19:00.0' > /sys/bus/pci/drivers/qla2xxx/unbind

3. Conecte el dispositivo al controlador:

# echo "[pci-device-id]" > /sys/bus/pci/drivers/[pci_driver_name]/bind

Como ejemplo, haga que el dispositivo PCI 0000:19:00.0 sea controlado por el controlador qla2xxx:

# echo '0000:19:00.0' > /sys/bus/pci/drivers/qla2xxx/bind


Cent OS
  1. CentOS / RHEL 6,7:Cómo habilitar o deshabilitar el servicio XDMCP (GDM)

  2. Cómo habilitar IPv6 en CentOS / RHEL 7

  3. Cómo deshabilitar IPv6 en CentOS / RHEL 5

  4. Cómo habilitar IPv6 en CentOS / RHEL 5

  5. Cómo deshabilitar lvmetad en CentOS/RHEL

Cómo habilitar SELinux en CentOS/RHEL 7

RHEL 8/CentOS 8 activar/desactivar IPv6

Cómo instalar TeamViewer en CentOS 6 / RHEL 6

Cómo deshabilitar IPv6 en CentOS 7 / RHEL 7

Cómo instalar MariaDB en CentOS 8 / RHEL 8

Cómo habilitar/deshabilitar los modos SELinux en RHEL/CentOS