Creating a logical volume file

Hi to all,

I am brand new to HP-UX but am quite familiar with Linux systems (Red Hat, Ubuntu etc..)

I've just taken over a new HP-UX box and trying to work out how to create a logical volume.

As well as creating the volume, which I am sure is very easy I need to create a special character file for an Oracle database datafile.

Some details:

# vgdisplay -v vg02
--- Volume groups ---
VG Name                     /dev/vg02
VG Write Access             read/write
VG Status                   available
Max LV                      255
Cur LV                      15
Open LV                     15
Max PV                      16
Cur PV                      1
Act PV                      1
Max PE per PV               17493
VGDA                        2
PE Size (Mbytes)            8
Total PE                    17493
Alloc PE                    11510
Free PE                     5983
Total PVG                   0
Total Spare PVs             0
Total Spare PVs in use      0
VG Version                  1.0
VG Max Size                 2239104m
VG Max Extents              279888

   --- Logical volumes ---
   LV Name                     /dev/vg02/_efinl_sysaux1
   LV Status                   available/syncd
   LV Size (Mbytes)            512
   Current LE                  64
   Allocated PE                64
   Used PV                     1

   LV Name                     /dev/vg02/_efinl_system1
   LV Status                   available/syncd
   LV Size (Mbytes)            640
   Current LE                  80
   Allocated PE                80
   Used PV                     1

   LV Name                     /dev/vg02/_efinl_tools1
   LV Status                   available/syncd
   LV Size (Mbytes)            104
   Current LE                  13
   Allocated PE                13
   Used PV                     1

   LV Name                     /dev/vg02/_efinl_users1
   LV Status                   available/syncd
   LV Size (Mbytes)            104
   Current LE                  13
   Allocated PE                13
   Used PV                     1

   LV Name                     /dev/vg02/_efinl_efinliver_dts1
   LV Status                   available/syncd
   LV Size (Mbytes)            304
   Current LE                  38
   Allocated PE                38
   Used PV                     1

   LV Name                     /dev/vg02/_efint_efintestr_dts1
   LV Status                   available/syncd
   LV Size (Mbytes)            304
   Current LE                  38
   Allocated PE                38
   Used PV                     1

   LV Name                     /dev/vg02/_css_pagf1
   LV Status                   available/syncd
   LV Size (Mbytes)            24576
   Current LE                  3072
   Allocated PE                3072
   Used PV                     1

   LV Name                     /dev/vg02/_css_pagf2
   LV Status                   available/syncd
   LV Size (Mbytes)            8192
   Current LE                  1024
   Allocated PE                1024
   Used PV                     1

   LV Name                     /dev/vg02/_css_pagf3
   LV Status                   available/syncd
   LV Size (Mbytes)            8192
   Current LE                  1024
   Allocated PE                1024
   Used PV                     1

   LV Name                     /dev/vg02/_css_pagf4
   LV Status                   available/syncd
   LV Size (Mbytes)            8192
   Current LE                  1024
   Allocated PE                1024
   Used PV                     1

   LV Name                     /dev/vg02/_css_pagf5
   LV Status                   available/syncd
   LV Size (Mbytes)            8192
   Current LE                  1024
   Allocated PE                1024
   Used PV                     1

   LV Name                     /dev/vg02/_css_pagf6
   LV Status                   available/syncd
   LV Size (Mbytes)            8192
   Current LE                  1024
   Allocated PE                1024
   Used PV                     1

   LV Name                     /dev/vg02/_css_pagf7
   LV Status                   available/syncd
   LV Size (Mbytes)            8192
   Current LE                  1024
   Allocated PE                1024
   Used PV                     1

   LV Name                     /dev/vg02/_css_pagf8
   LV Status                   available/syncd
   LV Size (Mbytes)            8192
   Current LE                  1024
   Allocated PE                1024
   Used PV                     1

   LV Name                     /dev/vg02/_css_pagf9
   LV Status                   available/syncd
   LV Size (Mbytes)            8192
   Current LE                  1024
   Allocated PE                1024
   Used PV                     1


   --- Physical volumes ---
   PV Name                     /dev/dsk/c0t0d0
   PV Status                   available
   Total PE                    17493
   Free PE                     5983
   Autoswitch                  On
   Proactive Polling           On


