First we see the disks that we have:
# ioscan -funC disk Class I H/W Path Driver S/W State H/W Type Description ================================================================== disk 1 0/1/1/0.0.0.0.0 sdisk CLAIMED DEVICE HP EH0146FAWJB /dev/dsk/c0t0d0 /dev/rdsk/c0t0d0 disk 0 0/1/1/0.0.0.1.0 sdisk CLAIMED DEVICE HP EH0146FAWJB /dev/dsk/c0t1d0 /dev/dsk/c0t1d0s2 /dev/rdsk/c0t1d0 /dev/rdsk/c0t1d0s2 /dev/dsk/c0t1d0s1 /dev/dsk/c0t1d0s3 /dev/rdsk/c0t1d0s1/dev/rdsk/c0t1d0s3 #
Hence we see that the disk that is in use c0t1d0 (is partitioned) and c0t0d0 is available to us to make the mirror. We can also confirm seeing it for example in /dev/dsk
# cd /dev/dsk # ls -l total 0 brw-r----- 1 bin sys 31 0x000000 Aug 15 15:51 c0t0d0 brw-r----- 1 bin sys 31 0x001000 Aug 15 15:51 c0t1d0 brw-r----- 1 bin sys 31 0x001001 Aug 15 15:51 c0t1d0s1 brw-r----- 1 bin sys 31 0x001002 Aug 15 15:51 c0t1d0s2 brw-r----- 1 bin sys 31 0x001003 Aug 15 15:51 c0t1d0s3
once we know which is the disk, we looked at naming agile
# ioscan -m dsf Persistent DSF Legacy DSF(s) ======================================== /dev/rdisk/disk2 /dev/rdsk/c0t0d0 /dev/rdisk/disk3 /dev/rdsk/c0t1d0 /dev/rdisk/disk3_p1 /dev/rdsk/c0t1d0s1 /dev/rdisk/disk3_p2 /dev/rdsk/c0t1d0s2 /dev/rdisk/disk3_p3 /dev/rdsk/c0t1d0s3 #
as we see the disk c0t0d0 corresponds to disk2. Once you have located the disk, we begin to create the partitions. We must first create the partition configuration file.
# echo "3 EFI 500MB HPUX 100% HPSP 400MB" > /tmp/idf
values represent a boot disk with 3 partiones, one EFI, one HPUX and one HPSP. Once you create the file we create the partitions on the disk with idisk
# idisk -f /tmp/idf -w /dev/rdisk/disk2 idisk version: 1.44 ********************** WARNING *********************** If you continue you may destroy all data on this disk. Do you wish to continue(yes/no)? yes EFI Primary Header: Signature = EFI PART Revision = 0x10000 HeaderSize = 0x5c HeaderCRC32 = 0xd7322519 MyLbaLo = 0x1 MyLbaHi = 0x0 AlternateLbaLo = 0x1117732f AlternateLbaHi = 0x0 FirstUsableLbaLo = 0x40 FirstUsableLbaHi = 0x0 LastUsableLbaLo = 0x111772ff LastUsableLbaHi = 0x0 Disk GUID = 766060f4-dd50-11e0-8000-d6217b60e588 PartitionEntryLbaLo = 0x2 PartitionEntryLbaHi = 0x0 NumberOfPartitionEntries = 0xc SizeOfPartitionEntry = 0x80 PartitionEntryArrayCRC32 = 0x935b7d87 Primary Partition Table (in 512 byte blocks): Partition 1 (EFI): Partition Type GUID = c12a7328-f81f-11d2-ba4b-00a0c93ec93b Unique Partition GUID = 766062fc-dd50-11e0-8000-d6217b60e588 Starting Lba Lo = 0x40 Starting Lba Hi = 0x0 Ending Lba Lo = 0xf9fff Ending Lba Hi = 0x0 Partition 2 (HP-UX): Partition Type GUID = 75894c1e-3aeb-11d3-b7c1-7b03a0000000 Unique Partition GUID = 76606310-dd50-11e0-8000-d6217b60e588 Starting Lba Lo = 0xfa000 Starting Lba Hi = 0x0 Ending Lba Lo = 0x110af7ff Ending Lba Hi = 0x0 Partition 3 (HPSP): Partition Type GUID = e2a1e728-32e3-11d6-a682-7b03a0000000 Unique Partition GUID = 7660631a-dd50-11e0-8000-d6217b60e588 Starting Lba Lo = 0x110af800 Starting Lba Hi = 0x0 Ending Lba Lo = 0x111772ff Ending Lba Hi = 0x0 EFI Alternate Header: Signature = EFI PART Revision = 0x10000 HeaderSize = 0x5c HeaderCRC32 = 0xfbcf546d MyLbaLo = 0x1117732f MyLbaHi = 0x0 AlternateLbaLo = 0x1 AlternateLbaHi = 0x0 FirstUsableLbaLo = 0x40 FirstUsableLbaHi = 0x0 LastUsableLbaLo = 0x111772ff LastUsableLbaHi = 0x0 Disk GUID = 766060f4-dd50-11e0-8000-d6217b60e588 PartitionEntryLbaLo = 0x1117730f PartitionEntryLbaHi = 0x0 NumberOfPartitionEntries = 0xc SizeOfPartitionEntry = 0x80 PartitionEntryArrayCRC32 = 0x935b7d87 Alternate Partition Table (in 512 byte blocks): Partition 1 (EFI): Partition Type GUID = c12a7328-f81f-11d2-ba4b-00a0c93ec93b Unique Partition GUID = 766062fc-dd50-11e0-8000-d6217b60e588 Starting Lba Lo = 0x40 Starting Lba Hi = 0x0 Ending Lba Lo = 0xf9fff Ending Lba Hi = 0x0 Partition 2 (HP-UX): Partition Type GUID = 75894c1e-3aeb-11d3-b7c1-7b03a0000000 Unique Partition GUID = 76606310-dd50-11e0-8000-d6217b60e588 Starting Lba Lo = 0xfa000 Starting Lba Hi = 0x0 Ending Lba Lo = 0x110af7ff Ending Lba Hi = 0x0 Partition 3 (HPSP): Partition Type GUID = e2a1e728-32e3-11d6-a682-7b03a0000000 Unique Partition GUID = 7660631a-dd50-11e0-8000-d6217b60e588 Starting Lba Lo = 0x110af800 Starting Lba Hi = 0x0 Ending Lba Lo = 0x111772ff Ending Lba Hi = 0x0 Legacy MBR (MBR Signatures in little endian): MBR Signature = 0xa4606076 Protective MBR
once partitioned we check it
[ad#enlaces-horizontal]
# idisk /dev/rdisk/disk2 idisk version: 1.44 EFI Primary Header: Signature = EFI PART Revision = 0x10000 HeaderSize = 0x5c HeaderCRC32 = 0xd7322519 MyLbaLo = 0x1 MyLbaHi = 0x0 AlternateLbaLo = 0x1117732f AlternateLbaHi = 0x0 FirstUsableLbaLo = 0x40 FirstUsableLbaHi = 0x0 LastUsableLbaLo = 0x111772ff LastUsableLbaHi = 0x0 Disk GUID = 766060f4-dd50-11e0-8000-d6217b60e588 PartitionEntryLbaLo = 0x2 PartitionEntryLbaHi = 0x0 NumberOfPartitionEntries = 0xc SizeOfPartitionEntry = 0x80 PartitionEntryArrayCRC32 = 0x935b7d87 Primary Partition Table (in 512 byte blocks): Partition 1 (EFI): Partition Type GUID = c12a7328-f81f-11d2-ba4b-00a0c93ec93b Unique Partition GUID = 766062fc-dd50-11e0-8000-d6217b60e588 Starting Lba Lo = 0x40 Starting Lba Hi = 0x0 Ending Lba Lo = 0xf9fff Ending Lba Hi = 0x0 Partition 2 (HP-UX): Partition Type GUID = 75894c1e-3aeb-11d3-b7c1-7b03a0000000 Unique Partition GUID = 76606310-dd50-11e0-8000-d6217b60e588 Starting Lba Lo = 0xfa000 Starting Lba Hi = 0x0 Ending Lba Lo = 0x110af7ff Ending Lba Hi = 0x0 Partition 3 (HPSP): Partition Type GUID = e2a1e728-32e3-11d6-a682-7b03a0000000 Unique Partition GUID = 7660631a-dd50-11e0-8000-d6217b60e588 Starting Lba Lo = 0x110af800 Starting Lba Hi = 0x0 Ending Lba Lo = 0x111772ff Ending Lba Hi = 0x0 EFI Alternate Header: Signature = EFI PART Revision = 0x10000 HeaderSize = 0x5c HeaderCRC32 = 0xfbcf546d MyLbaLo = 0x1117732f MyLbaHi = 0x0 AlternateLbaLo = 0x1 AlternateLbaHi = 0x0 FirstUsableLbaLo = 0x40 FirstUsableLbaHi = 0x0 LastUsableLbaLo = 0x111772ff LastUsableLbaHi = 0x0 Disk GUID = 766060f4-dd50-11e0-8000-d6217b60e588 PartitionEntryLbaLo = 0x1117730f PartitionEntryLbaHi = 0x0 NumberOfPartitionEntries = 0xc SizeOfPartitionEntry = 0x80 PartitionEntryArrayCRC32 = 0x935b7d87 Alternate Partition Table (in 512 byte blocks): Partition 1 (EFI): Partition Type GUID = c12a7328-f81f-11d2-ba4b-00a0c93ec93b Unique Partition GUID = 766062fc-dd50-11e0-8000-d6217b60e588 Starting Lba Lo = 0x40 Starting Lba Hi = 0x0 Ending Lba Lo = 0xf9fff Ending Lba Hi = 0x0 Partition 2 (HP-UX): Partition Type GUID = 75894c1e-3aeb-11d3-b7c1-7b03a0000000 Unique Partition GUID = 76606310-dd50-11e0-8000-d6217b60e588 Starting Lba Lo = 0xfa000 Starting Lba Hi = 0x0 Ending Lba Lo = 0x110af7ff Ending Lba Hi = 0x0 Partition 3 (HPSP): Partition Type GUID = e2a1e728-32e3-11d6-a682-7b03a0000000 Unique Partition GUID = 7660631a-dd50-11e0-8000-d6217b60e588 Starting Lba Lo = 0x110af800 Starting Lba Hi = 0x0 Ending Lba Lo = 0x111772ff Ending Lba Hi = 0x0 Legacy MBR (MBR Signatures in little endian): MBR Signature = 0xa4606076 Protective MBR #
and once partitioned, we create the device files
[ad#enlaces-horizontal]
# insf -e -H 0/1/1/0.0.0.0.0 insf: Installing special files for sdisk instance 1 address 0/1/1/0.0.0.0.0 # ls -l total 0 brw-r----- 1 bin sys 31 0x000000 Aug 15 15:51 c0t0d0 brw-r----- 1 bin sys 31 0x000001 Sep 12 17:10 c0t0d0s1 brw-r----- 1 bin sys 31 0x000002 Sep 12 17:10 c0t0d0s2 brw-r----- 1 bin sys 31 0x000003 Sep 12 17:10 c0t0d0s3 brw-r----- 1 bin sys 31 0x001000 Aug 15 15:51 c0t1d0 brw-r----- 1 bin sys 31 0x001001 Aug 15 15:51 c0t1d0s1 brw-r----- 1 bin sys 31 0x001002 Aug 15 15:51 c0t1d0s2 brw-r----- 1 bin sys 31 0x001003 Aug 15 15:51 c0t1d0s3 #
and now we can see the partitions s1, s2 and s3. To see it in nomenclature agile
# ioscan -fnNC disk Class I H/W Path Driver S/W State H/W Type Description =================================================================== disk 2 64000/0xfa00/0x0 esdisk CLAIMED DEVICE HP EH0146FAWJB /dev/disk/disk2 /dev/rdisk/disk2 disk 3 64000/0xfa00/0x1 esdisk CLAIMED DEVICE HP EH0146FAWJB /dev/disk/disk3 /dev/disk/disk3_p2 /dev/rdisk/disk3 /dev/rdisk/disk3_p2 /dev/disk/disk3_p1 /dev/disk/disk3_p3 /dev/rdisk/disk3_p1 /dev/rdisk/disk3_p3 # insf -e -H 64000/0xfa00/0x0 insf: Installing special files for esdisk instance 2 address 64000/0xfa00/0x0 # ioscan -fnNC disk Class I H/W Path Driver S/W State H/W Type Description =================================================================== disk 2 64000/0xfa00/0x0 esdisk CLAIMED DEVICE HP EH0146FAWJB /dev/disk/disk2 /dev/disk/disk2_p2 /dev/rdisk/disk2 /dev/rdisk/disk2_p2 /dev/disk/disk2_p1 /dev/disk/disk2_p3 /dev/rdisk/disk2_p1 /dev/rdisk/disk2_p3 disk 3 64000/0xfa00/0x1 esdisk CLAIMED DEVICE HP EH0146FAWJB /dev/disk/disk3 /dev/disk/disk3_p2 /dev/rdisk/disk3 /dev/rdisk/disk3_p2 /dev/disk/disk3_p1 /dev/disk/disk3_p3 /dev/rdisk/disk3_p1 /dev/rdisk/disk3_p3 # ls -l total 0 crw-r----- 1 bin sys 13 0x000000 Sep 12 17:04 disk2 crw-r----- 1 bin sys 13 0x000005 Sep 12 17:29 disk2_p1 crw-r----- 1 bin sys 13 0x000006 Sep 12 17:29 disk2_p2 crw-r----- 1 bin sys 13 0x000007 Sep 12 17:29 disk2_p3 crw-r----- 1 bin sys 13 0x000001 Aug 15 15:51 disk3 crw-r----- 1 bin sys 13 0x000002 Aug 15 15:51 disk3_p1 crw-r----- 1 bin sys 13 0x000003 Aug 15 15:51 disk3_p2 crw-r----- 1 bin sys 13 0x000004 Aug 15 15:51 disk3_p3 #
Once we have the device files we can add them to LVM
# pvcreate -B /dev/rdisk/disk2_p2 Physical volume "/dev/rdisk/disk2_p2" has been successfully created. #
The -B option is to identifiy the HPUX partition
# vgextend vg00 /dev/disk/disk2_p2 Volume group "vg00" has been successfully extended. Volume Group configuration for /dev/vg00 has been saved in /etc/lvmconf/vg00.conf #
and we write the boot sector in the disk /dev/disk/disk2
# mkboot -e -l /dev/rdisk/disk2 # mkboot -a "hpux" /dev/rdisk/disk2
now we just need to create the mirror in each lvol
# lvextend –m 1 /dev/vg00/lvol1 /dev/disk/disk2_p2
0 comments:
Post a Comment