reg DS_LVZ


 
Thread Tools Search this Thread
Operating Systems AIX reg DS_LVZ
# 1  
Old 01-06-2011
reg DS_LVZ

HI

in a vg i want to display the lv name & whether the LV is enabled with DS_LVZ parameter?

I used
Code:
#lsvg -o | grep vgname | lsvg -il

this gives the output of lv's in the vg.
buti treid with
Code:
lsvg -o | grep vgname| lsvg -il | egrep "LOGICAL VOLUME|DS_LVZ"

but No output.SmilieSmilie
i want to display the LV NAME & whether the LV enabled with DS_LVZ parameter?

Last edited by pludi; 01-07-2011 at 05:47 AM..
# 2  
Old 01-06-2011
Hey,

If you do a lslv -L <lv_name> you can get the parameter you are looking for.
A simple FOR loop + IF statement will help you get you what you need.

Cheers.
# 3  
Old 01-07-2011
reg DS_LVZ

I need some script to grep the output fr lslv outputSmilie
# 4  
Old 01-07-2011
Can you post the output of the lsvg command and the desired output?
# 5  
Old 01-08-2011
reg DS_LVZ

Code:
VOLUME GROUP:       pmrxvz3                  VG IDENTIFIER:  00f60ebf00004c0000000129b2ff8e0f
VG STATE:           active                   PP SIZE:        32 megabyte(s)
VG PERMISSION:      read/write               TOTAL PPs:      58856 (1883392 megabytes)
MAX LVs:            256                      FREE PPs:       8758 (280256 megabytes)
LVs:                72                       USED PPs:       50098 (1603136 megabytes)
OPEN LVs:           72                       QUORUM:         5 (Enabled)
TOTAL PVs:          8                        VG DESCRIPTORS: 8
STALE PVs:          0                        STALE PPs:      0
ACTIVE PVs:         8                        AUTO ON:        no
MAX PPs per VG:     65536                    MAX PVs:        1024
LTG size (Dynamic): 1024 kilobyte(s)         AUTO SYNC:      no
HOT SPARE:          no                       BB POLICY:      relocatable

LOGICAL VOLUME:     rpmrxvz3_33          VOLUME GROUP:pmrxvz3   
LV IDENTIFIER:      00cb8c4400003c0000000129b50d816a.9 PERMISSION:     read/write
VG STATE:           active/complete        LV STATE:       opened/syncd
TYPE:               raw                    WRITE VERIFY:   off
MAX LPs:            512                    PP SIZE:        32 megabyte(s)
COPIES:             1                      SCHED POLICY:   parallel
LPs:                512                    PPs:            512
STALE PPs:          0                      BB POLICY:      relocatable
INTER-POLICY:       maximum                RELOCATABLE:    yes
INTRA-POLICY:       middle                 UPPER BOUND:    1024
MOUNT POINT:        N/A                    LABEL:          None
MIRROR WRITE CONSISTENCY: on/ACTIVE                              
EACH LP COPY ON A SEPARATE PV ?: yes                                    
Serialize IO ?:     NO                                     
DEVICESUBTYPE : DS_LVZ

Code:
#lsvg -o | grep pmrxvz3|lsvg -il|

pmrxvz3:
LV NAME             TYPE       LPs     PPs     PVs  LV STATE      MOUNT POINT
rpmrxvz3_33        raw        512     512     8    open/syncd    N/A
rpmrxvz3_2         raw        512     512     8    open/syncd    N/A
rpmrxvz3_1         raw        512     512     8    open/syncd    N/A
rpmrxvz3_3         raw        512     512     8    open/syncd    N/A
rpmrxvz3_6         raw        512     512     8    open/syncd    N/A
rpmrxvz3_38        raw        512     512     8    open/syncd    N/A

pmrxvz4

LV NAME             TYPE       LPs     PPs     PVs  LV STATE      MOUNT POINT
rpmrxvz7_1         raw        512     512     8    open/syncd    N/A
rpmrxvz7_4         raw        512     512     8    open/syncd    N/A
rpmrxvz7_6         raw        512     512     8    open/syncd    N/A
rpmrxvz7_8         raw        512     512     8    open/syncd    N/A
rpmrxvz7_10        raw        512     512     8    open/syncd    N/A
rpmrxvz7_14        raw        512     512     8    open/syncd    N/A
rpmrxvz7_15        raw        512     512     8    open/syncd    N/A

