Monday, October 24, 2011

Oracle Business Intelligence Applications (OBIA 7.9.6.3) overview

Oracle Business Intelligence Applications (OBIA) are complete, prebuilt BI solutions that deliver intuitive, role-based intelligence for everyone in an organization from front line employees to senior management that enable better decisions, actions, and business processes. Designed for heterogeneous environments, these solutions enable organizations to gain insight from a range of data sources and applications including Siebel, Oracle E-Business Suite, PeopleSoft, and third party systems such as SAP.

Oracle BI Applications are built on the Oracle BI Suite Enterprise Edition, a comprehensive, innovative, and leading BI platform. This enables organizations to realize the value of a packaged BI Application, such as rapid deployment, lower TCO, and built-in best practices, while also being able to very easily extend those solutions to meet their specific needs, or build completely custom BI applications, all on one common BI architecture.

Oracle BI Applications includes the following:
■ Oracle Financial Analytics
■ Oracle Human Resources Analytics
■ Oracle Supply Chain and Order Management Analytics
■ Oracle Procurement and Spend Analytics
■ Oracle Project Analytics
■ Oracle Sales Analytics
■ Oracle Service Analytics
■ Oracle Contact Center Telephony Analytics
■ Oracle Marketing Analytics
■ Oracle Loyalty Analytics
■ Oracle Price Analytics
and more

Oracle BI Applications is a prebuilt business intelligence solution.
Oracle BI Applications supports Oracle sources, such as Oracle E-Business Suite Applications, Oracle's Siebel Applications, Oracle's PeopleSoft Applications, Oracle's JD Edwards Applications, and non-Oracle sources, such as SAP Applications. If you already own one of the above applications, you can purchase Oracle Business Intelligence Enterprise Edition and Oracle BI Applications to work with the application.
Oracle BI Applications also provides complete support for enterprise data, including financial, supply chain, workforce, and procurement and spend sources. These enterprise applications typically source from both Oracle data sources, such as Oracle EBS and PeopleSoft and non-Oracle data sources, such as SAP


Topology for an Oracle BI Applications Deployment

Oracle BI Applications and Informatica PowerCenter can be deployed flexibly across a wide range of topologies on different platforms and combinations of platforms.



Machine A (Windows-only)
Machine A is a machine that has installed Oracle Business Intelligence Enterprise Edition, on which you run the Oracle BI Applications installer to install the Oracle BI Applications files.
Note: The instance of Oracle Business Intelligence Enterprise Edition does not need to be the functional version of Oracle Business Intelligence Enterprise Edition that you will use to deploy dashboards in your live system. This instance is only required to enable the Oracle BI Applications installer to install the Oracle BI Applications files on a machine
After the Oracle BI Applications files have been installed on Machine A, the DAC Client is installed on Machine B, and the DAC Server is installed on Machine C.
In addition, the following files are copied from the installation machine (Machine A) to the Business Intelligence Deployment Tier (Machine Group F) as follows:
- The OracleBI\Server\Repository\OracleBIAnalyticsApps.rpd file is copied from Machine A to the machine that runs the BI Server in Machine Group F.
- The OracleBIData\Web\Catalog\EnterpriseBusinessAnalytics\*.* files are copied from Machine A to the machine that runs the BI Presentation Services Catalog in Machine Group F.


• ETL Tier (Functional)
o Machine B (Windows-only)
Runs the DAC Client and Informatica PowerCenter Client Tools.
o Machine C (Windows, UNIX, Linux)
Runs the DAC Server and Informatica PowerCenter Services.
o Machine D (Windows, UNIX, Linux)
Hosts the transactional (OLTP) database.
o Machine E (Windows, UNIX, Linux)
Hosts the Oracle Business Analytics Warehouse database


• BI Deployment Tier (Functional)
The BI Deployment tier is used to deploy the business intelligence dashboards.
o Machine Group F (Windows, UNIX, Linux)
Machine Group F is a group of machines that runs the Oracle Business Intelligence Enterprise Edition components. For example, one machine might run the BI Server and another machine might run the BI Presentation Services


Oracle Business Analytics warehouse architecture when deployed with Informatica PowerCenter and DAC

High-level analytical queries, like those commonly used in Oracle Business Intelligence, scan and analyze large volumes of data using complex formulas. This process can take a long time when querying a transactional database, which impacts overall system performance.
For this reason, the Oracle Business Analytics Warehouse was constructed using dimensional modeling techniques to allow for fast access to information required for decision making. The Oracle Business Analytics Warehouse derives its data from operational applications and uses Informatica PowerCenter to extract, transform, and load data from various supported transactional database systems (OLTP) into the Oracle Business Analytics Warehouse.



• The Client tier contains the Informatica PowerCenter client tools and the Oracle BI Data Warehouse Administration Console (DAC). DAC is a command and control interface for the data warehouse to allow for set up, configuration, administration, and monitoring of data warehouse processes.

• The Server tier contains the following:
o DAC Server. Executes the instructions from the DAC Client. The DAC Server manages data warehouse processes, including scheduling, loading of the ETL, and configuring the subject areas to be loaded. It dynamically adjusts its actions based on information in the DAC Repository. Depending on your business needs, you might incrementally refresh the Oracle Business Analytics Warehouse once a day, once a week, once a month, or on another similar schedule.
o DAC Repository. Stores the metadata (semantics of the Oracle Business Analytics Warehouse) that represents the data warehouse processes.
o Informatica PowerCenter Services:
 Integration Services - The Integration Service reads workflow information from the repository. The Integration Service connects to the repository through the Repository Service to fetch metadata from the repository.
 Repository Services - The Repository Service manages connections to the PowerCenter Repository from client applications. The Repository Service is a separate, multi-threaded process that retrieves, inserts, and updates metadata in the repository database tables.
o Informatica Repository. Stores the metadata related to Informatica workflows.
• The Database tier contains the OLTP and OLAP databases.


The Informatica Repository stores all of the Informatica object definitions for the ETL mappings that populate the Oracle Business Analytics Warehouse. It is a series of repository tables that are stored in a database, which can be a transactional, analytical, or separate database

Oracle BI Applications Components (with Informatica/DAC)




Oracle Business Analytics Warehouse Overview
The Oracle Business Analytics Warehouse is a unified data repository for all customer-centric data, which supports the analytical requirements of the supported source systems.
The Oracle Business Analytics Warehouse includes the following:
• A complete relational enterprise data warehouse data model with numerous prebuilt star schemas encompassing many conformed dimensions and several hundred fact tables.

• An open architecture to allow organizations to use third-party analytical tools in conjunction with the Oracle Business Analytics Warehouse using the Oracle Business Intelligence Server

• A set of ETL (extract-transform-load) processes that takes data from a wide range of source systems and creates the Oracle Business Analytics Warehouse tables.

• The Oracle Business Intelligence Data Warehouse Administration Console (DAC), a centralized console for the set up, configuration, administration, loading, and monitoring of the Oracle Business Analytics Warehouse

Important points

The metadata for a source system is held in a container
The PowerCenter Services can be installed on UNIX or on Windows.

The PowerCenter Client Tools must be installed on Windows.
You must co-locate the DAC Client with the Informatica PowerCenter Client Tools.
■ You must co-locate the DAC Server with Informatica PowerCenter Services.
DAC produces parameter files that are used by Informatica. If an execution plan
fails in DAC and you want to debug the workflow by running it directly from
Informatica, then the parameter file produced by DAC should be visible to
Informatica. This is one reason for the requirement to co-locate the DAC and
Informatica components as stated above
The DAC installer installs the DAC Client and DAC Server on Windows.

DAC Client only runs on Windows.
DAC Servers runs on Windows, UNIX, and Linux.
The DAC Server can run on Linux, but it must first be installed on a Windows
machine, then copied over to a Linux machine. Oracle does not provides an installer
for DAC on UNIX

The DAC Client can only be installed and run on Windows.
■ The DAC Client must be installed on the machine where Informatica PowerCenter
Client Tools was installed.
■ The DAC Server must be installed on the machine where Informatica PowerCenter
Services was installed.
■ You must install Informatica PowerCenter Services before you install DAC.
■ The correct version of the JDK is installed by the DAC installer.
■ The DAC installer installs DAC in the DAC_HOME\bifoundation\dac directory.


The DAC Client uses the Informatica pmrep and pmcmd command line programs
when communicating with Informatica PowerCenter. The DAC Client uses pmrep to
synchronize DAC tasks with Informatica workflows and to keep the DAC task source
and target tables information up to date.
In order for the DAC Client to be able to use the pmrep and pmcmd programs, the
path of the Informatica Domain file 'domains.infa' must be defined in the environment
variables on the DAC Client machine.
When you install DAC using the DAC installer, the Informatica Domain file is defined
in the environment variables on the DAC Client machine.

INFA_DOMAINS_FILE
C:\Informatica\9.0.1\clients\PowerCenterClient\domains.infa
The DAC Server uses the following command line programs to communicate with
Informatica PowerCenter:
■ pmrep is used to communicate with PowerCenter Repository Services.
■ pmcmd is used to communicate with PowerCenter Integration Services to run the
Informatica workflows.

The pmrep and pmcmd programs are installed during the PowerCenter Services
installation in the INFA_HOME\server\bin directory on the Informatica PowerCenter
Services machine


Oracle Business Intelligence Applications V7.9.6.3 requires Oracle Business
Intelligence Enterprise Edition V11.1.1.5.0.
■ Oracle Business Intelligence Applications V7.9.6.3 requires Informatica
PowerCenter V9.0.1. Hotfix 2.
■ Oracle Business Intelligence Applications V7.9.6.3 requires Oracle Data Warehouse
Console V10.1.3.4.1.

