1752422 Members
5485 Online
108788 Solutions
New Discussion юеВ

Re: HP-UX mirror disks

 
SOLVED
Go to solution
cheesytime
Regular Advisor

HP-UX mirror disks

Hello,

From SAM I see two unused disks, see below:

0.4.0 1 Unused 286102 COMPAQ BF3008AFEC

0.5.0 1 Unused 286102 COMPAQ BF3008AFEC


disk 7 0/4/1/0.4.0 sdisk CLAIMED DEVICE COMPAQ BF3008AFEC
/dev/dsk/c4t4d0 /dev/rdsk/c4t4d0

disk 8 0/4/1/0.5.0 sdisk CLAIMED DEVICE COMPAQ BF3008AFEC
/dev/dsk/c4t5d0 /dev/rdsk/c4t5d0

I would like to know how to make a RAID1 with thouse two disks and then create a filesystem with that RAID1 called /test (with the largefiles option on it)

Thanks a lot
25 REPLIES 25
Pete Randall
Outstanding Contributor
Solution

Re: HP-UX mirror disks

Unless these two disks are part of some RAID unit that is capable of mirroring, you will need the MirrorDisk product, which is a purchaseable extension of LVM. You can check to see if you have it by running swlist:

# swlist |grep -i mirror
B2491BA B.11.11 MirrorDisk/UX

Assuming you have the MirrorDisk product, it works by mirroring logical volumes, not whole disks. Check the lvextend man page and you will see the information concerning the "-m mirror copies" option.


Pete

Pete
Steven E. Protter
Exalted Contributor

Re: HP-UX mirror disks

Shalom,

Your server or disk unit may have hardware raid, negating the need to purchase Mirror/UX

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Mel Burslan
Honored Contributor

Re: HP-UX mirror disks

provided you have mirrorUX software:

pvcreate /dev/rdsk/c4t4d0
pvcreate /dev/rdsk/c4t5d0

# eplace vg00 if you want to put them under a different vg below
vgextend vg00 /dev/dsk/c4t4d0
vgextend vg00 /dev/dsk/c4t5d0

lvcreate -s -n myNEWlvolNAME vg00
lvextend -L /dev/vg00/myNEWlvolNAME /dev/dsk/c4t4d0
lvextend -m 1 /dev/vg00/myNEWlvolNAME /dev/dsk/c4t5d0

newfs -F vxfs /dev/vg00/myNEWlvolNAME

One thing to consider: since this seems like a large disk drive (~290 GB) you may need to create a new volume group with larger PE-per-PV number or with larger PE sizes to accommodate these drives.
________________________________
UNIX because I majored in cryptology...
Mel Burslan
Honored Contributor

Re: HP-UX mirror disks

Too bad forums do not have an edit feature:

please correct the last command in my response as:

newfs -F vxfs -o largefiles /dev/vg00/myNEWlvolNAME
________________________________
UNIX because I majored in cryptology...
unix adm
Regular Advisor

Re: HP-UX mirror disks

If you have mirror disk software available


re-verify if these disks are not the part of any volume group already

strings /etc/lvmtab |grep -i c4t4d0
strings /etc/lvmtab |grep -i c4t5d0


Steps to create new vg and mirror using raid 1


pvcreate -f /dev/rdsk/c4t4d0
pvcreate -f /dev/rdsk/c4t5d0
mkdir /dev/vgtest
mknod group c64 0X020000

(minor number 0X020000 (make sure it is unused if used just use successive number 0X030000)

vgcreate vgtest /dev/dsk/c4t4d0
lvcreate -L M /dev/vgtest -n lvoltest
newfs -f vxfs -o largefiles /dev/vgtest/rlvoltest
mkdir /test
mount /dev/vgtest/lvoltest /test


vgextend /dev/vgtest /dev/dsk/c4t5d0

lvextend -m 1 /dev/vgtest/lvoltest /dev/dsk/c4t5d0

Once completes u can check using , look for mirror copy details.

lvdisplay /dev/vgtest/lvoltest



Thanks and Regards
Rajeev
cheesytime
Regular Advisor

Re: HP-UX mirror disks

Rajeev:

Amazing response!

>mknod group c64 0X030000

>(minor number 0X020000 (make sure it is >unused if used just use successive number >0X030000)

How do I find out wether its being used or not?
cheesytime
Regular Advisor

Re: HP-UX mirror disks

I tried:

root@host:/dev # ll /dev/*/group
cr--r--r-- 1 root sys 64 0x010000 May 9 2005 /dev/test/group
cr--r--r-- 1 root sys 64 0x020000 Sep 14 2005 /dev/test/group
crw-r----- 1 root sys 64 0x000000 Feb 26 2005 /dev/vg00/group

root@host:/dev # mknod group c64 0X030000
mknod: arg count
usage: mknod name b|c major minor
mknod name p

why mknod aint working?
Patrick Wallek
Honored Contributor

Re: HP-UX mirror disks

Assuming all of your VG names start with 'vg' do:

# ll /dev/vg*/group

or, to just search all of /dev:

# ll /dev/*/group
Mel Burslan
Honored Contributor

Re: HP-UX mirror disks

There needs to be a space between c and 64. That must be what the complaint is about
________________________________
UNIX because I majored in cryptology...