mapping device from an inq output to veritas disk groups


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting mapping device from an inq output to veritas disk groups
# 1  
Old 01-06-2009
mapping device from an inq output to veritas disk groups

Hi, Does anyone have a clever way of mapping the following from two different files using perl.

sample line from vxdisk list output (vxdisk-list.file):

emcpower18s2 auto:sliced IDFAG1_1 (IDFAG1_appdg) online


sample line from 'inq' output (inq.file):


dev/rdsk/emcpower18c :EMC :SYMMETRIX :5670 :280076a000 : 8923200 :000287750328


I would like the resulting output to appear in
the following format

Diskgroup Device ID
======= =======
IDFAG_appdg, 280076a000

Many Thanks,
Collin
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Beginners Questions & Answers

How to extend a disk in veritas volume manager in veritas cluster?

Hi Experts, I wanted to extend a veritas file system which is running on veritas cluster and mounted on node2 system. #hastatus -sum -- System State Frozen A node1 running 0 A node2 running 0 -- Group State -- Group System Probed ... (1 Reply)
Discussion started by: Skmanojkum
1 Replies

2. Linux

Logical Volume to physical disk mapping

When installing Linux, I choose some default setting to use all the disk space. My server has a single internal 250Gb SCSI disk. By default the install appears to have created 3 logical volumes lv_root, lv_home and lv_swap. fdisk -l shows the following lab3.nms:/dev>fdisk -l Disk... (2 Replies)
Discussion started by: jimthompson
2 Replies

3. Solaris

T5220 disk mapping issue

Hi, More a Sun T5220 problem then a Solaris 10 problem, but perhaps someone had a similar issue. For starters the output with 1 disk in slot 0 of the server. It points to PhyNum 5, where I would expect PhyNum 0. {0} ok probe-scsi MPT Version 1.05, Firmware Version 1.22.00.00 Target... (2 Replies)
Discussion started by: ejdv
2 Replies

4. Solaris

Veritas not attaching replaced disk