i am able to get the LV NAME ,TYPE, LPs, PPs, PVs, LV STATE & MOUNT POINT output.In these LVs i need to grep LV name & whether the LV got DS_LVZ.thanks in advance.Smilie

Last edited by Scott; 01-08-2011 at 08:16 AM.. Reason: Code tags, please...
# 6  
Old 01-16-2011
Computer reg DS_LVZ

yes i got the answer.
Code:
lsvg -o |grep vgname |lsvg -il|grep sync|awk'{print "lslv "$1"|egrep \"LOGICAL VOLUME|DS_LVZ\" >>/tmp/frsLvz.txt"}'|sh

also you can try with the following script.i could not try this.please try this & give me the feedback.
Code:
for i in `lsvg -o`
do
for j in `lsvg -l $i | sed -n '3,$p' | awk ' { print $1 }'`
do
  echo "-------------"
  echo "LVNAME:$j    "
  echo "-------------"
  lslv $j | grep -i "DS_LVZ"
  done
done

Thanks to all.SmilieSmilie

Moderator's Comments:
Mod Comment Use code tags, please...

Last edited by Scott; 01-16-2011 at 08:08 AM..
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Reg expressions

Hi, I would like to grep for a string within a tag, can someone provide some assistance in how to do it? So I would like to use the grep command to find a string like: <tag>sometext<tag> because the sometext can be any number of characters or an type of number or lettering, what expression... (1 Reply)
Discussion started by: cyberfrog
1 Replies

2. Shell Programming and Scripting

Sorting - Reg.

Hi masters, I have one doubt, lets's say file1 has the following contents, 1 2.0 3.1 5.5 7 5.10 5.9 How to sort these contents to get the o/p like 1 2.0 3.1 5.5 5.9 5.10 7 (8 Replies)
Discussion started by: ecearund
8 Replies

3. Solaris

Reg. VXVM

Hi Guys, I have a doubt either to Reboot the server after Replacing the disk0. I have two disks under vxvm root mirrored and i had a problem with primary disk so i replace the disk0 failed primary disk and then mirrored. After mirroring is it reboot required ? (7 Replies)
Discussion started by: kurva
7 Replies

4. Solaris

Reg: ZONES

HI Friends, What is the min. Requirement to install Solaris ZONEs, i am using INTEL PC at home and i allready installed Solaris 10 can i configure ZONES in it, and i want to know the basic information of ZONES. Thanks in Advance. (3 Replies)
Discussion started by: kurva
3 Replies

5. Shell Programming and Scripting

Reg expression For

HI system.sysUpTime.0 : Timeticks: (1519411311) 175 days, 20:35:13.11 From the above output i need only 175days in a perl script.. Please Help (2 Replies)
Discussion started by: Harikrishna
2 Replies

6. Shell Programming and Scripting

need a help reg -d in shell

hi, I am using this to get previous month `date -d"1 month ago" "+%m"` But will it work for january?..will it return 12? Please advice. (2 Replies)
Discussion started by: vanathi
2 Replies

7. Shell Programming and Scripting

Reg: Gzip

Hi , I want gzip a folder te55 which has got 3 files test1.test2,test3 the name of the gzipped folder should be te55.gz with the 3 files as test1,test2,test3 itself... Is it possible... thanks in advance sam (5 Replies)
Discussion started by: sam99
5 Replies

8. UNIX for Dummies Questions & Answers

Help with Reg. Expression

I need help with this: Can any one tell me what does these below mean: 1. "\(.\).*") != '/' 2. sed 's+^\./++;s+/.*++' 3. sed "s+${f}/+ + Thanks in advance (7 Replies)
Discussion started by: moe2266
7 Replies

9. UNIX for Advanced & Expert Users

Reg DB values

Hi, I would like to call my Data Base procedure through unix, my procedure returns 4 values i.e. (4 out variables), how to assign 4 out variables to unix variables. Ex: xxat_safety_stock_main_p( retcode => l_retcode ,errbuf => l_errbuf... (2 Replies)
Discussion started by: mpkirankumar
2 Replies

10. Shell Programming and Scripting

reg files

Dear all, One of our jobs retrieves data from tables and writes it to files. This job was running for around 15 minutes for the past 8 months. Now, this job is runnig for 45-50 minutes. I checked with the DBA's and found no issues with database. The time taken by to job to write to the file is... (5 Replies)
Discussion started by: ranj@chn
5 Replies
Login or Register to Ask a Question