- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- vgdisplay
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-07-2003 01:49 AM
11-07-2003 01:49 AM
I need to output to a file the result of vgdisplay -v command, but in this file I do not need the output of vg00. The problem is that I've other vg names than vg01, vg02... I don't know all the name of all the vg's that are configured on the machine.. How can I find them??
Thanks
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-07-2003 01:54 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-07-2003 01:55 AM
11-07-2003 01:55 AM
Re: vgdisplay
You can use the vgdisplay command ( no options)
# vgdisplay
or
# ll /dev/*/group
Regards,
Robert-Jan.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-07-2003 01:56 AM
11-07-2003 01:56 AM
Re: vgdisplay
Perhaps something like this:
for i in `ll -d /dev/vg* |grep -v vg00`
do
vgdisplay -v $i
done
Pete
Pete
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-07-2003 01:57 AM
11-07-2003 01:57 AM
Re: vgdisplay
Will show all volume groups, followed by the disks in the volume groups.
If you followed the vg naming convention the query can be further refined.
strings /etc/lvmtab | grep vg
/dev/vg01
/dev/vg11
This output can then be used as the input to the vgdisplay -v command
strings /etc/lvmtab | grep vg > file
read -r aa
do
vgdisplay -v $aa
done < file
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-07-2003 02:03 AM
11-07-2003 02:03 AM
Re: vgdisplay
All your answers are working find.. I'll use one of those in one script....
Thanks again!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-07-2003 02:07 AM
11-07-2003 02:07 AM
Re: vgdisplay
for i in `ls -d /dev/vg*`
do
[ $i = "/dev/vg00" ] || {
vgdisplay -v $i
}
done
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-07-2003 02:07 AM
11-07-2003 02:07 AM
Re: vgdisplay
for i in `ll -d /dev/vg* |grep -v vg00 |sed s"/\/dev\///g"| sed s"/\///"`
do
vgdisplay -v $i
done
Pete
Pete
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-07-2003 02:11 AM
11-07-2003 02:11 AM
Re: vgdisplay
strings lvmtab | grep -v dsk | grep -v vg00 | xargs vgdisplay -v {}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-07-2003 02:16 AM
11-07-2003 02:16 AM
Re: vgdisplay
strings lvmtab | grep -v dsk | grep -v '/dev/vg00$' | xargs vgdisplay -v
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-07-2003 02:20 AM
11-07-2003 02:20 AM
Re: vgdisplay
for i in `ls -d /dev/vg* |grep -v vg00 |sed s"/\/dev\///g"| sed s"/\///"`
do
vgdisplay -v $i
done
Pete
Pete
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-07-2003 02:43 AM
11-07-2003 02:43 AM
Re: vgdisplay
Why are you trying so hard to get rid of that "/dev", vgdisplay doesn't mind if it's there or not!