The OBIEE server uses the metadata to generate the SQL queries. It is stored in the
Repository or often referred to as .rpd. The repository has three layer as shown below, the physical layer, logical layer and the presentation layer.

Metadata maps the OBAW physical tables to a generic business model and includes more than 100 presentation catalogs (aka subject areas) to allow queries using Oracle BI clients such as Answers, Dashboards




High Level Data Flow
• Source – eBS (Raw Data)
• ETL – Extraction Transform and Load (Informatica – PowerCenter or
ODI)
• OBAW - Business Analytics Warehouse
• OBIEE Metadata
• OBIEE Content – Reports and Dashboards




• A prebuilt Informatica repository which includes mappings (wrapped in workflows) to extract data from the supported source systems (various versions of standard applications such as Siebel CRM - yes it was first - , Oracle eBusiness Suite, Peoplesoft, JDEdwards and SAP (BI Apps version 7.8.4) ) and load the data into the Oracle Business Analysis Warehouse. (Note: Oracle BI Applications version 7.9.5.2 includes a repository for the Oracle Data Integrator instead of Informatica but supports only Oracle Financials).


• The Oracle Business Analysis Warehouse (OBAW), a prebuilt schema (stars that is) which serves as a turnkey data warehouse including dozens of stars and accompanying indexes, aggregates, time dimensions and slowly changing dimension handling (and yes, it can be optimized).
• A prebuilt repository for the Data Warehouse Administration Console (DAC) server which is the orchestration engine behind the ETL process. The DAC client and server were included until version 7.9.5. Since then it is a separate installer.
• A prebuilt Oracle BI Server repository (rpd file) which maps the OBAW physical tables to a generic business model and includes more than 100 presentation catalogs (aka subject areas) to allow queries and segmentation using Oracle BI clients such as Answers, Dashboards and Segment Designer. Did I mention that it also takes care of authentication and data security?
• A prebuilt presentation catalog (repository) containing hundreds of requests and ready-to-use dashboards which enable tight integration between the source applications and the BI infrastructure (example: Click the Service Analytics screen in Siebel CRM, work with the dashboard data, drill down to details and click an action button to navigate back to the Siebel CRM record).

Oracle BI EE 10g is the successor of Siebel Analytics and Oracle BI Applications is the successor of Siebel Analytics Applications.


Detailed Data flow



First, the DAC scheduler kicks off jobs to loadrefresh the OBAW at regular intervals or alternatively, these jobs could be kicked off manually from the DAC client.
The DAC server uses the object and configuration data stored in the DAC repository to issue commands to the informatica Server.
The informatica server executes the commands issued from DAC, and uses the objects and configuration data stored in the informatica repository.
Then the data are extracted, transferred and loaded from the transactional databases into the OBAW target tables.
After the ETL is complete and OBAW is online, an OBIEE end user runs a dashboard or report in the Answers or Interactive dashboard.
The request comes through the web server and interacts with the presentation server.
The presentation server interacts with OBI Server and OBI server will understand the requests and hits the OBAW if it’s not cashed and extracts the data and provides it to the presentation server.
The presentation server formats the data into the required format and through web server, the request is presented to the end user



ETL process





ETL mappings are split into two main mappings, SDE mappings and SIL mappings.
2 SDE mappings load the staging tables,then SIL mappings (SILOS, SIL_Vert, PLP) load the final physical warehouse tables
3 SILOS SIL mappings are for all sources except Siebel Verticals. SIL_Vert SIL mappings are for Siebel Verticals only
4 Staging tables are suffixed with S, so W_AP_XACTS_F is the final table and the staging table is W_AP_XACTS_FS

Monday, December 6, 2010

DB Recovery

incomplete recovery of database until CANCLE after reaching some time from hot snap backup and archives



SQL>startup mount

SQL> recover database using backup controlfile until CANCEL
ORA-00279: change 5965295809608 generated at 12/01/2010 17:54:21 needed for
thread 1
ORA-00289: suggestion :
/oraarchive/vis/abcd001k_VIS_0001_0000006134_697765707.arc
ORA-00280: change 5965295809608 for thread 1 is in sequence #6134


Specify log: {=suggested | filename | AUTO | CANCEL}
/oraarchive/vis/abcd001k_VIS_0001_0000006134_697765707.arc
ORA-00279: change 5965295965197 generated at 12/02/2010 00:00:16 needed for
thread 1
ORA-00289: suggestion :
/oraarchive/vis/abcd001k_VIS_0001_0000006135_697765707.arc
ORA-00280: change 5965295965197 for thread 1 is in sequence #6135
ORA-00278: log file
'/oraarchive/vis/abcd001k_VIS_0001_0000006134_697765707.arc' no longer
needed for this recovery


Specify log: {=suggested | filename | AUTO | CANCEL}
/oraarchive/vis/abcd001k_VIS_0001_0000006135_697765707.arc
ORA-00279: change 5965295965276 generated at 12/02/2010 00:00:36 needed for
thread 1
ORA-00289: suggestion :
/oraarchive/vis/abcd001k_VIS_0001_0000006136_697765707.arc
ORA-00280: change 5965295965276 for thread 1 is in sequence #6136
ORA-00278: log file
'/oraarchive/vis/abcd001k_VIS_0001_0000006135_697765707.arc' no longer
needed for this recovery


Specify log: {=suggested | filename | AUTO | CANCEL}
/oraarchive/vis/abcd001k_VIS_0001_0000006136_697765707.arc


ORA-00279: change 5965296032263 generated at 12/02/2010 04:00:15 needed for
thread 1
ORA-00289: suggestion :
/oraarchive/vis/abcd001k_VIS_0001_0000006137_697765707.arc
ORA-00280: change 5965296032263 for thread 1 is in sequence #6137
ORA-00278: log file
'/oraarchive/vis/abcd001k_VIS_0001_0000006136_697765707.arc' no longer
needed for this recovery


Specify log: {=suggested | filename | AUTO | CANCEL}


/oraarchive/vis/abcd001k_VIS_0001_0000006137_697765707.arc
ORA-00279: change 5965296032275 generated at 12/02/2010 04:00:19 needed for
thread 1
ORA-00289: suggestion :
/oraarchive/vis/abcd001k_VIS_0001_0000006138_697765707.arc
ORA-00280: change 5965296032275 for thread 1 is in sequence #6138
ORA-00278: log file
'/oraarchive/vis/abcd001k_VIS_0001_0000006137_697765707.arc' no longer
needed for this recovery


Specify log: {=suggested | filename | AUTO | CANCEL}

/oraarchive/vis/abcd001k_VIS_0001_0000006138_697765707.arc
ORA-00279: change 5965296081988 generated at 12/02/2010 08:00:15 needed for
thread 1
ORA-00289: suggestion :
/oraarchive/vis/abcd001k_VIS_0001_0000006139_697765707.arc
ORA-00280: change 5965296081988 for thread 1 is in sequence #6139
ORA-00278: log file
'/oraarchive/vis/abcd001k_VIS_0001_0000006138_697765707.arc' no longer
needed for this recovery


Specify log: {=suggested | filename | AUTO | CANCEL}
/oraarchive/vis/abcd001k_VIS_0001_0000006139_697765707.arc
ORA-00279: change 5965296081997 generated at 12/02/2010 08:00:19 needed for
thread 1
ORA-00289: suggestion :
/oraarchive/vis/abcd001k_VIS_0001_0000006140_697765707.arc
ORA-00280: change 5965296081997 for thread 1 is in sequence #6140
ORA-00278: log file
'/oraarchive/vis/abcd001k_VIS_0001_0000006139_697765707.arc' no longer
needed for this recovery


Specify log: {=suggested | filename | AUTO | CANCEL}
/oraarchive/vis/abcd001k_VIS_0001_0000006140_697765707.arc
ORA-00279: change 5965296141979 generated at 12/02/2010 12:00:15 needed for
thread 1
ORA-00289: suggestion :
/oraarchive/vis/abcd001k_VIS_0001_0000006141_697765707.arc
ORA-00280: change 5965296141979 for thread 1 is in sequence #6141
ORA-00278: log file
'/oraarchive/vis/abcd001k_VIS_0001_0000006140_697765707.arc' no longer
needed for this recovery


Specify log: {=suggested | filename | AUTO | CANCEL}
CANCEL
ORA-01547: warning: RECOVER succeeded but OPEN RESETLOGS would get error below
ORA-01194: file 1 needs more recovery to be consistent
ORA-01110: data file 1: '/d03/oraVIS/vis/db/apps_st/data/system01.dbf'


To open the database with foruce, do below:

1) Set _ALLOW_RESETLOGS_CORRUPTION=TRUE in init.ora file.
2) Startup Mount
3) Alter database open resetlogs.
4) reset undo_management to “manual” in init.ora file.
5) startup database
6) Create new undo tablespace
changed undo_management to “AUTO” and undo_tablespace to “NewTablespace”
7) Bounce database.

Friday, September 17, 2010

ASM

Adding datafile

ALTER TABLESPACE TDW_PROD ADD DATAFILE '+DATA_DISKGRP/bivis/datafile/bivis_28.dbf' SIZE 1024M AUTOEXTEND ON NEXT
1024M MAXSIZE UNLIMITED

queries
select NAME,TOTAL_MB,FREE_MB,FREE_MB/TOTAL_MB*100 from v$ASM_DISK;

