Назад | Перейти на главную страницу

Монтирование диска из SAN (RHEL 5.9)

Администратор хранилища сказал мне, что он поставил на мой сервер диск емкостью 3 ТБ из SAN, и меня попросили смонтировать его. Единственная информация, которую я знаю, это то, что он находится на LUN 1 и что размер диска 3 ТБ.

Настроен режим Multipath, и у меня установлены диски QLogic. Я не уверен, что теперь делать ... дисков так много, как я могу найти подходящий для монтирования? Я сказал специалисту по хранению данных, что вижу все в SAN, но только что получил от него «Я не знаю Linux». Не знаю, какие вопросы задать, чтобы понять, какой диск монтировать.

Это результат fsdisk -l:

Disk /dev/cciss/c0d0: 299.9 GB, 299959511040 bytes
255 heads, 63 sectors/track, 36468 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

           Device Boot      Start         End      Blocks   Id  System
/dev/cciss/c0d0p1   *           1          13      104391   83  Linux
/dev/cciss/c0d0p2              14       36468   292824787+  8e  Linux LVM

Disk /dev/dm-0: 32.2 GB, 32212254720 bytes
255 heads, 63 sectors/track, 3916 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes


Disk /dev/dm-1: 267.6 GB, 267630149632 bytes
255 heads, 63 sectors/track, 32537 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes


Disk /dev/sda: 107.3 GB, 107374182400 bytes
255 heads, 63 sectors/track, 13054 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdb: 3298.5 GB, 3298534883328 bytes
255 heads, 63 sectors/track, 401024 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1               1      267350  2147483647+  ee  EFI GPT

Disk /dev/sdc: 214.7 GB, 214748364800 bytes
255 heads, 63 sectors/track, 26108 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdd: 107.3 GB, 107374182400 bytes
255 heads, 63 sectors/track, 13054 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System

Disk /dev/sde: 3298.5 GB, 3298534883328 bytes
255 heads, 63 sectors/track, 401024 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sde1               1      267350  2147483647+  ee  EFI GPT

Disk /dev/sdf: 214.7 GB, 214748364800 bytes
255 heads, 63 sectors/track, 26108 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdg: 107.3 GB, 107374182400 bytes
255 heads, 63 sectors/track, 13054 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdh: 3298.5 GB, 3298534883328 bytes
255 heads, 63 sectors/track, 401024 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdh1               1      267350  2147483647+  ee  EFI GPT

Disk /dev/sdi: 214.7 GB, 214748364800 bytes
255 heads, 63 sectors/track, 26108 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdj: 107.3 GB, 107374182400 bytes
255 heads, 63 sectors/track, 13054 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdk: 3298.5 GB, 3298534883328 bytes
255 heads, 63 sectors/track, 401024 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdk1               1      267350  2147483647+  ee  EFI GPT

Disk /dev/sdl: 214.7 GB, 214748364800 bytes
255 heads, 63 sectors/track, 26108 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdm: 107.3 GB, 107374182400 bytes
255 heads, 63 sectors/track, 13054 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdn: 3298.5 GB, 3298534883328 bytes
255 heads, 63 sectors/track, 401024 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdn1               1      267350  2147483647+  ee  EFI GPT

Disk /dev/sdo: 214.7 GB, 214748364800 bytes
255 heads, 63 sectors/track, 26108 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdp: 107.3 GB, 107374182400 bytes
255 heads, 63 sectors/track, 13054 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdq: 3298.5 GB, 3298534883328 bytes
255 heads, 63 sectors/track, 401024 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdq1               1      267350  2147483647+  ee  EFI GPT

Disk /dev/sdr: 214.7 GB, 214748364800 bytes
255 heads, 63 sectors/track, 26108 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System

Disk /dev/sds: 107.3 GB, 107374182400 bytes
255 heads, 63 sectors/track, 13054 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdt: 3298.5 GB, 3298534883328 bytes
255 heads, 63 sectors/track, 401024 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdt1               1      267350  2147483647+  ee  EFI GPT

Disk /dev/sdu: 214.7 GB, 214748364800 bytes
255 heads, 63 sectors/track, 26108 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdv: 107.3 GB, 107374182400 bytes
255 heads, 63 sectors/track, 13054 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdw: 3298.5 GB, 3298534883328 bytes
255 heads, 63 sectors/track, 401024 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdw1               1      267350  2147483647+  ee  EFI GPT

Disk /dev/sdx: 214.7 GB, 214748364800 bytes
255 heads, 63 sectors/track, 26108 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdy: 107.3 GB, 107374182400 bytes
255 heads, 63 sectors/track, 13054 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdz: 3298.5 GB, 3298534883328 bytes
255 heads, 63 sectors/track, 401024 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdz1               1      267350  2147483647+  ee  EFI GPT

Disk /dev/sdaa: 214.7 GB, 214748364800 bytes
255 heads, 63 sectors/track, 26108 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdab: 107.3 GB, 107374182400 bytes
255 heads, 63 sectors/track, 13054 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdac: 3298.5 GB, 3298534883328 bytes
255 heads, 63 sectors/track, 401024 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System
/dev/sdac1               1      267350  2147483647+  ee  EFI GPT