# bdf /disk1
Filesystem          kbytes    used   avail %used Mounted on
/dev/dsk/c0t1d1    71652960 31511906 37653489   46% /disk1

# pwd
/dev/vg02

# ls -la
total 32
drwxr-xr-x   2 root       sys           8192 Jan 12 15:29 .
dr-xr-xr-x  26 bin        bin           8192 Feb 23 11:49 ..
brw-r-----   1 root       sys         64 0x020007 Apr 10  2010 _css_pagf1
brw-r-----   1 root       sys         64 0x020008 Jun 22  2010 _css_pagf2
brw-r-----   1 root       sys         64 0x020009 Sep 13  2010 _css_pagf3
brw-r-----   1 root       sys         64 0x02000a Jan  1  2011 _css_pagf4
brw-r-----   1 root       sys         64 0x02000b Mar 17  2011 _css_pagf5
brw-r-----   1 root       sys         64 0x02000c May 11  2011 _css_pagf6
brw-r-----   1 root       sys         64 0x02000d Aug 30 09:22 _css_pagf7
brw-r-----   1 root       sys         64 0x02000e Oct 13 17:56 _css_pagf8
brw-r-----   1 root       sys         64 0x02000f Jan 12 15:29 _css_pagf9
brw-r-----   1 root       sys         64 0x020005 Jun 11  2008 _efinl_efinliver_dts1
brw-r-----   1 root       sys         64 0x020001 Jun 11  2008 _efinl_sysaux1
brw-r-----   1 root       sys         64 0x020002 Jun 11  2008 _efinl_system1
brw-r-----   1 root       sys         64 0x020003 Jun 11  2008 _efinl_tools1
brw-r-----   1 root       sys         64 0x020004 Jun 11  2008 _efinl_users1
brw-r-----   1 root       sys         64 0x020006 Aug  9  2008 _efint_efintestr_dts1
crw-r-----   1 root       sys         64 0x020000 Jun 11  2008 group
crw-rw-rw-   1 root       sys         64 0x020007 Apr 10  2010 r_css_pagf1
crw-rw-rw-   1 root       sys         64 0x020008 Jun 22  2010 r_css_pagf2
crw-rw-rw-   1 root       sys         64 0x020009 Sep 13  2010 r_css_pagf3
crw-rw-rw-   1 root       sys         64 0x02000a Jan  1  2011 r_css_pagf4
crw-rw-rw-   1 root       sys         64 0x02000b Mar 17  2011 r_css_pagf5
crw-rw-rw-   1 root       sys         64 0x02000c May 11  2011 r_css_pagf6
crw-rw-rw-   1 root       sys         64 0x02000d Aug 30 09:22 r_css_pagf7
crw-rw-rw-   1 root       sys         64 0x02000e Oct 13 17:56 r_css_pagf8
crw-rw-rw-   1 root       sys         64 0x02000f Jan 12 15:29 r_css_pagf9
crw-rw-rw-   1 root       sys         64 0x020005 Jun 11  2008 r_efinl_efinliver_dts1
crw-rw-rw-   1 root       sys         64 0x020001 Jun 11  2008 r_efinl_sysaux1
crw-rw-rw-   1 root       sys         64 0x020002 Jun 11  2008 r_efinl_system1
crw-rw-rw-   1 root       sys         64 0x020003 Jun 11  2008 r_efinl_tools1
crw-rw-rw-   1 root       sys         64 0x020004 Jun 11  2008 r_efinl_users1
crw-rw-rw-   1 root       sys         64 0x020006 Aug  9  2008 r_efint_efintestr_dts1

