September 12, 2009

ASM Hands-On Training, Server Enviroment Setup And Aliases

The server where the labs of the ASM Hands-On Training works is configured with tcsh as the default oracle user shell.

A .cshrc file containing several aliases was setup to easy moving around and executing repetitive commands.

On this document there is a general explanation of how the environment can be used.

Details on this file: Server Enviroment Setup And Aliases

ASM Hands-On Training, Lab 21, ASMCMD Use And Options

On this lab we will review some of the useful set of commands provided by the ASM command line utility.

Some of the asmcmd commands display information, these information is based on v$asm views, other commands actually make changes to the structure like mkdir or rm.

Details on file: ASMCMD Use And Options

ASM Hands-On Training, Lab 20, Storage Consolidation With ASM

On this lab we will share our ASM disks with a second server and we will open the sati12 database on it.

To do that we copied the vm to another location, without including the ASM disks, that are located on a separate folder, this way the second vm is pointing to the same ASM disks as the first one.

Details on file: Storage Consolidation With ASM

ASM Hands-On Training, Lab18, ASM Metadata and Other Checkups

On this lab we will review various utilities that provide further information for managing ASM.

Checksum Mismatch After Storage Crash, AMDU an 11g tool that can be used with 10g as well, Blockdumps, Asmiostats and asmdebug

Details on this file: ASM Metadata and Other Checkups

ASM Hands-On Training, Lab 17, Measuring Throughput

On this lab we will review simple methods for getting input about the the database througput and response time.

We will produce the load using swingbench and we will gather AWR snapshots every 10 minutes. After some time we will be able to check througput statistics based on the AWR snapshots information.

Details on this Document: Measuring Throughput

Another useful script for checking IO:

set pages 50000 lines 250
alter session set nls_date_format='dd-mm-yy hh24:mi';
spool chkio1-Physical-rw.log
select min(begin_time), max(end_time),
sum(case metric_name when 'Physical Read Total Bytes Per Sec' then average end) Physical_Read_Total_Bps,
sum(case metric_name when 'Physical Write Total Bytes Per Sec' then average end) Physical_Write_Total_Bps,
snap_id
from dba_hist_sysmetric_summary
group by snap_id
order by snap_id;
spool off

select min(begin_time), max(end_time),
sum(case metric_name when 'Physical Read Total Bytes Per Sec' then maxval end) Physical_Read_Total_Bps,
sum(case metric_name when 'Physical Write Total Bytes Per Sec' then maxval end) Physical_Write_Total_Bps,
sum(case metric_name when 'Physical Read Total Bytes Per Sec' then maxval end) +
sum(case metric_name when 'Physical Write Total Bytes Per Sec' then maxval end) Total_IO,
snap_id
from dba_hist_sysmetric_summary
group by snap_id
order by snap_id
/

ASM Hands-On Training, Lab 16, Configuring And Running Swingbench And OSWatcher

Whenever implementing new environments it is convenient to run stress tests and to gather OS statistics that will provide valuable diagnostics information.

Swingbench provide an easy configurable tool to run oltp or dss like stress tests; that is very useful when the customer does not have any possibility to benchmark the new configuration.

Oswatcher will collect statistics from the OS in a cyclic 2-day period by default, which can be extended to whatever period is convenient for you.

Details on this file:
Lab16-Configure-SwingBench-and-OsWatcher.pdf

ASM Hands-On Training, Lab 15, Cloning A Disk Group

Sometimes it is required having several clones of the same database running on the same server. That was simple to do when the database was based on File System, and is still simple to do with the help of Rman.

But there are very large databases, which are usually cloned using storage tools like bcv, srdf or snapshots that cannot consider Rman as a viable possibility.

For these databases there is the possibility to implement the procedure we will test on this lab.

Note that the rename disk group script has not been made public.
The rename disk group functionality is available on 11g R2 that was made available to the general public on August 2009.

These are the steps required to complete the process:

1. Prepare a set of storage devices with enough space to hold a copy of the diskgroup to be copied
2. Shutdown the source database
3. Make a bit by bit copy of the source database on the target devices
4. Add kfed path to the path of user root
5. Execute the rename diskgroup script
6. Rename ASM disks of the cloned devices
7. Rescan ASM disks
8. Start the ASM instance and mount the new diskgroup
9. Recreate the controlfile and rename the database based on the cloned diskgroup
10.Open the clone with the resetlogs option

Details on this file:
Cloning Disk Group

ASM Hands-On Training, Lab 14, 11g Compatibility Parameters and Resilience Test

On this lab we will make a review of the 11g Compatibility Parameters and 3 Resilience Tests

The compatibility parameters compatible.asm and compatible.rdbms define the minimum ASM and database versions that will be able to connect to a disk group. These parameters can be advanced only

On the resilience probe we will do the following tests

  • · Add ASM disks and bring down the ASM instance on the middle of the operation
  • · Remove ASM disks and bring down the ASM instance on the middle of the operation
  • · Destroy the ASM metadata and restore the disk

Details on this file:
11g Compatibility Parameters and Resilience Test

ASM Hands-On Training, Lab 13, ASM And Rman: Crash, Restore And Recovery Scenarios

On this Lab we will review the following crash and recovery scenarios, and we will implement some of them:

  • · System tablespace loss
  • · Recover system tablespace
  • · User datafile loss
  • · Recover users tablespace
  • · Online redo loss
  • · Recover from redo loss
  • · Controlfile loss
  • · Recover from controlfile loss
  • · Database loss
  • · Recover from total loss

Details on this file
ASM and Rman Crash Restore and Recovery Scenarios

ASM Hands-On Training, Labs 11 and 12 : Restoring A Lost Database From Backup And Cleanup File Based ASM Diskgroups

To work on the 11g part of the Labs we will start restoring an 11g database we have on a backup.
The backup consist of an incremental level 0 backupset, a controlfile and spfile backup and the archived logs required to recover the database.

The restore is done in 6 steps
· Re-create the ASM metada
· Restore the spfile
· Restore the controlfile
· Restore the datafiles
· Recover the database
· Open resetlogs

This is covered on this file:
Restoring a Lost Database From Backup

On the previous Labs we created ASM disks based on OS Files, before continuing with the next labs we need to clear them.

This is explained on this file:
Cleanup File based ASM Diskgroups

About

Principal Support Consultant Oracle Advanced Customer Services

Categories

Powered by
Movable Type and Oracle