Operating System - HP-UX
1752808 Members
5612 Online
108789 Solutions
New Discussion юеВ

how to manage raw volume ???

 
Vasago
Occasional Contributor

how to manage raw volume ???

Hi,

Running HP-UX with Oracle. Some Database are on RAW LV.

How i can manage RAW LV ? (ex : show how space are used on raw device...)

i can do an lvdisplay but that don't give me space used... :

LV Name /dev/vgoracle/lvora1
VG Name /dev/vgoracle
LV Permission read/write
LV Status available/syncd
Mirror copies 0
Consistency Recovery MWC
Schedule parallel
LV Size (Mbytes) 300000
Current LE 9375
Allocated PE 9375
Stripes 0
Stripe Size (Kbytes) 0
Bad block on
Allocation strict
IO Timeout (Seconds) default
9 REPLIES 9
G. Vrijhoeven
Honored Contributor

Re: how to manage raw volume ???

Hi

I would look for usage within Oracle management tools. I do not think it is possible to view using a UNIX command, May be a backup tool?

HTH,

Gideon
Patrick Wallek
Honored Contributor

Re: how to manage raw volume ???

>> how to manage raw volume ???

VERY VERY CAREFULLY!!!!

There is no way that I know of for you to see the space used on a raw LV at the unix level. That's what oracle tools are for.

A. Clay Stephenson
Acclaimed Contributor

Re: how to manage raw volume ???

From the perspective of the OS, your question has absolutely no meaning; how the space is used within a raw volume is solely determined by the application (Oracle in this case).

You can start by doing a "select * from dba_data_files". The "bytes" column will indicate the total size of the tablespace which must be be less than or equal to the LV Size returned by lvdisplay.
If it ain't broke, I can fix that.
Steven E. Protter
Exalted Contributor

Re: how to manage raw volume ???

In /dev/vgorcle

Make sure the oracle user owns the special device files.

All other management of this raw space must be done with sqlplus or tools provided by oracle.

I manage Software AG databases raw.

All I can do in the OS is create the logical volumes, change the ownership and then start using the SAG tools.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
generic_1
Respected Contributor

Re: how to manage raw volume ???

Ask your local DBA how to use their tools if you are deeply intersted. Since you have root you should be able to run any tools they use. Really they should be the ones who need to manage whether they have enough space. If they are not keeping up with it and giving you last minutes requests defining a SLA might help :).
Juergen Tappe
Valued Contributor

Re: how to manage raw volume ???

To see how "full" the Datafiles are:

db_studio is a nice graphical Oracle tool.
You need to have an oracle login (diffenrent to the Unix login).

the set your enviroment correctly (su - oracle) does this normaly.
... and try "oemapp dba_studio".

If it is installed on that Unix box you'll get a GUI where you have to connect to the required instance and then you should look under Storage / Datafiles ......

But from pure SYSTEM Admin view I guess you dont need care about that. DBAs should :-)
Working together
Hein van den Heuvel
Honored Contributor

Re: how to manage raw volume ???

You just foudn out why they label raw devices a managemetn nightmare! It is all up to you. The (Operating) system will not help. These are RAW devices, no window dressing. You have to astablish and adhere to:
- Carefull naming
- Carefull sizing
- Carefull ownership settings


Clay wrote: "You can start by doing a "select * from dba_data_files". "

Right. But is only a start.Besides datafile Oracle also has temp files, redo logs, control files.

Here is a procedure I use. You would need to run it once for every instance you manage.

column status format a8
column member format a55
column file_name format a45
column Tablespace format a15
column segment_name format a15
column extent_name format a15
column owner format a10
column file format a45
column id format 99

set pages 9999
set heading off
set FEEDBACK off
select 'redo_'||l.group# "Tablespace", l.group# "Id", l.bytes/(1024*1024) "MB",
MEMBER "File" from v$logfile f, v$log l where l.group# = f.group#
union
select tablespace_name "Tablespace", FILE_ID "Id", bytes/(1024*1024) "MB",
file_name "File" from dba_data_files
union
select tablespace_name "Tablespace", FILE_ID "Id", bytes/(1024*1024) "MB",
file_name "File" from dba_temp_files
union
select 'Control_file' "Tablespace", rownum "Id", 0 "MB",
name "File" from v$controlfile
order by 1
/
Bill Hassell
Honored Contributor

Re: how to manage raw volume ???

A raw volume has no files and no concept of full or empty as far as HP-UX is concerned. Only Oracle knows how the lvols are laid out and how much space is being used. By choosing to use raw volumes, you have turned over ALL responsibility for disk space to your DBAs. There is nothing you can do except to learn Oracle and the various status tools to see how the space is being managed,


Bill Hassell, sysadmin
Vasago
Occasional Contributor

Re: how to manage raw volume ???

Thanks to all,

By the way :

I have found Oracle doc about using RAW volume with oracle. But not exactly for HP-UX... Here what i have made on the server :

1. Give ownership to oracle user on the raw disk (/dev/vgoracle/rlvora1)
2. chmod 600 on the raw disk
3. Using ln -sf to create symbolic file (.dbf that point on the raw disk)
4. Used Enteprise manager to create new tablespace that point on .dbf (with reuse option)

Somebody can tell me if this procedure are OK ? If optimisatioon configuration or tool exist for RAW volume...

thanks