четверг, 2 декабря 2010 г.

way to connect to APPS or how to bypass default Login screen.

Check this out

http://app.com:8000/OA_HTML/fndvald.jsp?username=&password=pass

вторник, 9 ноября 2010 г.

FAILED: file FNDNLINS.sql on worker 1 for product fnd username APPLSYS.

If you use ADADMIN utility and get ERROR

FAILED: file FNDNLINS.sql on worker 1 for product fnd username APPLSYS.

sqlplus> @..... FNDNLINS.sql
MESG
--------------------------------------------------------------------------------
LANGUAGE=AMERICAN
PACKAGE=FND_LOOKUP_VALUES_PKG
SQLERRM=ORA-00001: unique constraint(APPLSYS.FND_LOOKUP_VALUES_U2) violated


Solution



[applmgr@app u02]$
adctrl


Copyright (c) 2002 Oracle Corporation
Redwood Shores, California, USA

AD Controller

Version 11.5.0

NOTE: You may not use this utility for custom development
unless you have written permission from Oracle Corporation.


Attention: AD Controller no longer checks for unapplied pre-requisite patches.
You must use OAM Patch Wizard for this feature. Alternatively, you can
review the README for pre-requisite information.


Your default directory is '/u02/oracle/pr/prappl'.
Is this the correct APPL_TOP [Yes] ?

AD Controller records your AD Controller session in a text file
you specify. Enter your AD Controller log file name or press [Return]
to accept the default file name shown in brackets.

Filename [adctrl.log] :

************* Start of AD Controller session *************
AD Controller version: 11.5.0
AD Controller started at: Tue Nov 09 2010 12:14:42

APPL_TOP is set to /u02/oracle/pr/prappl

Reading product information from file...

Reading language and territory information from file...

Reading language information from applUS.txt ...

Enter the ORACLE username of Application Object Library [APPLSYS] :

Enter the ORACLE password of Application Object Library [APPS] : APPS_password

AD Controller is verifying your username/password.
The status of various features in this run of AD Controller is:

<-Feature version in->
Feature Active? APPLTOP Data model Flags
------------------------------ ------- -------- ----------- -----------
CHECKFILE Yes 1 1 Y N N Y N Y
PREREQ Yes 6 6 Y N N Y N Y
CONCURRENT_SESSIONS No 2 2 Y Y N Y Y N
PATCH_TIMING Yes 2 2 Y N N Y N Y
PATCH_HIST_IN_DB Yes 6 6 Y N N Y N Y
SCHEMA_SWAP Yes 1 1 Y N N Y Y Y


AD Controller Menu
---------------------------------------------------

1. Show worker status
2. Tell worker to restart a failed job
3. Tell worker to quit
4. Tell manager that a worker failed its job
5. Tell manager that a worker acknowledges quit
6. Restart a worker on the current machine
7. Exit
HIDDEN 8.

Enter your choice [1] : 8

Enter the worker number(s)/range(s) or 'all' for all workers,
or press [Return] to go back to the menu : 1

Status changed to 'Skip & restart' for worker 1.
Review the messages above, then press [Return] to continue.

Fixed: file FNDNLINS.sql on worker 1 for product fnd username APPLSYS.
Completed: file FNDNLINS.sql on worker 1 for product fnd username APPLSYS.

Telling workers to quit...

2 workers have quit. Waiting for 30 more.
12 workers have quit. Waiting for 20 more.
15 workers have quit. Waiting for 17 more.
22 workers have quit. Waiting for 10 more.
23 workers have quit. Waiting for 9 more.
29 workers have quit. Waiting for 3 more.

All workers have quit.


Dropping FND_INSTALL_PROCESSES table...


FND_INSTALL_PROCESSES table dropped.


Dropping AD_DEFERRED_JOBS table...


AD_DEFERRED_JOBS table dropped.


Review the messages above, then press [Return] to continue.
You should check the file
/u02/oracle/pr/prappl/admin/pr/log/adadmin.log

for errors.

четверг, 4 ноября 2010 г.

Waiting for snapshot controlfile enqueue

When RMAN needs to back up or resynchronize from the control file, it first
creates a snapshot or consistent image of the control file. If one RMAN job is
already backing up the control file while another needs to create a new snapshot
control file, then you may see the following message:

RMAN-08512: waiting for snapshot controlfile enqueue


Under normal circumstances, a job that must wait for the control file enqueue
waits for a brief interval and then successfully retrieves the enqueue.
Recovery Manager makes up to five attempts to get the enqueue and then fails the
job. The conflict is usually caused when two jobs are both backing up the control
file, and the job that first starts backing up the control file waits for service
from the media manager.

To determine which job is holding the conflicting enqueue:

1. After you see the first RMAN-08512: waiting for snapshot controlfile enqueue
message, start a new SQL*Plus session on the target database:

% sqlplus sys/sys_pwd@prod1


2. Execute the following query to determine which job is causing the wait:

SELECT s.sid, username AS "User", program, module, action, logon_time "Logon", l.*
FROM v$session s, v$enqueue_lock l
WHERE l.sid = s.sid and l.type = 'CF' AND l.id1 = 0 and l.id2 = 2;


