- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Create 1 vg on 2 disks
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
10-21-2002 08:40 AM
10-21-2002 08:40 AM
The system is a K460 running HP-UX 11.0. The two disks are /dev/dsk/c0t4d0 and /dev/dsk/c0t5d0. Each are 8678 mbytes. I would like to make the two disks into one volume group with all available disk space in this one volume group (for database tables - I don't care about anything that may be currently on the disks).
I can create vg's on a single disk with no problem but I looking for advice and commands for creating volume groups with more than one disk. Any and all help will be appreciated.
I will be away from email for a couple of days but will assign points as soon as possible. Thank you
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-21-2002 08:43 AM
10-21-2002 08:43 AM
Solutionpvcreate /dev/dsk/cxtxdx
to create the volume group with both disks:
1. mkdir /dev/vgxx (if not alread done)
2. cd /dev/vgxx
3. mknod group c 64 0x0x0000 (note the second x should be substituted with the number of your volume group)... you may have done this already as well
4. vgcreate /dev/vgxx /dev/dsk/c0t4d0 /dev/dsk/c0t5d0
you will get both disks in the new volume group
if you already created the volume group with one disk and want to add the other one
vgextend /dev/vgxx /dev/dsk/cxtxdx (the disk you want to add)
Ted
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-21-2002 08:45 AM
10-21-2002 08:45 AM
Re: Create 1 vg on 2 disks
You next run a vgcreate using one of the disks. Next do a vgchange -a y /dev/vgxx to activate the VG followed by a vgextend command to include the other disk.
You are now ready to create logical volumes using the lvcreate command and then followed by a newfs command to create the file system.
Man pvcreate, vgcreate, vgchange, vgextend, lvcreate, and newfs for details OR simply do all this from SAM->Disks and Filesystems. Sam will perform all these steps for you.
Regards, Clay
You can then follow this up
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-21-2002 08:50 AM
10-21-2002 08:50 AM
Re: Create 1 vg on 2 disks
Do this:
# mkdir /dev/vgXX
# mknod /dev/vgXX/group c 64 0x0N0000
Note the minor number 'N' in 'mknod' must be unique. By convention is matches the convention used for the volume group name. Thus, if the volume group were "VG03" then 'N' would be '3'. You can do:
# ls -l /dev/vg*/group
...to discern what minor numbers have already been used.
# pvcreate /dev/dsk/c0t4d0
# pvcreate /dev/dsk/c0t5d0
# vgcreate /dev/vgXX /dev/dsk/c0t4d0 /dev/dsk/c0t5d0
Note that you may want to specify non-default values for 'pe_size', 'max_pe', 'max_pv' and/or 'max_lv' during the volume group creation since they cannot be changed later. Look at the man pages for 'vgcreate'.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-21-2002 09:02 AM
10-21-2002 09:02 AM
Re: Create 1 vg on 2 disks
mkdir /dev/vgnew
mknod /dev/vgnew/group c 64 0x300000 (300000 in unique0
pvcreate -f /dev/rdsk/c0t4d0
pvcreate -f /dev/rdsk/c0t5d0
vgcreate /dev/vgnew /dev/dsk/c0t4d0 /dev/dsk/c0t5d0
and then create the LV etc
Manoj Srivastava
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-21-2002 09:18 AM
10-21-2002 09:18 AM
Re: Create 1 vg on 2 disks
vgextend vgname /dev/dsk/c0t5d0
Use pvcreate -f on the disk prior to adding to vg. In the future, to create a vg with multiple disks, add the disk device name to the end of the vgcreate command:
vgcreate vg01 /dev/dsk/c0t4d0 /dev/dsk/c0t5d0
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-21-2002 09:49 AM
10-21-2002 09:49 AM
Re: Create 1 vg on 2 disks
The necessity to use the 'f'orce option of 'pvcreate' occurs when the physical disk still has a Volume Group Identifier (VGID) in its Physical Volume Reserved Area (PVRA). This will be the case for a disk that was once part of a volume group that was 'vgexport'ed. Since this is the quickest way to destroy a volume group, many people stumble on the need to force a 'pvcreate' to ignore the VGID information.
If a volume group is destroyed with a 'vgremove' then the VGID is erased at that time and a simple (unforced) 'pvcreate' suffices.
Either a 'vgexport' or a 'vgremove' of a volume group eliminates all references to the physical disk from '/etc/lvmtab'. In addition, the 'vgexport' also removes the device files for the volume group in '/dev/vg*' which is quite convenient.
Personally, I always do a 'pvcreate -f' at the time I destroy a volume group's physical volume(s). In that way when I do a simple 'pvcreate' later, I *really* pay attention if I get the message "The physical volume already belongs to a volume group". Then, in that case I know I probably don't have the disk I want.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-21-2002 11:21 AM
10-21-2002 11:21 AM
Re: Create 1 vg on 2 disks
This is described in an example in the man pages for vgcreate (man vgcreate).
A more "user friendly" method is to use SAM.
Start SAM, select "Disk and File systems", select "Volume Groups", select Actions/Create, Select "New Volume Group Name, and last, "Select Disks".
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-21-2002 11:21 AM
10-21-2002 11:21 AM
Re: Create 1 vg on 2 disks
I believe that I'll be able to handle it from here.
Again, thanks.
Scott