content top

How to Install/Update Java (JDK) on Oracle Linux

Oracle Linux uses RPM (Red Hat Package Manager). If you want to install latest Java platform, you can download Java RPM packages from:

http://www.oracle.com/technetwork/java/javase/downloads/index.html

Oracle releases Java RPM wrapped in a self-extracting binary file. So instead of using rpm tool, you just change the mode of file, and make it executable and then run it:

Is it done? Let’s check it:

Read More

How to Install Oracle Linux 5.6 (Step by Step Guide)

Oracle Linux, formerly known as Oracle Enterprise Linux, is a Red Hat Enterprise Linux-compatible distribution, repackaged and distributed by Oracle, available under the GNU General Public License (GPL) since late 2006. Oracle Linux can be freely downloaded from Oracle’s E-delivery service (edelivery.oracle.com).

I’ll show how to install Oracle Linux 5.6. First you need to download the DVD (or CDs) from edelivery website and burn them. Then insert your Oracle Linux media in your CD/DVD drive and reboot your system (be sure to set your computer to boot from the CD/DVD drive).

Oracle Linux installer should boot as shown in the figure below:

Hit enter key to start the installation.

Read More

How to Automate Startup/Shutdown of Oracle Database on Linux

There are already good sample scripts for automating database startup and shutdown (i.e. check Tim Hall’s oracle-base.com or read MOS [ID 222813.1]), but I wanted to create a wizard to generate “dbora” script according to your inputs. So here it is:

http://apex.oracle.com/pls/apex/f?p=22258:1

This script uses dbstart/dbshut scripts of Oracle. If dbstart/dbshut scripts return the error: “Test: Argument Expected”, you should replace the value #!/bin/sh with the value #!/bin/bash in the first line of dbstart/dbshut files (MOS [ID 369923.1]).

I have also create a wizard to generate shell profile files:

http://apex.oracle.com/pls/apex/f?p=22258:2

I hope you find them useful. Feel free to post your feedback and suggestions here.

Create AWR and ADDM Reports and Send Them via Email

I’ve seen a question on OTN forum about how to create a job in Grid Control for generating AWR/ADDM reports and send these reports via email. As I know OEM Grid Control doesn’t have such a job template but we can write a PL/SQL script for this task and define it as a job, so we can automate it for all databases.

First, let’s check how we can generate AWR reports. To be able to get AWR reports in plain text, we can use:

Syntax (for Oracle 10.2)

DBMS_WORKLOAD_REPOSITORY.AWR_REPORT_TEXT(
l_dbid IN NUMBER,
l_inst_num IN NUMBER,
l_bid IN NUMBER,
l_eid IN NUMBER,
l_options IN NUMBER DEFAULT 0)
RETURN awrrpt_text_type_table PIPELINED;

If we want the report in HTML, we can use:

DBMS_WORKLOAD_REPOSITORY.AWR_REPORT_HTML(
l_dbid IN NUMBER,
l_inst_num IN NUMBER,
l_bid IN NUMBER,
l_eid IN NUMBER,
l_options IN NUMBER DEFAULT 0)
RETURN awrrpt_text_type_table PIPELINED;

Read More

How to Gather the Header Information and the Content of an Export Dumpfile?

I’ve found a great document at My Oracle Support (Metalink): How to Gather the Header Information and the Content of an Export Dumpfile? [ID 462488.1]. The document explains how to extract DDL statements from dumpfiles and how to use GET_DUMPFILE_INFO procedure (of DBMS_DATAPUMP package) to gather header information for both original and datapump exports.

In summary,

The Data Definition Language (DDL) statements in a DataPump dumpfile can be extracted with the parameter SQLFILE:

Note: This command will not import the data, but it still needs a valid database connection.

The Data Definition Language (DDL) statements in a original export file can be extracted with the parameter SHOW:

Sample PL/SQL code which uses DBMS_DATAPUMP.GET_DUMPFILE_INFO can be found at MOS [ID 462488.1]. Unfortunately this procedure can only be used in an Oracle10g Release 2 or any higher release database.

After I’ve made some tests with PL/SQL code, I decided to examine Oracle export files and write my own utility to read the header information.

Read More
Page 12 of 23« First...1011121314...Last »
content top