You should see output similar to the following (the output in this example has
been truncated):

SID User Program Module Action Logon
--- ---- -------------------- ------------------------- ---------------- ---------
9 SYS rman@h13 (TNS V1-V3) backup full datafile: c1 0000210 STARTED 21-JUN-10


To kill active session
Run


select vs.sid, vs.username, vs.osuser, vs.process fg_pid,
vp.spid bg_pid
from v$session vs, v$process vp
where vs.paddr = vp.addr
/


If you get something like:

SID USERNAME OSUSER FG_PID BG_PID
---- --------------- ---------- --------- ---------
10 JULIAN JULIAN 1965:6969 1234

run in unix as the oracle user

kill -9 1234

среда, 3 ноября 2010 г.

Rman catalog Database creation

Rman catalog Database creation

1.connect to the catalog database

a)here create a catalog tablespace

sql> create tablespace catalog
datafile ‘/……………………/catalog01.dbf’ size 250 m

b)create a user for recover catalog

sql> create user rmancat identified by rman
default tablespace catalog
default temporary tablespace temp
quota unlimited on catalog;

c)Grant the appropriate privilages.

sql>grant connect,resource,recover_catalog_owner to rmancat;

2. Login to the operating system

export ORACLE_SID=catalog

rman
rman> connect catalog rmancat/rman

rman>create catalog tablespace “CATALOG”

rman> exit

3.log in to the Operating system

export ORACLE_SID=sample
rman

rman> connect target sys/sys
rman>connect catalog rmancat/rman@catalog
rman > register database.

Now you configured your catalog database….


a)Go to the tnsname.ora file.

Add the following highlighted entries

CATALOG =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = your_host_with_rmancat)(PORT = 1522))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = your_global_name)
)
)

среда, 27 октября 2010 г.

Oracle Grid Control Agent 11.1.0.1 Installation and Configuration

Agent Installation and Configuration

More detailed documents can be found at
http://download.oracle.com/docs/cd/B16240_01/doc/install.102/e10953/toc.htm

Installation


Method 1: Install agent from local file with silent mode.


This is the fastest method to install agent. Take 11.1.0 agent for example.

1) download Linux_Grid_Control_agent_download_11_1_0_1_0.zip from /ade_autofs/shiphomes_linux/em/11.1.0/100227/agentdownload_only/ , you can execute command in host emqa1-vm9.cn.oracle.com as below
scp -rvp aime@stsdc02-1.us.oracle.com:/ade_autofs/shiphomes_linux/em/11.1.0/100227/agentdownload_only/download Linux_Grid_Control_agent_download_11_1_0_1_0.zip /home/oracle/

2) extract the zip file to local folder, unzip Linux_Grid_Control_agent_download_11_1_0_1_0.zip -d ./agent

3) prepare the additional_agent.rsp file. modify the rsp file as below, the values depend on oms information.
SECURITY_UPDATES_VIA_MYORACLESUPPORT=False
DECLINE_SECURITY_UPDATES=True
SKIP_SOFTWARE_UPDATES=True
ORACLE_AGENT_HOME_LOCATION=”/scratch/aime”
OMS_HOST=smptst-svc1.us.oracle.com
OMS_PORT=1159
AGENT_REGISTRATION_PASSWORD=agent4321

4) install agent with silent mode.
$cd agent_install_home/linux/agent
$./runInstaller -silent -responseFile ~/additional_agent.rsp

5) after installation finished and successfully, run root.sh under agent_home directory

Method 2: Install agent using agent push on oms deploy page.


1) Go to GC console page , click on Deployments, then click on Install Agent under Agent Installation, Click on Fresh Install.

2) Provide the host where you want to install the agent, the credential, Install_dir. Leave port blank ,then it will use a random port so that it won’t fail if the default port 3872 used. Remember provide the Management Server Registration Password and then click on next to the end.

Method 3: Install agent using NFS Agent Installation.

Suppose there is agent installed on emqa1-vm1.cn.oracle.com, the agent_home is /scratch/aime/agent11g , this need get installed on vm9.
1) mount emqa1-vm1.cn.oracle.com:/scratch/aime/agent11g /scratch/aime/agent11g . verify that the folder path is same as the agent_home in vm1.

2) $cd /scratch/aime/agent11g/sysman/install
$./nfsagentinstall -s /scratch/state_dir

3) then the agent will be installed to /scratch/state_dir , you can use emcli start/stop/status agent under /scratch/state_dir/bin

Method 4: Install agent using OUI.

Make sure that the agent installation file is released or it can be installed by oui. It’s the easiest method to install agent.
1) access the host via vnc and then run the runInstaller .

2) provide the information according to the oui and then it’ll be installed successfully.

Configuration


This part describes how to change agent pointing to another oms without re-install.
1) make sure you stop the agent. check the status of agent, /agent_home/bin/emctl status agent , stop the agent /agent_home/bin/emctl stop agent
2) cd agent_home/sysman/emd , delete all files under upload and state
3) cd agent_home/sysman/config , vi emd.properties , modify REPOSITORY_URL and emdWalletSrcUrl .
4) /agent_home/bin/emctl start agent
agent_home/bin/emctl secure agent, provide the register password
agent_home/bin/emctl upload agent
make sure the three command above executed successfully
5) then you’ll see your agent pointing to the new oms.