What I am trying to do is create a special file like the "r_css_pagf9"

Unfortunately the person that usually deals with this is no longer available and I am having to do his job for him and hence the assistance.

Any questions? Please ask.

Thanks to all that reply.

Could you say more about your system (model, OS version...) for I am a bit surprised by what I see...
I would like to see vg00 display and more the output of bdf command to understand a bit...
By the look at things, you never had disk issues... (your display is a bit scary for someone used to solve sever issues...) or did the guy in charge realized and ran away before?( with such implemetation you need really good backups AND documentation on all config stuff...)

HP9000 running HP-UX with a IA64 / version 11.1

vgdisplay -v vg00
--- Volume groups ---
VG Name                     /dev/vg00
VG Write Access             read/write
VG Status                   available
Max LV                      255
Cur LV                      10
Open LV                     10
Max PV                      16
Cur PV                      1
Act PV                      1
Max PE per PV               4320
VGDA                        2
PE Size (Mbytes)            16
Total PE                    4310
Alloc PE                    3683
Free PE                     627
Total PVG                   0
Total Spare PVs             0
Total Spare PVs in use      0
VG Version                  1.0
VG Max Size                 1080g
VG Max Extents              69120

   --- Logical volumes ---
   LV Name                     /dev/vg00/lvol1
   LV Status                   available/syncd
   LV Size (Mbytes)            1792
   Current LE                  112
   Allocated PE                112
   Used PV                     1

   LV Name                     /dev/vg00/lvol2
   LV Status                   available/syncd
   LV Size (Mbytes)            8192
   Current LE                  512
   Allocated PE                512
   Used PV                     1

   LV Name                     /dev/vg00/lvol3
   LV Status                   available/syncd
   LV Size (Mbytes)            1024
   Current LE                  64
   Allocated PE                64
   Used PV                     1

   LV Name                     /dev/vg00/lvol4
   LV Status                   available/syncd
   LV Size (Mbytes)            2048
   Current LE                  128
   Allocated PE                128
   Used PV                     1

   LV Name                     /dev/vg00/lvol5
   LV Status                   available/syncd
   LV Size (Mbytes)            112
   Current LE                  7
   Allocated PE                7
   Used PV                     1

   LV Name                     /dev/vg00/lvol6
   LV Status                   available/syncd
   LV Size (Mbytes)            8144
   Current LE                  509
   Allocated PE                509
   Used PV                     1

   LV Name                     /dev/vg00/lvol7
   LV Status                   available/syncd
   LV Size (Mbytes)            4336
   Current LE                  271
   Allocated PE                271
   Used PV                     1

   LV Name                     /dev/vg00/lvol8
   LV Status                   available/syncd
   LV Size (Mbytes)            8704
   Current LE                  544
   Allocated PE                544
   Used PV                     1

   LV Name                     /dev/vg00/lvol9
   LV Status                   available/syncd
   LV Size (Mbytes)            16384
   Current LE                  1024
   Allocated PE                1024
   Used PV                     1

   LV Name                     /dev/vg00/lvol10
   LV Status                   available/syncd
   LV Size (Mbytes)            8192
   Current LE                  512
   Allocated PE                512
   Used PV                     1


   --- Physical volumes ---
   PV Name                     /dev/disk/disk3_p2
   PV Status                   available
   Total PE                    4310
   Free PE                     627
   Autoswitch                  On
   Proactive Polling           On


