- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Script to create volume groups
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
04-24-2007 10:36 PM
04-24-2007 10:36 PM
I have a server with cluster setup as per the client requirement i need to create some 50 volume groups can any one provide me the script.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-24-2007 11:17 PM
04-24-2007 11:17 PM
SolutionThere are really only three steps to create a volume group.
mkdir /dev/
mkdir /dev/vg01
mknod /dev/vg01/group c 64 0x010000
I change the 01 after the x to match the volume group name.
vgcreate with parameters.
vgcreate /dev/vg01 /dev/dsk/c0t3d0
I recommend the -p physical volume limit to allow more space to be crammed into fewer disks.
-p 10
If the disks vary your script will need to take disks as an input parameter.
Simple example script
makemyg.sh
#!/bin/sh
vgname=$1
disk=$2
vgnum= (last two charcaters of vgname some work for you)
mkdir "/dev/${1}"
mknod "/dev/${1}/group c 64 0x${vgnum}0000"
vgcreate "/dev/${1} ${2}"
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
04-25-2007 02:18 AM
04-25-2007 02:18 AM
Re: Script to create volume groups
~cheers
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2007 02:28 AM
04-25-2007 02:28 AM
Re: Script to create volume groups
One thing you will need to check is the MAXVGS kernel parameter. By default this is set to 10. You will need to increase it if you are going to set up 50 VGs.
Another thing -- Do you really need 50 VGs? Could you create fewer VGs and more LVs in each VG?
When scripting this you must remember that the minor number (0x??0000) is in HEX. So VG10 would have 0x0a0000 as the minor number. The system uses the minor number to keep track of the number of VGs as well. A decimal 50 is 32 in HEX.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2007 03:13 AM
04-25-2007 03:13 AM
Re: Script to create volume groups
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-29-2007 04:25 PM
04-29-2007 04:25 PM