вторник, 26 октября 2010 г.

Installing Oracle Enterprise Manager Grid Control 11gR1 on Linux

Installing Oracle Enterprise Manager Grid Control 11gR1 on Linux

This document will detail the installation of Oracle Enterprise Manager Grid Control 11gR1 on Oracle Enterprise Linux 5.5.

Oracle WebLogic Server 10.3.2 or higher is required to be installed on the host in which you are going to install Enterprise Manager Grid Control.

The Oracle Database for the repository needs to be Oracle Database 10gR2 (10.2.0.4) or higher. The UNDO table space must have at least 200MB allocated at the time of install. The parameter SESSION_CACHED_CURSORS must be 200 or greater and the parameter PROCESSES must be 500 or greater. If these parameters along with the UNDO table space size are not set at the time of installation they will produce errors on Step 7 Connect to Oracle Database. If the database was created with Database Control enabled you will need to remove the Database Control repository.

To start the installation process execute the runInstaller script.

Enter your My Oracle Support user name and password to set up security update notification and initiate configuration manager. This information is option. Click the Next button to continue.


It is possible to install patches/updates during the installation process. If you choose to apply patches/updates you can either get them on demand using your My Oracle Support login credentials or you can download the patches/updates prior to installation and store them in a central location. After making your choices click the Next button to continue.

You can either install a new Enterprise Manager system or add an addition management server. Both install options require an existing certified Oracle WebLogic server. For this document we are going to install a new Enterprise Manager system. Click the Next button to continue.

Next are the standard prerequisite checks that are common with Oracle software installs. Click the Next button to continue.

The installer should pickup the location of the middleware home that was used for the installation of Oracle WebLogic Server. If the installer does not find middleware home either type in or browse to the location that contains the Oracle WebLogic Server. You can also provide another location for the Oracle Management Service. Click the Next button to continue.

The installation process will create a WebLogic domain called GCDomain all that we need to provide is the password. Click the Next button to continue.

Now we need to provide the install the connection information for the database to be used as the repository. Provide the hostname, port, SID and SYS password for the database you are going to use for the Grid Control Repository. Click the Next button to continue.

Three table spaces are created to house the Enterprise Manager Grid Control repository. You can either accept the defaults for the data files or provide names that match your naming scheme. You also need to provide a password for the SYSMAN user.


Enter the password to be used to secure the communications between the agents and management service. You can also choose to only allow secure agents to communicate with the repository and to only allow secure access to the console. Both are set by default.


You have the ability to customize the ports used by Enterprise Manager to fit in your environment. Click the Next button to continue.

The Review screen is your last chance to make any changes to previous steps before starting the installation. Click the Install button to start the installation.

Installation steps and progress are displayed on the Install Progress screen.

At the end of the installation you will be asked to run a configuration script as the root user. In a terminal session connect as the root user and run MW_HOME/weblogic/oms11g/allroot.sh. Note I chose not to overwrite any files.

[root@gc ~]# /u02/app/oracle/product/weblogic/oms11g/allroot.sh

After the scripts are complete click the OK button to continue.

Next several configuration assistants will be executed.

After the entire configuration is complete you will get the Finish dialog that will detail the installation and provide the URL to access Enterprise Manager Grid Control.

Possible Errors

Step 7 of 13 Connect to Oracle Database

If the database you are going to use as a repository is configured with Database Control you will receive an error message like the one below.

If you do get this error, click the OK button to dismiss the error and open another terminal session and run the $ORACLE_HOME/bin/emca – deconfig dbcontrol db command. Note: If your repository database is in a RAC cluster you will need to add –cluster after –repos drop.

[oracle@gc ~]$ emca -deconfig dbcontrol db -repos drop -SYS_PWD password -SYSMAN_PWD password


After removing database control from the database you may receive another error such as the one below.

The database to be used as the Grid Control repository needs to have the parameters SESSION_CACHED_CURSORS set to 200 or greater and PROCESSES set to 500 or greater. Setting these parameters will require the database to be bounced in order for the changes to take effect. Click the OK button to dismiss the error and connect to the database to change the parameters.

SQL> alter system set session_cached_cursors=200 scope=spfile;

SQL> alter system set processes=500 scope=spfile;

SQL> shutdown immediate

SQL> startup


UNDO tablespace size has to be at least 200MB



Click the OK button to dismiss the error and resize the data file associated with the undo table space to 200MB or more.

SQL> select file_name from dba_data_files;
FILE_NAME
---------------------------------------------------
/u02/app/oracle/oradata/gcrepo/users01.dbf
/u02/app/oracle/oradata/gcrepo/undotbs01.dbf
/u02/app/oracle/oradata/gcrepo/sysaux01.dbf

SQL> alter database datafile '/u02/app/oracle/oradata/gcrepo/undotbs01.dbf' resize 400M;
Database altered.