Veritas Volume Manager -2
What we will learn
in Next Few Pages,
·
How
vxvm find disks [like devfsadm in Solaris]
·
How
to see the disks in vxvm
·
Veritas
Naming Convention / modification
·
Realizing
disks to Veritas
·
Removing
disks from Veritas
·
Veritas
User Interactive Disk Configuration (vxdiskadm)
·
Create
Dg / add-remove disk to Dg
Better to have BABY
STEPS, Instead of start Jumping-Japang at once
root@pr-01:>/# format
Searching for
disks...done
AVAILABLE DISK
SELECTIONS:
0. c1t0d0 <DEFAULT cyl 1563 alt 2 hd
255 sec 63>
/pci@0,0/pci15ad,1976@10/sd@0,0
1. c2t2d0 <DEFAULT cyl 1917 alt 2 hd
128 sec 32>
/iscsi/disk@0000iqn.2006-01.com.openfiler%3Atsn.aeed9c1a441f0001,0
Specify disk (enter
its number):
I need some more
disks…
root@pr-01:>/# format
Searching for
disks...done
AVAILABLE DISK
SELECTIONS:
0. c1t0d0 <DEFAULT cyl 1563 alt 2 hd
255 sec 63>
/pci@0,0/pci15ad,1976@10/sd@0,0
1. c2t2d0 <DEFAULT cyl 1917 alt 2 hd
128 sec 32>
/iscsi/disk@0000iqn.2006-01.com.openfiler%3Atsn.aeed9c1a441f0001,0
2. c2t3d0 <DEFAULT cyl 957 alt 2 hd
64 sec 32>
/iscsi/disk@0000iqn.2006-01.com.openfiler%3Atsn.aeed9c1a441f0001,1
3. c2t4d0 <DEFAULT cyl 957 alt 2 hd
64 sec 32>
/iscsi/disk@0000iqn.2006-01.com.openfiler%3Atsn.aeed9c1a441f0001,2
4. c2t5d0 <DEFAULT cyl 957 alt 2 hd
64 sec 32>
/iscsi/disk@0000iqn.2006-01.com.openfiler%3Atsn.aeed9c1a441f0001,3
Good… Now I have
enough no of disks… For testing…
root@pr-01:>/# vxdisk list
DEVICE TYPE DISK GROUP STATUS
disk_0 auto:none - - online invalid
disk_1 auto:none - - online invalid
Ohhh… only 2 disks
…. Means VxVM is sleeping … let’s wake him up…
root@pr-01:>/# vxdisk scandisks
root@pr-01:>/# vxdisk list
DEVICE TYPE DISK GROUP STATUS
disk_0 auto:none - - online invalid
disk_1 auto:none - - online invalid
disk_2 auto:none - - online invalid
disk_3 auto:none - - online invalid
disk_4 auto:none - - online invalid
Great na… vxvm has
5 disks, But
disk_0 disk_1
disk_2 and so on… but what
is this,
what is the actual
name of disk ?
Let’s Find out,
root@pr-01:>/# vxdisk -e list
DEVICE TYPE DISK GROUP STATUS OS_NATIVE_NAME ATTR
disk_0 auto:none - - online
invalid c1t0d0s2 -
disk_1 auto:none - - online
invalid c2t5d0s2 -
disk_2 auto:none - - online
invalid c2t4d0s2 -
disk_3 auto:none - - online
invalid c2t2d0s2 -
disk_4 auto:none - - online
invalid c2t3d0s2 -
Actually Veritas
has Naming Convention,
·
OS
Native
·
Enclosure
Based
Default is Enclosure
Based,
I want to change it
to OS Native
root@pr-01:>/# vxddladm set
namingscheme=osn
root@pr-01:>/# vxdisk list
DEVICE TYPE DISK GROUP STATUS
c1t0d0s2 auto:none - - online invalid
c2t2d0s2 auto:none - - online invalid
c2t3d0s2 auto:none - - online invalid
c2t4d0s2 auto:none - - online invalid
c2t5d0s2 auto:none - - online invalid
Now … looking good
What ???
Veritas is telling
that … u moron
What I will do with
these ?
Give me control of
the disks…
Ok… take it,
**** have u noticed
the names of disks, realized by veritas ?? ***
Let’s give the
control of disks to Veritas
root@pr-01:>/# vxdisksetup -i
c2t2d0 format=sliced
root@pr-01:>/# vxdisksetup -i
c2t3d0 format=sliced
root@pr-01:>/# vxdisksetup -i
c2t4d0 format=sliced
root@pr-01:>/# vxdisksetup -i
c2t5d0 format=sliced
So what’s this
format & sliced
Format is the
manner in which we give the disks to Veritas and the types of format are,
SIMPLE Public /Private Regions are on same disk area, Public area
is following the Private area.
Simple
format disks can be converted to CDS
SLICED Pub/Private regions are on different disk partitions,
sliced format disk can be used for
boot, if not
Used
for booting then only can converted to CDS
NOPRIV no private only public region for
allocating subdisks
CDS cross platform data sharing, suitable for moving disk
between different OS’s.
Assigned disks to
vxvm… let’s take back the disk…
root@pr-01:>/# vxdiskunsetup
c2t5d0
Want to see the
status,
root@pr-01:>/# vxdisk list
DEVICE TYPE DISK GROUP STATUS
c1t0d0s2 auto:none - - online invalid
c2t2d0s2 auto:sliced - - online
c2t3d0s2 auto:sliced - - online
c2t4d0s2 auto:sliced - - online
c2t5d0s2 auto:none - - online invalid
Let’s have another
easier way
root@pr-01:>/# vxdiskadm
Volume Manager
Support Operations
Menu:
VolumeManager/Disk
1
Add or initialize one or more disks
2
Encapsulate one or more disks
3
Remove a disk
4
Remove a disk for replacement
5
Replace a failed or removed disk
6
Mirror volumes on a disk
7
Move volumes from a disk
8
Enable access to (import) a disk group
9 Remove access to (deport) a disk group
10
Enable (online) a disk device
11
Disable (offline) a disk device
12
Mark a disk as a spare for a disk group
13
Turn off the spare flag on a disk
14
Unrelocate subdisks back to a disk
15
Exclude a disk from hot-relocation use
16
Make a disk available for hot-relocation use
17
Prevent multipathing/Suppress devices from VxVM's view
18
Allow multipathing/Unsuppress devices from VxVM's view
19
List currently suppressed/non-multipathed devices
20
Change the disk naming scheme
21
Get the newly connected/zoned disks in VxVM view
22
Change/Display the default disk layouts
23
Dynamic Reconfiguration Operations
list
List disk information
?
Display help about menu
??
Display help about the menuing system
q
Exit from menus
Select an operation
to perform: 1
Add or initialize
disks
Menu:
VolumeManager/Disk/AddDisks
Use this operation to add one or more disks
to a disk group. You can
add the selected disks to an existing disk
group or to a new disk group
that will be created as a part of the
operation. The selected disks may
also be added to a disk group as spares. Or
they may be added as
nohotuses to be excluded from hot-relocation
use. The selected
disks may also be initialized without adding
them to a disk group
leaving the disks available for use as
replacement disks.
More than one disk or pattern may be entered
at the prompt. Here are
some disk selection examples:
all:
all disks
c3 c4t2:
all disks on both controller 3 and controller 4, target 2
c3t4d2:
a single disk (in the c#t#d# naming scheme)
xyz_0 :
a single disk (in the enclosure based naming scheme)
xyz_ :
all disks on the enclosure whose name is xyz
Select disk devices
to add: [<pattern-list>,all,list,q,?] list
DEVICE DISK GROUP STATUS
c1t0d0 -
- online invalid
c2t2d0 - - online
c2t3d0 - - online
c2t4d0 - - online
c2t5d0 - - online invalid
Select disk devices
to add: [<pattern-list>,all,list,q,?] c2t5d0
Here is the disk selected. Output format: [Device_Name]
c2t5d0
Continue operation?
[y,n,q,?] (default: y) y
You can choose to add this disk to an
existing disk group, a
new disk group, or leave the disk available
for use by future
add or replacement operations. To create a new disk group,
select a disk group name that does not yet
exist. To leave
the disk available for future use, specify a
disk group name
of "none".
Which disk group
[<group>,none,list,q,?] (default:
none) none
Add site tag to
disk? [y,n,q,?] (default: n) n
The disk will be initialized and left free
for use as a replacement
disk.
c2t5d0
Continue with
operation? [y,n,q,?] (default: y) y
Initializing device c2t5d0.
Enter the desired
format
[cdsdisk,sliced,simple,q,?] (default: cdsdisk) sliced
Enter desired
private region length
[<privlen>,q,?] (default: 65536) 65536
Add or initialize
other disks? [y,n,q,?] (default: n) n
Select an
operation to perform: q
Goodbye.
Seen… how
mannered Veritas is? Goodbye… ever told by any Volume Manger? Go to svm and see it has only one thing to say
c’mon I want to &$#@
OK…
Now what Next?
Create dg
DISK GROUP
A disk group is
a collection of disks that share a common configuration that is managed by
VxVM.
A disk group
configuration is a set of records with detailed information
about related
VxVM objects, their attributes, and their connection.
Cmd is vxdg
For addition /
removal / import / deport of dg
Format of
command is
#vxdg <init / adddisk / rmdisk / import / deport /destroy>
<dg name> [cds=on|off] <disk name=device name>
I think all will
be good except the last one,
Suppose we are
going to make dg with c1t5d0s2, we have to give a name for this device which
will be disk name
** 3 names that
we can’t use as dg name
·
Boot dg
·
Default dg
·
Nodg
root@pr-01:>/# vxdisk list
DEVICE TYPE DISK GROUP STATUS
c1t0d0s2 auto:none - - online invalid
c2t2d0s2 auto:sliced - - online
c2t3d0s2 auto:sliced - - online
c2t4d0s2 auto:sliced - - online
c2t5d0s2 auto:sliced - - online
root@pr-01:>/# vxdg init test-dg1
test-disk2=c2t2d0s2
VxVM vxdg ERROR
V-5-1-6478 Device c2t2d0s2 cannot be added to a CDS disk group
root@pr-01:>/# vxdg init test-dg1
cds=off test-disk2=c2t2d0s2
root@pr-01:>/# vxdisk list
DEVICE TYPE DISK GROUP STATUS
c1t0d0s2 auto:none - - online invalid
c2t2d0s2 auto:sliced test-disk2 test-dg1
online
c2t3d0s2 auto:sliced - - online
c2t4d0s2 auto:sliced - - online
c2t5d0s2 auto:sliced - - online
**sliced
formatted disks cannot be used to create DG on it, unless the CDS would be off**
Now add 1 disk
to this DG,
root@pr-01:>/# vxdg -g test-dg1
adddisk test-disk3=c2t3d0s2
Now remove disk
from this DG,
root@pr-01:>/# vxdg -g test-dg1
rmdisk test-disk3
Now I want this
disk to Get Out from vxvm
root@pr-01:>/# vxdiskunsetup -f
c2t3d0
root@pr-01:>/# vxdisk list
DEVICE TYPE DISK GROUP STATUS
c1t0d0s2 auto:none - - online invalid
c2t2d0s2 auto:sliced test-disk2 test-dg1
online
c2t3d0s2
auto:none - - online invalid
c2t4d0s2 auto:sliced - - online
c2t5d0s2 auto:sliced - - online
Let’s get back
that disk,
root@pr-01:>/# vxdisksetup -i
c2t3d0 format=sliced
root@pr-01:>/# vxdisk list
DEVICE TYPE DISK GROUP STATUS
c1t0d0s2 auto:none - - online invalid
c2t2d0s2 auto:sliced test-disk2 test-dg1
online
c2t3d0s2
auto:sliced - - online
c2t4d0s2 auto:sliced - - online
c2t5d0s2 auto:sliced - - online
No comments:
Post a Comment