Hi, I`m on SunFire480R with Solaris 10. Disk in rootdg group failed, so it was replaced. However, I cannot make Veritas initalise the replaced disk: # vxdctl enable # vxdisk list c1t0d0s2 Device: c1t0d0s2 devicetag: c1t0d0 type: auto flags: online error private autoconfig... (1 Reply)
Discussion started by: masloff
1 Replies

5. UNIX for Dummies Questions & Answers

Configure disk group with veritas

People i have an a storage i create two virtual disk 1 y 2. In the virtual disk 1 i configure 8 volumes and in the Vd2 configure 5 volumes. Now i want to create a disk group called Prod2 y Dev2 but when i go to vxdiskadm and i choose add disk o encapusalte when i press list to list the disk... (0 Replies)
Discussion started by: enkei17
0 Replies

6. AIX

Problem mapping LUN disk from VIOS to the LPAR

Hello guys, It would be so nice of you if someone can provide me with these informations. 1) My SAN group assigned 51G of LUN space to the VIO server.I ran cfgdev to discover the newly added LUN. Unfortunately most of the disks that are in VIO server is 51G. How would I know which is the newly... (3 Replies)
Discussion started by: solaix14
3 Replies

7. AIX

LPAR and vio disk mapping

We have a frame the uses 2 vios that assign disk storage to LPAR's. We have a LPAr with multiple disk and I want to know how do I tell which vio is serving the disk. For example the LPAr has hdisk 0, 1, 2, 3 all the same size. I want to know which vio is serving hdisk0, 1. (4 Replies)
Discussion started by: daveisme
4 Replies

8. Solaris

OpenSolaris 2008.11 Hard Drive Device mapping

Dear Solaris Experts, I am a bit confused about OpenSolaris Hard Drive device mapping. On RedHat Linux based system, an IDE on first channel master drive is mapped as /dev/hda, first channel slave drive will be /dev/hdb, etc. For (Open)Solaris systems I found it as /dev/rdsk/c3d0p0 : ... (0 Replies)
Discussion started by: Zepiroth
0 Replies

9. Solaris

Need to remove a disk from Veritas

I have a bogus disk that keeps showing up as failed from vxdisk list - - disk hpdg failed was:c2t0d11s2 There isnt any c2 devices on the system: # ls /dev/dsk/c2* /dev/dsk/c2*: No such file or directory # ls /dev/rdsk/c2* /dev/rdsk/c2*: No such file or... (3 Replies)
Discussion started by: kiem
3 Replies

10. Filesystems, Disks and Memory

FSCK on veritas managed disk

I've had a VXFS filesystem get corrupted and now it won't mount. Can I run a fsck -y on the raw disk device or should something be done within veritas? Veritas does not see the disk at the moment. (2 Replies)
Discussion started by: ozzmosiz
2 Replies
Login or Register to Ask a Question
vxdisksetup(1M) 														   vxdisksetup(1M)

NAME
vxdisksetup, vxdiskunsetup - configure a disk for use with Veritas Volume Manager SYNOPSIS
vxdisksetup [-ifB] disk_address [attribute ...] vxdisksetup [-ifB] disk_address format=hpdisk [attribute ...] vxdisksetup [-if] disk_address format=cdsdisk [attribute ...] /etc/vx/bin/vxdiskunsetup [-C] [-F] disk_address... DESCRIPTION
The vxdisksetup command configures the disk for use by Veritas Volume Manager (VxVM). vxdisksetup is called by the vxdiskadd command as part of initial disk configuration. It is not typically necessary to call this command directly. Note: In release 4.0 of VxVM, the behavior of the vxdisksetup command has been changed so that it only creates auto-configured disks (with a disk access type of auto; see vxdisk(1M)), which can have one of the following formats: cdsdisk The disk is formatted as a CDS disk that is suitable for moving between different operating systems. This is the default format for non-EFI disks (provided that the -i option is used to write the disk header). It is not suitable for boot disks or EFI disks. Note: As the CDS format is applied to the entire disk and is unsuitable for boot disks, options and attributes that relate to partitions, slices or booting are not applicable. The CDS format is also incompatible with EFI disks. hpdisk The disk is formatted to include a private region that VxVM uses to store configuration information. Following the private region, the remainder of the disk forms the public region from which subdisks can be allocated. This format can be applied to disks that can be used to boot the system. If the disk is not initialized as a boot disk, space is reserved on the disk to allow it to be converted to cdsdisk format if required. The hpdisk format is the default for EFI disks. none The disk is unformatted. Note: This value may be displayed, but it cannot be set as a valid format. The vxdiskunsetup command reverses the configuration done by vxdisksetup and makes the specified disks unusable by VxVM. vxdiskunsetup can be applied only to VxVM-initialized disks that are not in use within an imported disk group. The disk_address argument passed to vxdisksetup or to vxdiskunsetup directs the command to the device that corresponds to the disk being operated upon. The address should be provided in the form c#t#d#, which define a controller number (c#), a SCSI target ID (t#), and a SCSI logical unit number (d#). Each number is specified in decimal and can be multiple digits. If the disks are named using the enclosure based naming scheme, the address usually takes the form enclosurename_diskno. The name must reference a valid disk under the /dev/vx/rdmp directory. The vxdiskunsetup command operates by removing the public and private regions that were created by the last invocation of vxdisksetup on the specified disks. After this operation, those disks are converted from the online to the error state state (as displayed by vxdisk list). The /etc/default/vxdisk file can be used to set the default values of the format and privlen attributes for the vxdisk and vxdisksetup com- mands. Values in this file override inbuilt values, and may themselves be overridden by values specified on the command line. For details, see the vxdisk(1M) manual page. Note: When vxdisksetup is executed on an HP IPF (IA64) system, the target disk is either configured or deconfigured as an EFI partitioned disk. The action that is taken depends on whether the -B option is specified, and whether the disk is already formatted as an EFI parti- tioned disk: o If the -B option is specified, and the disk is not already formatted as an EFI disk, the idisk(1M) utility is called to format the disk as an EFI partitioned disk. The partitioning creates an EFI header in the first 1K block, a 100MB partition (or slice) 1, and partition 2 (the HP-UX partition) on the remainder of the disk. If the vxbootsetup(1M) command is subsequently used to configure the disk as a boot disk, partition 1 is populated with an EFI file system, which contains the boot programs that are needed by an HP IPF system, and the HP-UX partition (partition 2) is set up as a logical simple VxVM disk with the same layout as a non-EFI disk. When vxdisksetup has completed setting up an EFI disk, the resulting disk must be addressed using the s2 suffix to select the logical sim- ple VxVM disk. o If the -B option is not specified and the target disk is currently formatted as an EFI partitioned disk, any EFI formatting is destroyed, and the disk is initialized as a non-EFI partitioned disk. OPTIONS
-B Initializes the Veritas Volume Manager private region to begin at block number 2144. This block is designated as the private region offset for a Veritas Volume Manager root disk. Without this option, the private region is initialized to start at the default block number 128. Note: This option is not supported for cdsdisk format disks. -C vxdiskunsetup usually does not operate on disks that appear to be imported by some other host (for example, a host that shares access to the disk). In this case, the -C option can be specified to force de-configuration of the disk, effectively removing the host locks that were detected by vxdiskunsetup. -f Forces a disk to be initialized even if it is a member of a deported disk group. -F By default, the vxdiskunsetup command only operates on online disks. It does not operate on disks that are imported or offline. This option forces an unsetup operation to be performed on such disks. -i Writes a disk header to the disk, initializes the private region of the disk and makes the disk directly usable (as a new disk in a disk group, for example). Note: A disk that is a member of an imported disk group cannot be initialized. The command also fails if the disk is a member of a deported disk group. The -f option can be used to override the latter restriction. ATTRIBUTES
You can specify attributes to affect the layout strategy used by vxdisksetup. CAUTION: Take great care when using these attributes as they can render a disk unusable by VxVM. config Sets up kernel logs or configuration databases on the disk. This attribute has the opposite effect to the noconfig attribute. This is the default behavior if the -i option is specified. Otherwise, the attribute is ignored. noconfig Prevents setting up kernel logs or configuration databases on the disk. The size of the default private region is set to 160 blocks, which is the minimum allowed private region size. noconfig is ignored unless the -i option is specified. noreserve Do not reserve space for conversion to other formats such as cdsdisk. privlen=length Specifies the length of the private region of the disk. The default size of this area is 32MB. The maximum possible size of the private region is 524288 blocks. For cdsdisk format disks, privlen is silently rounded up to the nearest multiple of 8KB if it is not already a multiple of 8KB. privoffset=offset Indicates the sector offset of the private region on the disk. The default value for the private region offset is block number 128 for non-boot disks and block number 2144 for boot disks. For cdsdisk format disks, privoffset is silently rounded up to the nearest multiple of 8KB that is larger than or equal to 128KB if it is not already a multiple of 8KB or if its value is less than 128KB. publen=length Specifies the length of the public region of the disk. This defaults to the size of the disk minus the private area on the disk. For cdsdisk format disks, publen is silently rounded up to the nearest multiple of 8KB if it is not already a multiple of 8KB. puboffset=offset Sets the offset on the disk where the public region starts. By default, this is past the end of the private region. For the hpdisk format, 128 blocks of disk space are reserved at the end of the private region unless this is overridden by the value of puboffset or the -B option is specified. The reserved space allows for later conversion to the cdsdisk format. For cdsdisk format disks, puboffset is silently rounded up to the nearest multiple of 8KB if it is not already a multiple of 8KB. EXAMPLES
To initialize a disk for regular use, enter: /etc/vx/bin/vxdisksetup -i c2t1d0 To initialize a disk for normal use, but set the private region size to 1MB instead of the default size of 32MB, enter: /etc/vx/bin/vxdisksetup -i c2t1d0 privlen=1m Force deconfiguration of a VxVM-initialized disk, c0f4d0: /etc/vx/bin/vxdiskunsetup -C c0t4d0 NOTES
The default private region size increased from 512KB to 1MB in release 3.2, and from 1MB to 32MB in release 5.0. FILES
/etc/default/vxdisk Defaults file used by the vxdisk and vxdisksetup utilities. SEE ALSO
vxcdsconvert(1M), vxdisk(1M), vxdiskadd(1M), vxintro(1M) VxVM 5.0.31.1 24 Mar 2008 vxdisksetup(1M)