Wednesday, September 30, 2009

See the output of a command on your screen, and store the output in a file

To capture only the output associated with specific operating system command,use the tee command. Output generated by a command is writen, both, on the screen and a designated file.

Example below runs the ls command to list all files in a directory, and save
that output to a file, for later viewing to determine the names and sizes of files on a particular date:

$ ls -altr /ora01/BRDSTN | tee /home/oracle/log/oct15_df.log

Sample output (displayed to the screen and recorded in the log file)

-rw-r----- 1 oracle oinstall 52429312 Oct 15 08:00 redo03a.log
-rw-r----- 1 oracle oinstall 838868992 Oct 15 08:25 undotbs01.dbf
-rw-r----- 1 oracle oinstall 524296192 Oct 15 08:30 system01.dbf
-rw-r----- 1 oracle oinstall 15056896 Oct 15 08:37 control01.ctl

Tuesday, September 29, 2009

R12 Instance Home Overview

Oracle Applications/E-Business Suite Release 12 introduces a new concept of a top-level directory for an Applications Instance which is known as Instance Home and is denoted the environment variable $INST_TOP.

Instance Home contains all the config files, log files, SSL certificates etc.

Advantages of new INSTANCE HOME

• The additional Instance Home makes the middle tier more easy to manage and organised since the data is kept separate from the config files. The Instance Home also has the ability to share the Applications and Technology stack code across multiple instances.

• Another advantage of the Instance Home is that the Autoconfig no longer writes anything to the APPL_TOP and ORACLE_HOME directories, everything is now written in the INST_TOP as a result APPL_TOP and ORACLE_HOME can also be made read only file system if required . Earlier say the adpatch used to write the log file in APPL_TOP/admin directory but with the new model the APPL_CONFIG_HOME/admin is used.

• To create a new instance that shares an existing middle-tier, just create a new instance_top with proper config files and NFS Mount the middle tier in the server.The basic structure of the Instance Home is:$APPS_BASE/inst/apps/$CONTEXT_NAME or also defined by environment variable $INST_TOP, where APPS_BASE (which does not have or need a corresponding environment variable) is the top level of the Applications installation and $CONTEXT_NAME is the highest level at which the Applications context exists (format $SID_$hostname).

Instance Home Directory Structure
• $INST_TOP/admin/scripts ($ADMIN_SCRIPTS_HOME): All AD scripts are located here
• $INST_TOP/appl ($APPL_CONFIG_HOME) : For standalone envs, this is set to
• $APPL_TOP
• $INST_TOP/appl/fnd/12.0.0/secure FND_SECURE: The dbc file is located here
• $INST_TOP/appl/admin All the env config files are located here
• $INST_TOP/certs SSL Certificates go here
• $INST_TOP/logs LOG_HOME: Central log file location. All log files are placed here (except adconfig)
• $INST_TOP/logs/ora ($ORA_CONFIG_HOME)
• $INST_TOP/logs/ora/10.1.2 ‘C’ Oracle home config, Contains tnsnames and forms listener servlet config files
• $INST_TOP/logs/ora/10.1.3 Apache & OC4J config home, Apache, OC4J and opmn. This is the ‘Java’ oracle home configuration for OPMN, Apache and OC4J
• $INST_TOP/pids Apache/Forms server PID files are located here
• $INST_TOP/portal Apache’s DocumentRoot folder

Saturday, September 26, 2009

ORA-12203: TNS:unable to connect to destination

Cause:

1.Invalid address specified or destination is not listening.
2.This error can also occur because of underlying network or network transport problems

Solution:

1.Verify that the net service name you entered was correct.
2.Verify that the ADDRESS portion of the connect descriptor which corresponds to the net service name is correct.
3.Ensure that the destination process (for example the listener) is running at the remote node.

ORA-01555 Snapshot too old

ORA-01555 Snapshot too old (Rollback has been overwritten)

Difference between two env files in CONTEXT.env and APPS CONTEXT.env under $APPL_TOP

APPS CONTEXT.env is main environment file which inturn calls other environment files like CONTEXT.env under $APPL_TOP, CONTEXT.env under 806 ORACLE_HOME and custom.env for any Customized environment files.

Thursday, September 24, 2009

To find the latest application version

select ARU_RELEASE_NAME||'.'||MINOR_VERSION||'.'||TAPE_VERSION version, START_DATE_ACTIVE updated,ROW_SOURCE_COMMENTS "how it is done", BASE_RELEASE_FLAG "Base version" FROM AD_RELEASES where END_DATE_ACTIVE IS NULL;

To get file version of any application file which is changed through patch application

select A.FILE_ID, A.APP_SHORT_NAME, A.SUBDIR, A.FILENAME, max(B.VERSION) from AD_FILES A, AD_FILE_VERSIONS B where A.FILE_ID = B.FILE_ID and B.FILE_ID = 86291 group by A.FILE_ID, A.APP_SHORT_NAME, A.SUBDIR, A.FILENAME;