select NAME,TOTAL_MB,FREE_MB,FREE_MB/TOTAL_MB*100 from v$ASM_DISKGROUP;

select NAME,TOTAL_MB,FREE_MB,TOTAL_MB-FREE_MB,FREE_MB/TOTAL_MB*100 from v$ASM_DISK

select NAME, REDUNDANCY, FAILGROUP from V$ASM_DISK ;

select operation from v$ASM_OPERATION;

select name,path,MOUNT_STATUS,HEADER_STATUS,MODE_STATUS,STATE,total_mb,free_mb from v$asm_disk

dropping/adding/cheking diskALTER DISKGROUP CHECK ALL;
ALTER DISKGROUP DROP DISK ; This command drops the disk and also initiates a REBAL operation
We can monitor the status of REBAL operation from v$asm_operation
Run select * from v$asm_disk and get different statuses of hdisk8.
eg:
ALTER DISKGROUP DATA_DISKGRP DROP DISK DATA_DISKGRP_0004;

DATA_DISKGRP_004 is alias for /dev/rhdisk8.

SQL> select OPERATION from v$asm_operation;

OPERA
-----
REBAL


ALTER DISKGROUP DATA_DISKGRP ADD DISK ‘mention the disk path’ NAME DATA_DISKGRP_004 REBALANCE POWER 5;