Disk /dev/sdad: 214.7 GB, 214748364800 bytes
255 heads, 63 sectors/track, 26108 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdae: 107.3 GB, 107374182400 bytes
255 heads, 63 sectors/track, 13054 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdaf: 3298.5 GB, 3298534883328 bytes
255 heads, 63 sectors/track, 401024 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System
/dev/sdaf1               1      267350  2147483647+  ee  EFI GPT

Disk /dev/sdag: 214.7 GB, 214748364800 bytes
255 heads, 63 sectors/track, 26108 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdah: 107.3 GB, 107374182400 bytes
255 heads, 63 sectors/track, 13054 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdai: 3298.5 GB, 3298534883328 bytes
255 heads, 63 sectors/track, 401024 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System
/dev/sdai1               1      267350  2147483647+  ee  EFI GPT

Disk /dev/sdaj: 214.7 GB, 214748364800 bytes
255 heads, 63 sectors/track, 26108 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdak: 107.3 GB, 107374182400 bytes
255 heads, 63 sectors/track, 13054 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdal: 3298.5 GB, 3298534883328 bytes
255 heads, 63 sectors/track, 401024 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System
/dev/sdal1               1      267350  2147483647+  ee  EFI GPT

Disk /dev/sdam: 214.7 GB, 214748364800 bytes
255 heads, 63 sectors/track, 26108 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdan: 107.3 GB, 107374182400 bytes
255 heads, 63 sectors/track, 13054 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdao: 3298.5 GB, 3298534883328 bytes
255 heads, 63 sectors/track, 401024 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System
/dev/sdao1               1      267350  2147483647+  ee  EFI GPT

Disk /dev/sdap: 214.7 GB, 214748364800 bytes
255 heads, 63 sectors/track, 26108 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdaq: 107.3 GB, 107374182400 bytes
255 heads, 63 sectors/track, 13054 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdar: 3298.5 GB, 3298534883328 bytes
255 heads, 63 sectors/track, 401024 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System
/dev/sdar1               1      267350  2147483647+  ee  EFI GPT

Disk /dev/sdas: 214.7 GB, 214748364800 bytes
255 heads, 63 sectors/track, 26108 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdat: 107.3 GB, 107374182400 bytes
255 heads, 63 sectors/track, 13054 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdau: 3298.5 GB, 3298534883328 bytes
255 heads, 63 sectors/track, 401024 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System
/dev/sdau1               1      267350  2147483647+  ee  EFI GPT

Disk /dev/sdav: 214.7 GB, 214748364800 bytes
255 heads, 63 sectors/track, 26108 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot      Start         End      Blocks   Id  System

Disk /dev/dm-2: 214.7 GB, 214748364800 bytes
255 heads, 63 sectors/track, 26108 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

     Device Boot      Start         End      Blocks   Id  System

Disk /dev/dm-3: 3298.5 GB, 3298534883328 bytes
255 heads, 63 sectors/track, 401024 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

     Device Boot      Start         End      Blocks   Id  System
/dev/dm-3p1               1      267350  2147483647+  ee  EFI GPT

Disk /dev/dm-4: 107.3 GB, 107374182400 bytes
255 heads, 63 sectors/track, 13054 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

     Device Boot      Start         End      Blocks   Id  System

fc_hosts:

 cat /sys/class/fc_host/host[1-4]/port_name 
    0x500143802424eb38 
    0x500143802424eb3a 
    0x500143802424ec18 
    0x500143802424ec1a 