bdf
Filesystem          kbytes    used   avail %used Mounted on
/dev/vg00/lvol3    1048576  698432  347448   67% /
/dev/vg00/lvol1    1835008  323992 1499288   18% /stand
/dev/vg00/lvol8    8912896 4952688 3932176   56% /var
/dev/vg00/lvol7    4440064 3481640  951016   79% /usr
/dev/vg00/lvol4     524288   25304  495528    5% /tmp
/dev/vg00/lvol6    8339456 6826528 1510296   82% /opt
/dev/vg00/lvol5     114688   10456  103432    9% /home
/dev/vg00/lvol9    16777216 1366678 14454162    9% /dump
/dev/dsk/c0t1d1    71652960 42522864 27330696   61% /disk1
DevFS                   11      11       0  100% /dev/deviceFileSystem
xray:/opt/css/bddata
                   16777216 14910056 1862024   89% /opt/css/bddata
xray:/opt/css/caspardata
                   16777216 14910056 1862024   89% /opt/css/caspardata
xray:/opt/css/conservatories
                   16777216 14910056 1862024   89% /opt/css/conservatories
xray:/opt/css/datadir
                   16777216 14910056 1862024   89% /opt/css/datadir
xray:/opt/css/pcf  16777216 14910056 1862024   89% /opt/css/pcf
xray:/opt/css/faxdir
                   16777216 14910056 1862024   89% /opt/css/faxdir
xray:/opt/css/kcslive
                   16777216 14910056 1862024   89% /opt/css/kcslive
xray:/opt/css/pdfdir
                   16777216 14910056 1862024   89% /opt/css/pdfdir
xray:/opt/css/statsdir
                   16777216 14910056 1862024   89% /opt/css/statsdir
xray:/opt/css/reprint
                   16777216 14910056 1862024   89% /opt/css/reprint
xray:/opt/css/home 16777216 14910056 1862024   89% /opt/css/home
xray:/opt/css/xtst 16777216 14910056 1862024   89% /opt/css/xtst
xray:/opt/css/tempdir
                   16777216 14910056 1862024   89% /opt/css/tempdir
xray:/sms           204800  105240   99056   52% /sms
sdchub01:/sdcserver
                   104855548 39758392 65097156   38% /sdcserver
cuf2k01:/server    71103484 61591992 9511492   87% /casparserver

First of all, please do use code tags around while posting outputs/commands for readability.

Creating volume groups in HP-UX is a lot similar to doing that in RHEL or Linux. Use lvcreate command to create a new logical volume.

lvcreate -L size_in_MB /dev/vg00

Download this document from HP for more info on LVM:
http://www.google.co.in/url?sa=t&rct=j&q=hp-ux%20system%20admin%20guide%20logical%20volume%20management&source=web&cd=1&ved=0CCMQFjAA&url=http%3A%2F%2Fbizsupport2.austin.hp.com%2Fbc%2Fdocs%2Fsupport%2FSupportManual%2Fc02023734%2Fc02023734.pdf&ei=xdhGT5qqGInXrQe7iPmXCw&usg=AFQjCNG6koomr9CGpgx7opPcIKN85F2u7Q&sig2=eYuHsaL0z7If5Jm3BKiNpw

Hi,

Sorry about that. I am not actually putting the code tags in. All I am doing is copying and pasting to and from and it seems to add it as a code tag.

I've actually been able to work out how to create the logical volume now. I am now just having a problem with creating a raw datafile for an Oracle database but this is another problem.

Thanks for all the assistance.

Why is it we see no vg02 lvols mounted? where is vg00/lvol10?
Have you noticed the difference between vg00 and vg02 (lvol names...)?

I suggest you use SAM (System Administration Manager, sam command) to go through the creation of such devices, for sam will check before execution (e.g. size...). Later, use command line, its faster...
I have no IA64 so menu may differ...
choose "Disk and File Systems", "Logical Volums" (Little delay: the system scans its HW...)
On the menu bar, choose "Create" then choose the VG, validate, then go to next option:
"Define new Logical Volume", a new widow will open:
choose lvol name
Give size...

It will create automatically the JFS Filesystem in it...

All the best

In the same Last window there is a menu box: choose ( I think - I have no oracle raw FS...) "raw" instead of Filesystem, I you choose swap it will create a syste swap device (no good...)