This query will give more details about disk usage.
SET LINESIZE 145
SET PAGESIZE 9999
SET VERIFY off
COLUMN disk_group_name FORMAT a15 HEAD 'Disk Group Name'
COLUMN disk_file_path FORMAT a17 HEAD 'Path'
COLUMN disk_file_name FORMAT a20 HEAD 'File Name'
COLUMN disk_file_fail_group FORMAT a20 HEAD 'Fail Group'
COLUMN total_mb FORMAT 999,999,999 HEAD 'File Size (MB)'
COLUMN used_mb FORMAT 999,999,999 HEAD 'Used Size (MB)'
COLUMN pct_used FORMAT 999.99 HEAD 'Pct. Used'
break on report on disk_group_name skip 1
compute sum label """" of total_mb used_mb on disk_group_name
compute sum label ""Grand Total: "" of total_mb used_mb on report
SELECT
NVL(a.name, '[CANDIDATE]') disk_group_name
, b.path disk_file_path
, b.name disk_file_name
, b.failgroup disk_file_fail_group
, b.total_mb total_mb
, (b.total_mb - b.free_mb) used_mb
, ROUND((1- (b.free_mb / b.total_mb))*100, 2) pct_used
FROM
v$asm_diskgroup a RIGHT OUTER JOIN v$asm_disk b USING (group_number)
ORDER BY
a.name
/

Issues -- Forms

Fixing issues of Custom Forms in Forms Servlet using Doc id 269634.1
You need to put your CUSTOM TOP variable (where the form resides) path information into Apache/Jserv/etc/formservlet.ini file
So open formservlet.ini and add this entry at the end
# Begin customizations
XXTAC_TOP=/d01/app/applmgr/prodappl/xxtac/11.5.0
# End customizations

Wednesday, September 15, 2010

UNIX

ls commnadb

Copy the specific things to ur file
ls -l > s1.sh
cat s1.sh |awk '{print $9}' > s2.sh


ls *.dbf|wc -l --- number of files in the PWD
t
ls -l /data/ora007/od08oadb01/*dbf|awk '{print $9}' > 007.txt
$9 is column number
column 9 is redirected to new file 007.txt

# echo "$userid"
system/xxxxx
# echo "$userid"|awk 'BEGIN { FS = "/" } {print $2}'
xxxxx

date=`date +%F`
# date +%F
2010-09-19
# date
Sun Sep 19 22:49:21 EDT 2010

ls -l *dbf|awk 'BEGIN {total=0} {total+=$5} END {print total/1024/1024/1024}'
$5 is the column number
column five size column in GB will be printed

ls -l [a-g]*dbf|awk 'BEGIN {total=0} {total+=$5} END {print total/1024/1024/1024}'
gives the total size of the DBF's starting from a to g

To find out the size of the datafiles
from [a-h]*dbf

du -sk [a-h]*dbf |awk 'BEGIN {total=0} {total+=$1} END {print total/1024/1024}'
du -sk [i]*dbf |awk 'BEGIN {total=0} {total+=$1} END {print total/1024/1024}'
du -sk [j-z]*dbf |awk 'BEGIN {total=0} {total+=$1} END {print total/1024/1024}'


ls -l | grep 'Jan 9' | awk '{print$9}' >one.sh -------in this Jan 9 is the day for which we are compressing and one.sh is the file name. Next open one.sh and do
:%s,^,compress ,g
OR
: %s,^,rm -rf ,g
save the file and run it also do a chmod 777 one.sh


To remove one month files at a time
ls -l|grep 'Aug '|awk '{print$9}' > one.sh
chmod 777 one.sh
vi one.sh
: %s,^,rm -f ,g
./one.sh

ls -l |grep 'Feb' |awk '{print$9}' > one.sh

ls -l |grep 'Feb' |grep *.req |awk '{print$9}' > one.sh


sdiff
sdiff -s -w 50 tb.txt sb.txt
50 is word length

diff $IAS_ORACLE_HOME/Apache/Apache/conf/httpd.conf $HOME/httpd.conf.orig > /tmp/httpddiff.txt
SIZEDIFF=`ls -lA /tmp/httpddiff.txt | awk -F' ' '{print $5}'`
if [ $SIZEDIFF -gt 0 ]
then
mailx -s "VIS irecruitment setup is missing in PROD" emaladdress < /tmp/httpddiff.txt
mailx -s "vis irecruitment setup is missing in PROD"" onemoreemailaddress < $HOME/irecmessage.txt
fi

eg of mailx command:
cat /tmp/mailbody | mail -s "Ignore Alerts: ABC PREPROD Apachebounce on hostname" abcd@abc.ice.com -- -r alertfromserver@abc.ice.com < a


to check any errors present in the file
cat /oracle/qa/qaappl/admin/QA/log/u2819091.log |grep -i ORA-

VNC SERVER
vncserver -geometry 1024x1024 -depth 8 -cc 3
vncserver :49 -nolisten local -httpd ${VNC}/classes -cc 3
vncserver :99 -geometry 1024x1024

You can kill sessions you started.
$ vncserver -kill :[display number]

$ vncserver -kill :0
Wait for 5 mins and delete the file as follows:
$ rm /tmp/X11-unix/X0
login as appl user for the instance refreshed and start the vnc services as follows:
$ vncserver :0 -localhost
$ xhost +

To set your password the first time (or reset it later) run this command:
$ /usr/bin/vncpasswd



strings
strings -a hrrunprc.sql | grep Header


To create a directory, change ownership, create symbolic link
mkdir -p /u20/app/KEYCS1/apkeycs1/applmgr/11510
mkdir -p /u20/app/KEYCS1/apkeycs1/applmgr/common
mkdir -p /u20/app/KEYCS1/apkeycs1/applmgr/CUSTOM
mkdir -p /u20/app/KEYCS1/apkeycs1/applmgr/product/806
mkdir -p /u20/app/KEYCS1/apkeycs1/applmgr/product/iAS
mkdir -p /u20/app/KEYCS1/orkeycs1/oracle/product
mkdir -p /u22/oradata/KEYCS1/oradata/data01
mkdir -p /u22/oradata/KEYCS1/oradata/data02
mkdir -p /u22/oradata/KEYCS1/oradata/data03

ln -s /u20/app/KEYCS1/apkeycss1/applmgr applmgr
ln -s /u20/app/KEYCSS1/orkeycss1/oracle oracle
ln -s /u22/oradata/KEYCSS1/oradata oradata

chown apkeycs1:oaa applmgr
chown orkeycs1:dba oracle
chown orkeycs1:dba oradata


Changing group for user
# usermod -g dba ora10g
Check the group created in “/etc/group”
# cat /etc/group |grep dba
dba::110:


useradd -c ""App user KEYCS1"" -d /u20/app/KEYCS1/apkeycs1 -g oaa apkeycs1
useradd -c ""Ora user KEYCS1"" -d /u20/app/KEYCS1/orkeycs1 -g dba orkeycs1

chown -R apkeycs1:oaa /u20/app/KEYCS1/apkeycs1
chown -R orkeycs1:dba /u20/app/KEYCS1/orkeycs1
chown -R orkeycs1:dba /u22/oradata/KEYCS1


Commands useful to clear space issues in mount points

bdf|awk '{print $5,$6}' > one.txt

find . -type f -mtime +5
find . -type f -mtime +5 -exec rm -f()
find . -type f -mtime +5|xargs rm -f
find . -name *.req -mtime +7 -exec compress -f {} \;
find . -name *.req -mtime +30 -exec rm -f {} \;
find . -name *.req -mtime +7 -exec gzip {} \;
find . -name "*" -mtime +20 -exec rm {} \;
find . -name "*" -mtime +30 -exec ls -la {} \;|awk '{print $5}'>a.sh
find . -size +500000000 -exec ls -al {} \;
find . -name "*" -mtime +20 -exec rm {} \;
find . -size +52428800 -exec ls -al {} \;
find . -size +100000000c -exec ls -l {} \;
$du -sh
$du -sk
find /eadvi4/applmgr/common/admin/log/EADVI4_hostname \( -name '*.*' \) -mtime +120 -exec rm -rf {} \;

delete files /u03/applmgr/prod/TEMPS and /u03/applmgr/qlty/TEMPS older than 15 days.
find /u03/applmgr/prod/TEMPS/ -mtime +15 -exec rm -f {} \;
find /u03/applmgr/qlty/TEMPS/ -mtime +15 -exec rm -f {} \;

find . -name "*.dbg" -mtime +1 -exec rm -f {} \;

Script to delete the dump files 21 days old need to be in cron
30 20 * * * find /ORACLE/eul10g/backup \( -name '*.dmp*' \) -mtime +21 -exec rm -f {} \; ---- As oracle user cron.

To find Symbolink links and replace to corrent ones
more rename_softlinks.sh
#!/bin/ksh
cd $ORACLE_HOME
find . -type l -exec ls -l {} \; | grep prod | awk '{gsub("prod","qa",$11); print "rm "$9; print "ln -s " $11 " " $9}'

To find links under any top
find . -type l -print | xargs ls -ld

Recreate soft links in $CUSTOM_TOP/bin
unlink visSQL
ln -s ../../../fnd/11.5.0/bin/fndcpesr visSQL


How to find the symbolic links that point to the old path in your oracle_home and appl_top.
This command is useful in cloning after restore from source to target that symbolic link are not pointing to source.

ls -al `find . -type l` | grep $OLD_PATH

To find all the text files that contains the old path at the UNIX level.

find . -type f -print|grep -v ":"|xargs file|grep "text"|awk '{FS=":"}{print $1}'|xargs grep -il $OLD_PATH

How to Sort files based on Size of file in a Directory
Useful in finding out spaces issues
ls -l | sort -nrk 5 | more

How to find a "word" or pattern in all files in a directory & subdirectories
find . -name "*" -exec grep -l {} \; -print
for example I want to search for word oracle
find . -name "*" -exec grep -l oracle {} \; -print


How to delete files older than N number of days , Useful to delete old log files
find . -name '*.*' -mtime + -exec rm {} \;
for example if I want to delete all files older than 7 days
find . -name '*.*' -mtime +7 -exec rm {} \;



To edit window registry
regedit (on run prompt)


To view a Linux desktop remotely
1. SSH to Linux server
2. Start the VNC server by typing 'vncserver' at the command line. Remember the display number.
3. Connect to the VNC server using a VNC viewer. Enter host name, display number, and VNC password for the user who started the session.
4. When finished, don't log out of Linux, just close the VNC viewer window.
5. If you wish, kill the VNC server session when finished. Or keep it running and use it next time you need to connect.



To use VNC to control or view a computer behind a firewall
The official VNC FAQ has a good explanation of using VNC through a firewall
at http://www.realvnc.com/faq.html#firewall. You must either open port 5900+N where N equals the VNC port assigned when you created a connection, or you must use SSH tunneling to channel the VNC traffic through ports that normally allow traffic through a firewall.
More detailed information is available at the link above.


ps command
ps -fu apdev


sort, delete rows, columns
ls -lrt |sort -nr -k5 |head -15
ls -lart |head -200
ls -lrt > a.sh
vi a.sh
esc :3000,$d -- to delete all line after 3000 use ^d for before 3000 deletion
$cut -c 55-95 a.sh > b.sh
vi b.sh
esc :%s,compress,^,g
save
sh b.sh

To know port is free or not
netstat -na
lsof |grep


To know n/w IP
netstat -iv

tar commands
Simple tar commands
tar -cvf directory.tar direcotry
tar -xvf director.tar


tar cvfzp TEST_apps_inst_myserver.tar.gz apps inst
tar cvfzp TEST_dbhome_myserver.tar.gz db/tech_st
Extract each of the tar files with the command tar xvfzp
tar xvfzp TEST_apps_inst_myserver.tar.gz

nohup tar -zxvf ------.gzip or .gz &

tar cf - . | ssh 192.168.100.107 "cd /path/target_directory; tar xf - "

ssh servernmae "cd /ORACLE/prod/9.2.0;tar cf - ." | tar xf -

Remote tar and untaa eg:
ssh usaxsxx "cd /ORACLE/prod/9.2.0;tar cf - ." | tar xf -
ssh usaxsxx "cd /ORACLE/prod/8.0.6; tar cf - ." | tar xf -
ssh usaxsxx "cd /ORACLE/prod/9iAS; tar cf - ." | tar xf -
ssh usaxsxx "cd /ORACLE/apps/prod; tar cf - [a-b]*" | tar xf -
ssh usaxsxx "cd /ORACLE/apps/prod; tar cf - [d-s]*" | tar xf -
ssh usaxsxx "cd /ORACLE/apps/prod; tar cf - [u-z]*" | tar xf -
ssh usaxsxx "cd /ORACLE/apps/prod; tar cf - c[a-n]*" | tar xf -
ssh usaxsxx "cd /ORACLE/apps/prod; tar cf - c[p-z]*" | tar xf -
ssh usaxsxx "cd /ORACLE/apps/prod/common; tar cf - [a-j]*" | tar xf -
ssh usaxsxx "cd /ORACLE/apps/prod/common; tar cf - [p-z]*" | tar xf -
ssh usaxsxx "cd /ORACLE/apps/prod/common; tar cf - outbound" | tar xf -

tar cf - [a-b]* | ssh remotehost "cd /ORACLE/apps/narvis; tar xf - "
tar cf - [d-s]* | ssh remotehost "cd /ORACLE/apps/narvis; tar xf - "
tar cf - [u-z]* | ssh remotehost "cd /ORACLE/apps/narvis; tar xf - "
tar cf - c[a-n]* | ssh remotehost "cd /ORACLE/apps/narvis; tar xf - "
tar cf - c[p-z]* | ssh remotehost "cd /ORACLE/apps/narvis; tar xf - "
tar cf - [a-j]* | ssh remotehost "cd /ORACLE/apps/narvis/common; tar xf - "
tar cf - [p-z]* | ssh remotehost "cd /ORACLE/apps/narvis/common; tar xf - "

tar cf - . | ssh remotehost "cd /ORACLE/narvis/8.0.6.3; tar xf - "
tar cf - . | ssh remotehost "cd /ORACLE/narvis/9iAS; tar xf - "

tar cf - . | ssh remotehost "cd /ORACLE/narvis_conf/8.0.6.3; tar xf - "
tar cf - . | ssh remotehost "cd /ORACLE/narvis_conf/9iAS; tar xf - "



Tar split
nohup tar cvf - OraHome_1 2> /11iGold/backup/OraHome_1.log | gzip | split -b 2000m - /11iGold/backup/OraHome_1.tar.gz &
This can be restored using the follwing command if required:
nohup cat /11iGold/backup/OraHome_1.tar.gz?? | gunzip | tar xf - &


untar/tar syntax in a single set of options

nohup cat /backups/code_tree_backups/100906/920.gz | gunzip | tar xvf - > 920.log &
nohup cat /backups/code_tree_backups/100906/1159.gz | gunzip | tar xvf - > ApplTop.log &
nohup cat /backups/code_tree_backups/100906/806.gz | gunzip | tar xvf - > 806.log &
nohup cat /backups/code_tree_backups/100906/common.gz | gunzip | tar xvf - > common.log &
nohup cat /backups/code_tree_backups/100906/custom.gz | gunzip | tar xvf - > custom.log &
nohup cat /backups/code_tree_backups/100906/ias.gz | gunzip | tar xvf - > ias.log &

nohup tar -cvpf - /u01/oradata/ 2> /scratch/u01.log | gzip -c > /scratch/u01.gz &
nohup tar -cvpf - /u13/oradata/ 2>/scratch/u13.log|gzip -c>/scratch/u13.gz &

nohup tar -cvpf - PROD_LVL0_20070103_9ii6jsga_s16690_p11 PROD_LVL0_20070103_9ki6jsgb_s16692_p11 PROD_LVL0_20070103_9ni6jtlj_s16695_p11 PROD_LVL0_20070103_9ri6k05o_s16699_p11 PROD_LVL0_20070103_9si6k0ig_s16700_p11 PROD_LVL0_20070103_9ti6k0ku_s16701_p11 PROD_LVL0_20070103_9mi6jtl9_s16694_p11 c-620808606-20070104-00 snapcf_PROD.f 2>/backup/backup1.log|gzip - c >/backup/backup1.gzip &


nohup tar -zcvpf $BACKUP_DIR/u01.tar /u01/PROD/oradata/ >$BACKUP_DIR/u01.log 2>&1 &
nohup tar -zxvpf $BACKUP_DIR/u10.tar &

rcp command
rcp -pr applmgr@remoteserver1:/u03/oracle/tst/tstcomn/* . &
rcp -pr applmgr@remoteserver1:/u03/oracle/tst/tstora/8.0.6 . &
rcp -pr applmgr@remoteserver1:/u03/oracle/tst/tstora/iAS . &

To zip files several files at a time
zip -r /tmp/`uname -n`_`date +%m%d%y.%H%M`_iAS.zip \
$IAS_ORACLE_HOME/Apache/Apache/conf/* \
$IAS_ORACLE_HOME/Apache/Apache/logs/* \
$IAS_ORACLE_HOME/Apache/Jserv/etc/* \
$IAS_ORACLE_HOME/Apache/Jserv/logs/*


R12 config files backup commands
as oratst user :
REFRESH=/clone/TST/REFRESH_FILES_DB.`date +%m%d%y`
rm -rf $REFRESH
mkdir -p $REFRESH
cp -p $ORACLE_HOME/*.env $REFRESH
cp -p $ORACLE_HOME/dbs/*.ora $REFRESH
cp -p $ORACLE_HOME/appsutil/*.xml $REFRESH
cp -p $TNS_ADMIN/*.ora $REFRESH
chmod 700 $REFRESH

=> as appltst user:
REFRESH=/clone/TST/REFRESH_FILES_APPS.`date +%m%d%y`
#rm -rf $REFRESH
mkdir -p $REFRESH/inst/apps
rsync -avH /d21/appltst/inst/apps/* $REFRESH/inst/apps/
chmod 700 $REFRESH

R12 config files backup commands
# more /vis2/clone/vis2.backup
echo su - applvis2
sleep 1
echo
echo backing up applications related config files .....................
sleep 2
echo
su - applvis2 -c /vis2/clone/vis2bkgenfiles/applvis2.bkp
sleep 1
echo su - oravis2
echo
sleep 2
echo backing up db related config files .....................
su - oravis2 -c /vis2/clone/vis2bkgenfiles/oravis2.bkp
sleep 1
echo
echo vis2 instance config files backup is complete and is located in /vis2/clone directory .
echo
# more /vis2/clone/vis2bkgenfiles/applvis2.bkp
REFRESH=/vis2/clone/REFRESH_FILES_APPS.`date +%m%d%y`
mkdir -p $REFRESH/inst/apps
rsync -avH /d11/applvis2/inst/apps/* $REFRESH/inst/apps/ --exclude "vis2_hostname1/logs/" --exclude "vis2_hostname2
/logs/" --exclude "vis2_hostname3/appltmp/" --exclude "vis2_hostname4/appltmp/"
chmod 700 $REFRESH

# more /vis2/clone/vis2bkgenfiles/oravis2.bkp
REFRESH=/vis2/clone/REFRESH_FILES_DB.`date +%m%d%y`
rm -rf $REFRESH
mkdir -p $REFRESH
cp -p $ORACLE_HOME/*.env $REFRESH
cp -p $ORACLE_HOME/dbs/*.ora $REFRESH
cp -p $ORACLE_HOME/appsutil/*.xml $REFRESH
cp -p $TNS_ADMIN/*.ora $REFRESH
chmod 700 $REFRESH
exp " '/ as sysdba' " file=$REFRESH/msdem_vis2_hostname.dmp log=$REFRESH/msdem_vis2_hostname.log direct=y feedbac
k=1000 owner=MSDEM



rsync
if refired it will pickup from where it failed
“rsync –exclude=ABc/ --log-file= -avH


RSYNC failed and restarted it. Please monitor the rsync and restart in case of failure.
Location: /d33/oravis/visdata
To Monitor: tail –f nohup.out (and) ps -ef | grep rsync
Command used to rsync:
nohup rsync -avH /snap/oravis/visdata/ /d33/oravis/visdata/ &


Some more rsync commands
nohup rsync -a -v -H /snaps/d01/applmgr/ /d01/appltst/ > /d01/appltst/rsync.log &
nohup rsync -a –v -H /cosxaor0o_d02oracle/ /d02/oratst/ > /d02/oratst/rsync.log &
nohup rsync -a -v -H /snaps/d03/oracle/ /d03/oratst/ > /d03/oratst/rsync.log &


One more rsync example
rsync -avH /d01/applcrp2/inst/apps/* $REFRESH/inst/apps/ --exclude "CRP2_vcosxaor33/logs/" --exclude "CRP2_vcosxawo14/logs/" --exclude "CRP2_vcosxaor33/appltmp/"
--exclude "CRP2_vcosxawo14/appltmp/"

some more rsync eg:
rsync commands and they can be submitted as background jobs using the nohup command.

Applications tier files:

cd /d01/oradev
nohup rsync --update --verbose --progress --stats --compress --recursive --times --owner --group --hard-links --perms --links /d01_snap_922385/oraprod/prodappl /d01/oradev/ > d01_devaappl_rsync.log &

nohup rsync --update --verbose --progress --stats --compress --recursive --times --owner --group --hard-links --perms --links /d01_snap_922385/oraprod/prodcomn /d01/oradev/ > d01_devacomn_rsync.log &

nohup rsync --update --verbose --progress --stats --compress --recursive --times --owner --group --hard-links --perms --links /d01_snap_922385/oraprod/prodora /d01/oradev/ > d01_devaora_rsync.log &

Database tier files:

cd /d03/oradev
nohup rsync --update --verbose --progress --stats --compress --recursive --times --owner --group --hard-links --perms --links /d03_snap/oraprod/proddata /d03/oradev/ > d03_devadata_rsync.log &

cd /d02/oradev
nohup rsync --update --verbose --progress --stats --compress --recursive --times --owner --group --hard-links --perms --links /d02_snap/oraprod/prodracdb /d02/oradev/ > d02_devadb_rsync.log &


one more rsync eg:

nohup rsync --log-file=d03_oradata_a.log -avH /NEW/d03/oracle/proddata/[a-d]* /d03/oracle/proddata &

nohup rsync --log-file=d03_oradata_e.log -avH /NEW/d03/oracle/proddata/[e-g]* /d03/oracle/proddata &

nohup rsync --log-file=d03_oradata_h.log -avH /NEW/d03/oracle/proddata/[h-k]* /d03/oracle/proddata &

nohup rsync --log-file=d03_oradata_l.log -avH /NEW/d03/oracle/proddata/[l-o]* /d03/oracle/proddata &

nohup rsync --log-file=d03_oradata_p.log -avH /NEW/d03/oracle/proddata/[p-s]* /d03/oracle/proddata &

nohup rsync --log-file=d03_oradata_t.log -avH /NEW/d03/oracle/proddata/[t-w]* /d03/oracle/proddata &

nohup rsync --log-file=d03_oradata_x.log -avH /NEW/d03/oracle/proddata/[x-z]* /d03/oracle/proddata &


nohup rsync --log-file=d02_oracle.log -avH /NEW/d02/oracle/* /d02/oracle &

nohup rsync --log-file=d01_prodappl.log -avH /NEW/d01/oracle/prodappl/* /d01/oracle/prodappl &

nohup rsync --log-file=d01_prodcomn.log /NEW/d01/oracle/prodcomn/* /d01/oracle/prodcomn/ &

nohup rsync --log-file=d01_prodora.log -avH /NEW/d01/oracle/prodora/* /d01/oracle/prodora &


nohup rsync --log-file=d01_final_log -avH /NEW/d01/* /d01/ &
nohup rsync --log-file=d02_final_log -avH /NEW/d02/* /d02/ &
nohup rsync --log-file=d03_final_log -avH /NEW/d03/* /d03/ &


Config files backup commands for apps[applvis@hostname]$ more /home/appltest/clone/config_backup_apps.sh
REFRESH=/home/appltest/REFRESH_FILES.`date +%m%d%y`
mkdir -p $REFRESH/appltop/admin $REFRESH/oraclehome $REFRESH/iasoraclehome $REFRESH/fndtop/resource $REFRESH/fndtop/secure $REFRESH/oahtml/bin/cfg $REFRESH/iasoraclehome/Apache/
modplsql $REFRESH/iasoraclehome/Apache/Apache $REFRESH/iasoraclehome/Apache/Jserv $REFRESH/comntop/admin/scripts $REFRESH/adtop/admin/template $REFRESH/config_top $REFRESH/iasco
nfighome/Apache
cp -rp $APPL_TOP/*.env $REFRESH/appltop
cp -rp $APPL_TOP/admin/*.env $REFRESH/appltop/admin
cp -rp $APPL_TOP/admin/*.txt $REFRESH/appltop/admin
cp -rp $APPL_TOP/admin/*.xml $REFRESH/appltop/admin
cp -rp $APPL_TOP/admin/*.sql $REFRESH/appltop/admin
cp -rp $APPL_TOP/admin/*.pls $REFRESH/appltop/admin
cp -rp $APPL_TOP/admin/*.drv $REFRESH/appltop/admin
cp -rp $ORACLE_HOME/*env $REFRESH/oraclehome
cp -rp $IAS_ORACLE_HOME/*env $REFRESH/iasoraclehome
cp -rp $IAS_CONFIG_HOME/*env $REFRESH/config_top
cp -rp $FND_TOP/resource/* $REFRESH/fndtop/resource
cp -rp $FND_TOP/secure/* $REFRESH/fndtop/secure
cp -rp $OA_HTML/bin/*cfg $REFRESH/oahtml/bin/cfg
cp -rp $IAS_ORACLE_HOME/Apache/modplsql/cfg $REFRESH/iasoraclehome/Apache/modplsql
cp -rp $IAS_ORACLE_HOME/Apache/Apache/conf $REFRESH/iasoraclehome/Apache/Apache
cp -rp $IAS_ORACLE_HOME/Apache/Jserv/etc $REFRESH/iasoraclehome/Apache/Jserv
cp -rp $APPLCSF/scripts/* $REFRESH/comntop/admin/scripts
cp -rp $AD_TOP/admin/template $REFRESH/adtop/admin/template
cp -rp $IAS_CONFIG_HOME/Apache/modplsql/cfg $REFRESH/iasconfighome/Apache/modplsql
cp -rp $IAS_CONFIG_HOME/Apache/Apache/conf $REFRESH/iasconfighome/Apache/Apache
cp -rp $IAS_CONFIG_HOME/Apache/Jserv/etc $REFRESH/iasconfighome/Apache/Jserv


-----------------------
Config file backup commands from DB side
[oravis@hostname]$ more db_bkp.sh
REFRESH=$HOME/REFRESH_FILES_DB.`date +%m%d%y`
mkdir -p $REFRESH/ORACLE_HOME/appsutil $REFRESH/TNS_ADMIN
cp -rp $ORACLE_HOME/dbs $REFRESH/ORACLE_HOME
cp -rp $ORACLE_HOME/*env $REFRESH/ORACLE_HOME
cp -rp $ORACLE_HOME/appsutil/*.xml $REFRESH/ORACLE_HOME/appsutil
cp -rp $TNS_ADMIN $REFRESH/TNS_ADMIN

To run alert commands repeatedly
while true
do
date
sqlplus "/as sysdba" @temp_alert1.sql
sleep 10
clear
done

To know number of CPU's on AIX m/c
lsdev -Cc processor

titles of each xterm window
If we add this to $HOME/.kshrc (assuming KSH is the shell being used), the information that is constant throughout the lifetime of the shell.
echo ""\033]0;${USER}@${HOST}\007""
The answer is available freely on the internet: http://www.faqs.org/docs/Linux-mini/Xterm-Title.html

How to run sibclean
As any of these users rlakshmi
$ /usr/local/bin/sudo /usr/sbin/slibclean
This will clean up any unused modules in kernel and library memory which may cause installation or runtime problems


Setup the SSH Key between machine1 and machine2

Scp machine1:/home/applmgr/.ssh/id_dsa.pub to machine2:/home/applmgr/.ssh/authorized_keys2

Verify that the ssh key is working from usellx08 to the config/middle tiers of the cloned instance

machine1> ssh machine2

machine2>exit

Connection to machine2 closed

machine1>

We can also generate the dsa key if not working as :
ssh-kegen -t dsa


Control file creation script
cat create_controlfile_script_for_newdb.sh
#!/bin/ksh

newdbname=$1
[ -z "$newdbname" ] && echo "Usage: {script_name}.sh " && exit 1

cd $DATA_DIR/admin/udump
latest_tracefile=`ls -lt *.trc | head -5 | awk '{print $9}' | xargs grep -l "CREATE CONTROLFILE" | head -1`

awk '/# Set #2. RESETLOGS case/ {
while ($0 !~ /^;$/) {
getline;
if ($0 ~ /^#/) continue;
sub("CONTROLFILE REUSE","CONTROLFILE SET");
sub("PROD",s_dbname);
sub("/prod/","/"s_dbname"/");
sub("/prod","/redo");
print
}
}' s_dbname=$newdbname $latest_tracefile > create_controlfile_${newdbname}.sql


To check if package/rpm is installed
rpm –qa grep {rpm_name} (From root)
eg: rpm -q binutils
To install package/rpm
rpm –ivh {rpm_name} (From root)

If you execute rpm with the -qa options (q for query mode, a for all installed packages) you will see the following if it is installed:

[oravis@myserver~]$ rpm -qa | grep libstdc++-devellibstdc++-devel-3.4.6-10
If your on a 64bit OS how do you know if this is the 32bit or 64bit version.
You need specify a query format in the rpm command. following example extract the name, version, release and architecture information for the libstdc++-devel package.

[oravis@myserver ~]$ rpm -qa --qf "%{NAME}-%{VERSION}-%{RELEASE}_%{ARCH}.rpm \ %{INSTALLTIME:date}\n" | grep libstdc++libstdc++-devel-3.4.6-10_x86_64.rpm
Mon 06 Oct 2008 07:46:50 PM EDTlibstdc++-devel-3.4.6-10_i386.rpm Mon 06 Oct 2008 07:46:50 PM EDT


To check the amount of RAM and swap space available, run this:

grep MemTotal /proc/meminfo
grep SwapTotal /proc/meminfo

Ex:
# grep MemTotal /proc/meminfo
MemTotal: 1034680 kB
# grep SwapTotal /proc/meminfo
SwapTotal: 1534196 kB

The minimum RAM required is 1024MB, and the minimum required swap space is 1GB. Swap space should be twice the amount of RAM for systems with 2GB of RAM or less and between one and two times the amount of RAM for systems with more than 2GB.

You also need 2.5GB of available disk space for the Oracle Database 10g Release 2 software and another 1.2GB for the database. The /tmp directory needs at least 400MB of free space. To check the available disk space on your system, run the following command:

df -h
Ex:
# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/sda3 6.8G 1.3G 5.2G 20% /
/dev/sda1 99M 17M 77M 18% /boot

Kernel Parameter
Make sure you add following entry in /etc/sysctl.conf

kernel.core_users_pid = 1
kernel.sem = 250 32000 100 128
kernel.shmmax = 65536
fs.file-max = 65536
net.ipv4.ip_local_port_range = 1024 65000
net.core.rrem_default = 262144
net.core.rmem_max = 262144
net.core.wmem_default = 262144
net.core.wmem_mzx = 262144

After adding these entries execute below command to take these parameters in to effect

sysctl –p /etc/sysctl.conf # sysctl -p
net.ipv4.ip_forward = 0
net.ipv4.conf.default.rp_filter = 1
net.ipv4.conf.default.accept_source_route = 0
kernel.sysrq = 0
kernel.core_uses_pid = 1
kernel.panic = 10
vm.dirty_background_ratio = 1
vm.dirty_ratio = 5
vm.lower_zone_protection = 100
vm.oom-kill = 0
kernel.shmmax = 34359738368
kernel.shmall = 8388608
kernel.sem = 2000 500000 100 250
kernel.shmmni = 4096
kernel.msgmnb = 65535
kernel.msgmni = 2878
kernel.msgmax = 8192
fs.file-max = 131072
net.ipv4.ip_local_port_range = 20000 65000
net.core.rmem_default = 262144
net.core.rmem_max = 262144
net.core.wmem_default = 262144
net.core.wmem_max = 262144
vm.nr_hugepages = 16384



$/sbin/sysctl -a | grep sem
kernel.sem = 250 32000 100 128



Create the Oracle Groups and User Account
Next, create the Linux groups and user account that will be used to install and maintain the Oracle Database 10g Release 2 software. The user account will be called oracle, and the groups will be oinstall and dba. Execute the following commands as root:

Ex:
# /usr/sbin/groupadd oinstall
# /usr/sbin/groupadd dba
# /usr/sbin/useradd -m -g oinstall -G dba oracle
# id
oracleuid=501(oracle) gid=502(oinstall) groups=502(oinstall),503(dba)

Set the password on the oracle account:

passwd oracle
Ex:
# passwd oracle
Changing password for user oracle.
New password:
Retype new password:
all authentication tokens updated successfully.

# groupadd dba
# useradd –d "/home/oracle" –m –g dba oracle
# passwd oracle

useradd
The general syntax for the useradd command is :

useradd -d home_directory -e expire_date -g initial_group -p password login_name

home_directory : Is the main directory within which the user is expected to store all his files and subdirectories.
For a user named ‘neha’ the home directory generally is /home/neha
expire_date : This is the date on which the user’s account expires and he/she cannot access the computer anymore unless the account is renewed.
initial_group : Every user in Linux belongs to a group which affects his file permissions. The initial group must be a group which already exists.
Password : This will be the user’s password to access his account
login_name : This will be the user name with which the user will access his account.

Eg :

useradd -d /home/neha -e 2009-12-03 -g root -p talent123 neha

creates a user named neha on my computer.

Home directory for user Neha is /home/neha
Expirty date is 3rd december,2009
Belongs to the ‘root’ group
Password is talent123

Incase you do not enter one of the parameters group, home, expire or shell they are replaced by their default values. These default values can be viewed using the “ useradd -D” command and can also be changed.


Configuring Kernel Parameters

Check and edit the /etc/sysctl.conf file with the following lines.

kernel.shmall = 2097152
kernel.shmmax = 2147483648
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
fs.file-max = 65536
net.ipv4.ip_local_port_range = 1024 65000
net.core.rmem_default = 1048576
net.core.rmem_max = 1048576
net.core.wmem_default = 262144
net.core.wmem_max = 262144

Note: Make sure to reboot the system or run the command /sbin/sysctl –p to change the kernel parameters.

Add the following lines to the /etc/security/limits.conf file:

oracle soft nproc 2047
oracle hard nproc 16384
oracle soft nofile 1024
oracle hard nofile 65536


Add or edit the following line in the /etc/pam.d/login file, if it does not already exist:

session required /lib/security/pam_limits.so

Make sure that SELINUX=disabled in the the /etc/selinux/config file

Edit the /etc/redhat-release file replacing the current release information (Fedora Core release 6 (Zod)) with redhat-4

Create Directories
mkdir -p /u01/app/oracle
chown -R oracle:oinstall /u01/app/oracle
chmod -R 775 /u01/app/oracle

Ex
#mkdir -p /u01/app/oracle
# chown -R oracle:oinstall /u01/app/oracle
# chmod -R 775 /u01/app/oracle

The Linux kernel is a wonderful thing. Unlike most other *NIX systems, Linux allows modification of most kernel parameters while the system is up and running. There's no need to reboot the system after making kernel parameter changes. Oracle Database 10g Release 2 requires the kernel parameter settings shown below. The values given are minimums, so if your system uses a larger value, don't change it.
kernel.shmall = 2097152
kernel.shmmax = 536870912
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
fs.file-max = 65536
net.ipv4.ip_local_port_range = 1024 65000
net.core.rmem_default=262144
net.core.wmem_default=262144
net.core.rmem_max=262144
net.core.wmem_max=262144

If you're following along and have just installed Linux, the kernel parameters will all be at their default values and you can just cut and paste the following commands while logged in as root.
cat /etc/sysctl.conf EOF
kernel.shmall = 2097152
kernel.shmmax = 536870912
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
fs.file-max = 65536
net.ipv4.ip_local_port_range = 1024 65000
net.core.rmem_default=262144
net.core.wmem_default=262144
net.core.rmem_max=262144
net.core.wmem_max=262144
EOF
/sbin/sysctl -p

Ex:
# cat /etc/sysctl.conf EOF
kernel.shmall = 2097152
kernel.shmmax = 536870912
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
fs.file-max = 65536
net.ipv4.ip_local_port_range = 1024 65000
EOF
# /sbin/sysctl -p
net.ipv4.ip_forward = 0
net.ipv4.conf.default.rp_filter = 1
net.ipv4.conf.default.accept_source_route = 0
kernel.sysrq = 0
kernel.core_uses_pid = 1
kernel.shmall = 2097152
kernel.shmmax = 536870912
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
fs.file-max = 65536
net.ipv4.ip_local_port_range = 1024 65000
net.core.rmem_default = 262144
net.core.wmem_default = 262144
net.core.rmem_max = 262144
net.core.wmem_max = 262144

Run the following commands as root to verify your settings:
/sbin/sysctl -a | grep shm
/sbin/sysctl -a | grep sem
/sbin/sysctl -a | grep file-max
/sbin/sysctl -a | grep ip_local_port_range
/sbin/sysctl -a | grep rmem_default
/sbin/sysctl -a | grep rmem_max
/sbin/sysctl -a | grep wmem_default
/sbin/sysctl -a | grep wmem_max

Ex:
# /sbin/sysctl -a | grep shm
kernel.shmmni = 4096
kernel.shmall = 2097152
kernel.shmmax = 536870912
kernel.shm-use-bigpages = 0
# /sbin/sysctl -a | grep sem
kernel.sem = 250 32000 100 128
# /sbin/sysctl -a | grep file-max
fs.file-max = 65536
# /sbin/sysctl -a | grep ip_local_port_range
net.ipv4.ip_local_port_range = 1024 65000
# /sbin/sysctl -a | grep rmem_default
net.core.rmem_default = 262144
# /sbin/sysctl -a | grep rmem_max
net.core.rmem_max = 262144
# /sbin/sysctl -a | grep wmem_default
net.core.wmem_default = 262144
# /sbin/sysctl -a | grep wmem_max
net.core.wmem_max = 262144

For Novell SUSE Linux releases, use the following to ensure that the system reads the /etc/sysctl.conf file at boot time:
/sbin/chkconfig boot.sysctl on

Setting Shell Limits for the oracle User
Oracle recommends setting limits on the number of processes and open files each Linux account may use. To make these changes, cut and paste the following commands as root:
cat /etc/security/limits.conf EOF
oracle soft nproc 2047
oracle hard nproc 16384
oracle soft nofile 1024
oracle hard nofile 65536
EOF

cat /etc/pam.d/login EOF
session required /lib/security/pam_limits.so
EOF
For RHEL4, use the following:
cat /etc/profile EOF
if [ \$USER = ""oracle"" ]; then
if [ \$SHELL = ""/bin/ksh"" ]; then
ulimit -p 16384
ulimit -n 65536
else
ulimit -u 16384 -n 65536
fi
umask 022
fi
EOF

cat /etc/csh.login EOF
if ( \$USER == ""oracle"" ) then
limit maxproc 16384
limit descriptors 65536
umask 022
endif
EOF
For SLES 9, use the following:
cat /etc/profile.local EOF
if [ \$USER = ""oracle"" ]; then
if [ \$SHELL = ""/bin/ksh"" ]; then
ulimit -p 16384
ulimit -n 65536
else
ulimit -u 16384 -n 65536
fi
umask 022
fi
EOF

cat /etc/csh.login.local EOF
if ( \$USER == ""oracle"" ) then
limit maxproc 16384
limit descriptors 65536
umask 022
endif
EOF


Enable Trace on any Executable to find out whats happening at O.S. Level
truss -eafl -o output.trc -o truss.txt
for example for Apache
truss -eafl -o output.trc -o truss.txt apachectl

This command will trace any system calls and will help you to find out errors.


How to schedule a Job in Unix
Use cronjob
crontab -l ( list current jobs in cron)
crontab -e ( edit current jobs in cron )
_1_ _2_ _3_ _4_ _5_ $Job_Name
1 - Minutes (0-59)
2 - Hours ( 0-24)
3 - day of month ( 1- 31 )
4 - Month ( 1-12)
5 - A day of week ( 0- 6 ) 0 -> sunday 1-> monday
e.g. 0 0 1 * 5 Means run job at Midnight on 1st of month & every friday
crontabs are in /var/spool/cron. The date/time of the users file is the last time they modified /var/cron/log


How to extract cpio file
cpio -idmv < file_name   (Don’t forget to use sign < before file name)

How to find CPU & Memory detail of linux
cat /proc/cpuinfo  (CPU)
cat /proc/meminfo (Memory)


How to find if Operating system in 32 bit or 64 bit ?
For solaris use command
isainfo -v
If you see out put like
32-bit sparc applications
That means your O.S. is only 32 bit
but if you see output like
64-bit sparcv9 applications
32-bit sparc applications
above means your o.s. is 64 bit & can support both 32 & 64 bit applications


How to find Process ID (PID) associated with any port ?
This command is useful if any service is running on a particular port (389, 1521..) and that is run away process which you wish to terminate using kill command
lsof | grep {port no.}  (lsof should be installed and in path)


How to change a particular pattern in a file ?
Open file using vi or any other editor, go in escape mode (by pressing escape) and use

:1,$s/old_pattern/new_parameter/gc   ( g will change globally, c will ask for confirmation before changing )

How to create symbolic link to a file ?
ln -s  pointing_to  symbolic_name
e.g. If you want to create symbolic link from a -> b
ln -s b a   
(Condition:you should have file b in that directory & there should not be any file with name a)


Grep for word in a zip file
unzip -t xmlparserv2.zip |grep HandlerBase
unzip -l appsborg2.zip | grep 9.0.4
0 04-18-03 17:10 .xdkjava_version_9.0.4.0.0_production


Redirecting standard error to standard output
sh patch.sh 2>&1 | tee patch.log


Printer check
lpstat -p printername
printer printername is idle. enabled since Mon Sep 15 14:50:53 2008. available.

lpstat -t | grep cac-check-bak

# ls -l test
-rw-r--r-- 1 root root 727 Apr 9 17:50 test
# lp -d cac-check-bak test
request id is cac-check-bak-54 (1 file(s))

# lpstat -o cac-check-bak

STEPS:
1. Verify whether the Printer IP is pingable from the server.
root# ping
2. Verify whether we are able to telnet to port 515 (or 9100 if HP) of the Printer IP.

1. To Add Network Printers:
Step: 1
Command:
lpadmin -p -o nobanner,dest= ,protocol=bsd -v /dev/null -I simple,postscript -T PS -i

/usr/lib/lp/model/netstandard
Step: 2
Enable and Accept The Printer:
enable
accept
Step: 3
Check the printer status.
lpstat -t | grep
Step: 4
Fire a test print and check the queue.
lp -d ( firing printjob)

-----------------------------APPS---------------------------------
SEE NOTE ONE ABOVE

The below are the steps for adding printer on Apps:
1. Login to Application as SYSADMIN.
2. Select System Administrator responsibility.
3. Open Printer -> Register form
4. Enter the Printer name, Type and Description
5. Save


To know hostnae from IP address
nslookup IP

Verify hostnames are fully qualified with the domain
-server: login as root
hostname
server.domainname


If the hostname is not fully qualified (with domain name) for a server, perform the following check:
cat /etc/sysconfig/network
NETWORKING=yes
HOSTNAME=server.domainnmae
GATEWAY=xx.xxx.xx.xx
If the HOSTNAME shows the fully qualified name in this file, then issue a reboot command for the settings to take effect.


To kill LOCAL=NO processes on DB
ps -ef | grep 'LOCAL=NO' | grep orad1 | awk '{ print $2 }' | xargs -i -t kill -9 {}


Embedding SQL in Shell
#!/bin/sh
VAR1=`sqlplus -s username/password end
set pagesize 0 feedback off ver off heading off echo off
select sysdate from dual;
exit;
end`
echo “system date is ” $VAR1
#end of shell script



Checking the Sun Operating System
System and hardware Configuration:
Hardware Status: sun4 (UNIX command; ‘arch’)
Operating System: SunOS 5.11 Generic sun4u sparc SUNW, Sun-Fire-V240 (UNIX command; ‘uname –a’).
CPU: 2 CPU’s. Each having the sparcv9 processor operates at 1503 MHz and has a sparcv9 floating point processor (UNIX command; ‘psrinfo –v’).
Memory size: 5120 Megabytes (UNIX command; ‘prtconf |grep size’).
Swap Total: (45440k bytes allocated + 4032k reserved = 49472k used) 14468936k available, i.e., 14GB (UNIX command; ‘swap –s’).
Check file System mounted and its respective size (UNIX command; ‘df -h’)


Screen commands
which screen
/usr/local/bin/screen
screen -list
screen -RR -DD screenname


To extract jar files
jar -xfv timesheet.jar
jar xvf $ORACLE_HOME/8402746/ewt3.jar


To split large files
split -l 2000 FILE
# split -l 50 book sect

This example splits book into 50-line segments named sectaa, sectab, sectac, and so forth.

# split book
This example splits book into 1000-line segments named xaa, xab, xac, and so forth.

Following are the most requred OS commands while installing and configuring Oracle Software on Unix/Linux Operating Systems.
Operating System: AIX 5L Based Systems (64-Bit)
Physical RAM: # /usr/sbin/lsattr -E -l sys0 -a realmem
Swap Space: # /usr/sbin/lsps -a

Operating System: HP Tru64 UNIX
PPhysical RAM: # /bin/vmstat -P grep "Total Physical Memory"
Swap Space: # /sbin/swapon -s

Operating System: HP-UX Itanium
Physical RAM: # /usr/contrib/bin/machinfo grep -i Memory
Swap Space: # /usr/sbin/swapinfo -a

Operating System: HP-UX PA-RISC (64-Bit)
Physical RAM: # grep "Physical:" /var/adm/syslog/syslog.log
Swap Space: # /usr/sbin/swapinfo -a

Operating System: IBM zSeries Based Linux, LinuxItanium/POWER/x86/x86-64
Physical RAM: # grep MemTotal /proc/meminfo
Swap Space: # grep SwapTotal /proc/meminfo

Operating System: Solaris SPARC 64-Bit/x86/x86-64
Physical RAM: # /usr/sbin/prtconf grep "Memory size"
Swap Space: # /usr/sbin/swap -s



Group and User Creation in Solairs.
This post is for creating an Unix Group and a User.

Solaris 5.10
--------------------------------------
Creating a Group:
--------------------------------------

For instance: Group - dba

Login as ROOT User

login: root
Password:
Sun Microsystems Inc. SunOS 5.10 Generic January 2005
#

To Check whther the group is already created.

# grep dba /etc/group
or
# cat /etc/groupgrep dba

If dba group info is not displayed, then

To create a Group:

# groupadd dba

Syntax: groupadd -g

# cat /etc/groupgrep dba

dba:103:

Note: The gid, which needs to be changed, should be not being the gid of other group.
Example:
# usermod -g 333 dba
UX: groupmod: ERROR: 103 is already in use. Choose another.

To remove a Group:

# groupdel dba

# cat /etc/groupgrep dba

Commands:
---------

Create Group - groupadd
Modify Group - groupmod
Remove Group - groupdel

For more details, check the man pages i.e. man groupadd, man groupmod, and man groupdel

--------------------------------------
Creating a User Account:
--------------------------------------

For instance: User - Oracle

Login as ROOT User

login: root
Password:
Sun Microsystems Inc. SunOS 5.10 Generic January 2005
#

To Check whther the oracle user is already created.

# grep oracle /etc/passwd
Or
# id –a oracle

If Oracle group info is not displayed, then

To create a User:

# useradd –d /export/home/oracle –m -g dba -s /bin/sh oracle


Note: In the above command
Option -Discription -Value
------------- -------------------- --------------------
-d -Home for the Oracle user -/export/home/oracle
-m -For making directory
-g -Primary Group dba
-s -Default Shell for the User -/bin/sh
Login -Name -Oracle

# grep oracle /etc/passwd
oracle:x:100:100::/export/home0/oracle:/bin/sh

To modify a User:

For example: To Comment the user and assing secondray group to the user

# usermod -c "Owner of the Oracle Software 10g" -G oinstall oracle

Note: In the above command
Option -Discription -Value
------------- -------------------- --------------------
-c -Comment -"Owner of the Oracle Software"
-G -econdary -Group oinstall


# grep oracle /etc/passwd
oracle:x:100:100:Owner of the Oracle Software 10g:/export/home0/oracle:/bin/sh

To set a password:

# passwd -r files oracle
New Password: XXXXXXXX
Re-enter new Password: XXXXXXXX
passwd: password successfully changed for oracle

Note: Where XXXXXXXX is the new password for oracle User.

To remove a user:

# userdel -r oracle

Note: The "-r" option is used to remove the user's home directory from the system.
And the Oracle user account should not be removed until and unles required, and
this should not be done on Production Servers.

# grep oracle /etc/passwd


Commands:
---------
Create a user - useradd
Modify a user - usermod
Rmove a user - userdel

seta password to the user- passwd

For more details, please check the man pages in UNIX i.e. man useradd, man usermod, and man userdel


UnZip can be downloaded from the following URLs:
Metalink : http://updates.oracle.com/unzips/unzips.html
Info-Zip : http://www.info-zip.org.

Perl 5.005
Use the Perl shipped with iAS1022 and RDBMS 9i if available or download it from
Perl.com

"Obtain and Install JDK 1.3 on All Applications Middle Tier Server Nodes

Download JDK 1.3
Operating System JDK 1.3 Download Location
Sun Solaris (SPARC) http://java.sun.com/j2se/1.3/download.html
Windows NT/2000 http://java.sun.com/j2se/1.3/download.html
HP HP/UX http://www.hp.com/products1/unix/java/
IBM AIX http://www.ibm.com/developerworks/java/jdk/aix/index.html
HP Tru64 UNIX http://www.compaq.com/java/download/index.html
Linux http://java.sun.com/j2se/1.3/download.html

follow the installation instructions provided in the package to install the JDK for each Applications middle tier

server node. Take a note for the new JDK 1.3 installation top-level directory with the full path as [JDK13_TOP]
[JDK13_TOP]/bin/java -version ---> confirm downloaded version


Script to kill services
# Kill leftover Apache processes
kill_processes=`ps -ef | grep ""/iAS/Apache/Apache/bin/"" | awk '{print $2}'`
echo $kill_processes
kill -9 $kill_processes

# Kill leftover Discoverer processes
kill_processes=`ps -ef | grep ""/discwb4/bin/"" | awk '{print $2}'`
echo $kill_processes
kill -9 $kill_processes


# Kill leftover JVM processes - THIS IS NOW APPLICABLE ONLY FOR OC4J
# kill_processes=`ps -ef | grep ""/native_threads/"" | awk '{print $2}'`
# echo $kill_processes
# kill -9 $kill_processes

# kill_processes=`ps -ef | grep ""/usr/j2se/"" | awk '{print $2}'`
# echo $kill_processes
# kill -9 $kill_processes"


Convert .sh file to unix format
“:set fileformat=unix”



Unix Operating System release
Solaris -> cat /etc/release
Red Hat Linux -> cat /etc/redhat-release

system log file
/var/adm/messages
service is /usr/sbin/syslogd
ps -ef|grep syslo
root 27893 7373 0 00:02:27 pts/4 0:00 grep syslo
root 9222 1 0 23:48:53 ? 0:00 /usr/sbin/syslogd

"How to find hostname on Linux/OEL ?
Use command “hostname” to find host name of Linux

How to change hostname on Linux/OEL ?

Open file /etc/sysconfig/network using editor like vi , nano or ed
Change entry HOSTNAME=XXXXXX to
HOSTNAME=New_Host_Name
Restart xinetd service or reboot Linux/OEL
Restart xinetd service xinetd restart
Reboot Linux reboot
If you have defined hostname resolution in hosts file then change entry in /etc/hosts

Starting xvfb
run this as applvis
nohup /usr/bin/X11/Xvfb :0 &
and then run this as applvis
nohup /usr/bin/X11/mwm &


O/s monitoring
use top/iostat/sar/vmstat

Most of the times while viewing big log files in vi editor, you would get "Line too Long" error
A simple solution to this problem is to use the fold command:

fold -80 yourfile.log > folded.log


Program to convert plain text files in DOS format to UNIX format.
dos2unix *.*


Below is the script which we used, - where certain files in non-prod were pointing to PROD.
#! /bin/bash

find /d11/applprod/PROD/apps/tech_st/10.1.2 -exec grep -l '/d11/applprod/GOLD' {} \; > ./files

for i in `cat ./files`
do
sed -e 's:d11/applprod/GOLD: d11/applprod/PROD:g' $i > temp_file
cp -rp temp_file $i
done


To get sql o/p in xls format
set markup html on spool on
spool emp.xls

Tuesday, September 14, 2010

OCM

Manual way of collection and upload
$ pwd
/d02/oravis/visdb/10.2.0/ccr/bin
$ ./emCCR collect
Oracle Configuration Manager - Release: 10.3.3.1.0 - Production
Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
------------------------------------------------------------------
Collection and upload done.

Verify in the systems tab of metalink to see the upload is done

RDA

review, download and run the ./rda.sh script as described in Note: 250262.1

other notes for rda
Note: 314422.1 - Remote Diagnostic Agent (RDA) 4 - Getting Started
Note: 330363.1 - Remote Diagnostic Agent (RDA) 4 - FAQ
Note: 330344.1 - Remote Diagnostic Agent (RDA) 4 - Training
Note: 330362.1 - Remote Diagnostic Agent (RDA) 4 - Troubleshooting Guide

To simplify RDA configuration, use an RDA profile, and the best choice is the DB9i profile, even for 10g or 11g, because the DB10g profile is a superset of DB9i that adds stuff we don't care about (for DB Install). First set the ORA* environment variables for the DB of interest, then run the RDA config pass:

Unix:
cd {dir you unzipped RDA into}
export ORACLE_HOME={dir}
export ORACLE_SID={name}
./rda.sh -Syvp DB9i

Next, edit the resulting setup.cfg file, search for 'sysdba' (first hit will be a comment), and change the 2 lines directly above and below as follows:
for SQL_LOGIN= replace 'system' with '/' and for SQL_SYSDBA= replace 0 with 1
then save it, and run the (rda) command again, with no arguments this time:
Unix:
./rda.sh
The output subdirectory will contain a new RDA*.zip file for you to upload