Многолучевость:

 # multipath -ll
    mpath2 (360a98000572d505a6834737741386576) dm-4 NETAPP,LUN
    size=100G features='3 queue_if_no_path pg_init_retries 50' hwhandler='0' wp=rw
    |-+- policy='round-robin 0' prio=4 status=active
    | |- 4:0:2:0 sdaq       66:160 active ready running
    | |- 4:0:1:0 sdan       66:112 active ready running
    | |- 3:0:3:0 sdah       66:16  active ready running
    | |- 3:0:1:0 sdab       65:176 active ready running
    | |- 1:0:3:0 sdv        65:80  active ready running
    | |- 1:0:1:0 sdp        8:240  active ready running
    | |- 2:0:2:0 sdg        8:96   active ready running
    | `- 2:0:1:0 sdd        8:48   active ready running
    `-+- policy='round-robin 0' prio=1 status=enabled
      |- 4:0:3:0 sdat       66:208 active ready running
      |- 4:0:0:0 sdak       66:64  active ready running
      |- 3:0:2:0 sdae       65:224 active ready running
      |- 3:0:0:0 sdy        65:128 active ready running
      |- 1:0:2:0 sds        65:32  active ready running
      |- 1:0:0:0 sdm        8:192  active ready running
      |- 2:0:3:0 sdj        8:144  active ready running
      `- 2:0:0:0 sda        8:0    active ready running
    mpath1 (360a98000572d505a6834737741434372) dm-3 NETAPP,LUN
    size=3.0T features='3 queue_if_no_path pg_init_retries 50' hwhandler='0' wp=rw
    |-+- policy='round-robin 0' prio=4 status=active
    | |- 4:0:2:1 sdar       66:176 active ready running
    | |- 4:0:1:1 sdao       66:128 active ready running
    | |- 3:0:3:1 sdai       66:32  active ready running
    | |- 3:0:1:1 sdac       65:192 active ready running
    | |- 1:0:3:1 sdw        65:96  active ready running
    | |- 1:0:1:1 sdq        65:0   active ready running
    | |- 2:0:2:1 sdh        8:112  active ready running
    | `- 2:0:1:1 sde        8:64   active ready running
    `-+- policy='round-robin 0' prio=1 status=enabled
      |- 4:0:3:1 sdau       66:224 active ready running
      |- 4:0:0:1 sdal       66:80  active ready running
      |- 3:0:2:1 sdaf       65:240 active ready running
      |- 3:0:0:1 sdz        65:144 active ready running
      |- 1:0:2:1 sdt        65:48  active ready running
      |- 1:0:0:1 sdn        8:208  active ready running
      |- 2:0:3:1 sdk        8:160  active ready running
      `- 2:0:0:1 sdb        8:16   active ready running
    mpath0 (360a98000572d505a6834737741457870) dm-2 NETAPP,LUN
    size=200G features='3 queue_if_no_path pg_init_retries 50' hwhandler='0' wp=rw
    |-+- policy='round-robin 0' prio=4 status=active
    | |- 4:0:2:2 sdas       66:192 active ready running
    | |- 4:0:1:2 sdap       66:144 active ready running
    | |- 3:0:3:2 sdaj       66:48  active ready running
    | |- 3:0:1:2 sdad       65:208 active ready running
    | |- 1:0:3:2 sdx        65:112 active ready running
    | |- 1:0:1:2 sdr        65:16  active ready running
    | |- 2:0:2:2 sdi        8:128  active ready running
    | `- 2:0:1:2 sdf        8:80   active ready running
    `-+- policy='round-robin 0' prio=1 status=enabled
      |- 4:0:3:2 sdav       66:240 active ready running
      |- 4:0:0:2 sdam       66:96  active ready running
      |- 3:0:2:2 sdag       66:0   active ready running
      |- 3:0:0:2 sdaa       65:160 active ready running
      |- 1:0:2:2 sdu        65:64  active ready running
      |- 1:0:0:2 sdo        8:224  active ready running
      |- 2:0:3:2 sdl        8:176  active ready running
      `- 2:0:0:2 sdc        8:32   active ready running

dmsetup:

# dmsetup ls 
mpath2  (253, 4) 
mpath1  (253, 3) 
mpath0  (253, 2) 
VolGroup00-LogVol01     (253, 1) 
VolGroup00-LogVol00     (253, 0)

Мне никогда раньше не приходилось делать ничего подобного, поэтому, пожалуйста, не бейте меня. Я просто ищу, какие вопросы задать администратору хранилища и какие команды найти подходящий диск для форматирования и монтирования.

Не использовать /dev/sd*, поскольку они сопоставляются только с отдельными путями.

Использовать /dev/mpath* устройств (или как показано на выходе multipath -l).

Выход multipath -ll показывает, что диск, который вы хотите использовать, /dev/mapper/mpath1

Создайте на нем свою файловую систему, отформатируйте ее, разбейте на разделы или как хотите. Просто не использовать /dev/sd* устройств.

глядя на ваш результат,

mpath1 (360a98000572d505a6834737741434372) dm-3 NETAPP,LUN
size=3.0T features='3 queue_if_no_path pg_init_retries 50' hwhandler='0' wp=rw
|-+- policy='round-robin 0' prio=4 status=active
| |- 4:0:2:1 sdar       66:176 active ready running
| |- 4:0:1:1 sdao       66:128 active ready running
| |- 3:0:3:1 sdai       66:32  active ready running
| |- 3:0:1:1 sdac       65:192 active ready running
| |- 1:0:3:1 sdw        65:96  active ready running
| |- 1:0:1:1 sdq        65:0   active ready running
| |- 2:0:2:1 sdh        8:112  active ready running
| `- 2:0:1:1 sde        8:64   active ready running
`-+- policy='round-robin 0' prio=1 status=enabled
  |- 4:0:3:1 sdau       66:224 active ready running
  |- 4:0:0:1 sdal       66:80  active ready running
  |- 3:0:2:1 sdaf       65:240 active ready running
  |- 3:0:0:1 sdz        65:144 active ready running
  |- 1:0:2:1 sdt        65:48  active ready running
  |- 1:0:0:1 sdn        8:208  active ready running
  |- 2:0:3:1 sdk        8:160  active ready running
  `- 2:0:0:1 sdb        8:16   active ready running

устройства, которые составляют mpath1 представляют собой отдельные пути к одним и тем же дискам (multipathd выясняет это, глядя на WWID и т. д.). Что означает, что все sd* диски в выводе указывают на одно и то же устройство, но используют разные пути для его достижения. Это сделано из соображений избыточности, а иногда и из соображений производительности.