Friday, August 6, 2010

Adding EMC SAN LUNs to RHEL 4

Adding EMC clariion LUNs to RHEL 4. EMC powerpath installed. RHEL is using local disk for boot. This SAN is for storage.

))))) Using powerpath software to display devs from SAN. (((((

[root@jasco scsi]# powermt display dev=all
Pseudo name=emcpowerb
CLARiiON ID=APM04344461 [jasco]
Logical device ID=6003534353535062D32D454F11 [LUN 57]
state=alive; policy=CLAROpt; priority=0; queued-IOs=0
Owner: default=SP A, current=SP A       Array failover mode: 1
==============================================================================
---------------- Host ---------------   - Stor -   -- I/O Path -  -- Stats ---
###  HW Path                I/O Paths    Interf.   Mode    State  Q-IOs Errors
==============================================================================
   0 qla2xxx                   sdb       SP A5     active  alive      0      0
   0 qla2xxx                   sdd       SP B4     active  alive      0      0
   1 qla2xxx                   sdf       SP A4     active  alive      0      0
   1 qla2xxx                   sdh       SP B5     active  alive      0      0

Pseudo name=emcpowera
CLARiiON ID=APM04344461 [jasco]
Logical device ID=6003534353535062D32D454F11 [LUN 56]
state=alive; policy=CLAROpt; priority=0; queued-IOs=0
Owner: default=SP B, current=SP B       Array failover mode: 1
==============================================================================
---------------- Host ---------------   - Stor -   -- I/O Path -  -- Stats ---
###  HW Path                I/O Paths    Interf.   Mode    State  Q-IOs Errors
==============================================================================
   0 qla2xxx                   sda       SP A5     active  alive      0      0
   0 qla2xxx                   sdc       SP B4     active  alive      0      0
   1 qla2xxx                   sde       SP A4     active  alive      0      0
   1 qla2xxx                   sdg       SP B5     active  alive      0      0

))))) Fdisk shows the scis disk(a-h) paths on SAN that RHEL knows. none are partitions or have file systems yet.  (((((

[root@jasco scsi]# fdisk -l

Disk /dev/sda: 21.4 GB, 21474836480 bytes
64 heads, 32 sectors/track, 20480 cylinders
Units = cylinders of 2048 * 512 = 1048576 bytes

Disk /dev/sda doesn't contain a valid partition table

Disk /dev/sdb: 429.4 GB, 429496729600 bytes
255 heads, 63 sectors/track, 52216 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Disk /dev/sdb doesn't contain a valid partition table

Disk /dev/sdc: 21.4 GB, 21474836480 bytes
64 heads, 32 sectors/track, 20480 cylinders
Units = cylinders of 2048 * 512 = 1048576 bytes

Disk /dev/sdc doesn't contain a valid partition table

Disk /dev/sdd: 429.4 GB, 429496729600 bytes
255 heads, 63 sectors/track, 52216 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Disk /dev/sdd doesn't contain a valid partition table

Disk /dev/sde: 21.4 GB, 21474836480 bytes
64 heads, 32 sectors/track, 20480 cylinders
Units = cylinders of 2048 * 512 = 1048576 bytes

Disk /dev/sde doesn't contain a valid partition table

Disk /dev/sdf: 429.4 GB, 429496729600 bytes
255 heads, 63 sectors/track, 52216 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Disk /dev/sdf doesn't contain a valid partition table

Disk /dev/sdg: 21.4 GB, 21474836480 bytes
64 heads, 32 sectors/track, 20480 cylinders
Units = cylinders of 2048 * 512 = 1048576 bytes

Disk /dev/sdg doesn't contain a valid partition table

Disk /dev/sdh: 429.4 GB, 429496729600 bytes
255 heads, 63 sectors/track, 52216 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Disk /dev/sdh doesn't contain a valid partition table

Disk /dev/emcpowerb: 429.4 GB, 429496729600 bytes
255 heads, 63 sectors/track, 52216 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Disk /dev/emcpowerb doesn't contain a valid partition table

Disk /dev/emcpowera: 21.4 GB, 21474836480 bytes
64 heads, 32 sectors/track, 20480 cylinders
Units = cylinders of 2048 * 512 = 1048576 bytes

Disk /dev/emcpowera doesn't contain a valid partition table


))))) Let's create a new partion with fdisk using one of the san paths. We use /dev/sdh for the 
429GB LUN. (((((


[root@jasco scsi]# fdisk  /dev/sdh
Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel
Building a new DOS disklabel. Changes will remain in memory only,
until you decide to write them. After that, of course, the previous
content won't be recoverable.


The number of cylinders for this disk is set to 52216.
There is nothing wrong with that, but this is larger than 1024,
and could in certain setups cause problems with:
1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs
   (e.g., DOS FDISK, OS/2 FDISK)
Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)

Command (m for help): p

Disk /dev/sdh: 429.4 GB, 429496729600 bytes
255 heads, 63 sectors/track, 52216 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System

Command (m for help): n
Command action
   e   extended
   p   primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-52216, default 1):
Using default value 1
Last cylinder or +size or +sizeM or +sizeK (1-52216, default 52216):
Using default value 52216

Command (m for help): p

Disk /dev/sdh: 429.4 GB, 429496729600 bytes
255 heads, 63 sectors/track, 52216 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdh1               1       52216   419424988+  83  Linux

))))) Partition is created. Goto expert mode to align partition. (((((

Command (m for help): x

Expert command (m for help): b
Partition number (1-4): 1
New beginning of data (63-838850039, default 63): 128

Expert command (m for help): w
The partition table has been altered!

Calling ioctl() to re-read partition table.
Syncing disks.

))))) Create ext3 filesystem. After this mount the file system to the path or fstab if required. (((((

[root@jasco etc]# mke2fs -j /dev/emcpowera

Done.

No comments:

Post a Comment