It has been more than two years since the last Developer 6i patchset 18 was certified with Oracle E-Business Suite Release 11i, and now, Developer 6i patchset 19 (6.0.8.28) is certified with Oracle Apps 11i.
Actually, since we migrated from Jinitiator to Java JRE 1.6, we've encountered some frustrating mouse focus issues, I really hope they were fixed with this patch and won't appear after upgrade.
Like with the last patch set, I'll bring you "step-by-step" upgrade instructions for linux deployments.
Other Operation Systems's need another patches - see Note 125767.1 - Upgrading Developer 6i with Oracle Applications 11i.
*** All patches must be installed on all Application tier nodes
1. Stop all application processes by adstpall.sh
2. Apply the latest certified Developer 6i patch set 19 (6194129)
- Source applications environment (e.g source .../testappl/APPSORA.env)
- Verify that $ORACLE_HOME is the 806_ORACLE_HOME
- Execute with applmgr user
$ unzip p6194129_60828_LINUX.zip
$ cd developer6i_patch19
$ ./patch_install.sh 2>&1 | tee patch_install_p19.log
- Check patch_install_p19.log for any errors
- Execute the following to relink Procedure Builder, Forms, Graphics and Reports
$ cd $ORACLE_HOME/procbuilder60/lib; make -f ins_procbuilder.mk install
$ cd $ORACLE_HOME/forms60/lib; make -f ins_forms60w.mk install
$ cd $ORACLE_HOME/graphics60/lib; make -f ins_graphics60w.mk install
$ cd $ORACLE_HOME/reports60/lib; make -f ins_reports60w.mk install
3. Apply patch 7156414
- Unzip patch file
$ unzip p7156414_60828_GENERIC.zip
- Backup old files
$ cp -r $ORACLE_HOME/forms60/java/oracle/forms/handler/UICommon.class $ORACLE_HOME/forms60/java/oracle/forms/
handler/UICommon.class.PRE_BUG7156414
$ cp -r $ORACLE_HOME/forms60/java/oracle/forms/handler/ComponentItem.class $ORACLE_HOME/forms60/java/oracle/forms/
handler/ComponentItem.class.PRE_BUG7156414
$ cp -r $ORACLE_HOME/forms60/java/oracle/forms/handler/BlockScroller.class $ORACLE_HOME/forms60/java/oracle/forms/
handler/BlockScroller.class.PRE_BUG7156414
$ cp -r $ORACLE_HOME/forms60/java/oracle/forms/handler/FormCanvas.class $ORACLE_HOME/forms60/java/oracle/forms/
handler/FormCanvas.class.PRE_BUG7156414
$ cp -r $ORACLE_HOME/forms60/java/oracle/forms/handler/FormWindow.class $ORACLE_HOME/forms60/java/oracle/forms/
handler/FormWindow.class.PRE_BUG7156414
$ cp -r $ORACLE_HOME/forms60/java/oracle/forms/ui/VBean.class $ORACLE_HOME/forms60/java/oracle/forms/
ui/VBean.class.PRE_BUG7156414
- Copy patch files to appropriate directories
$ cd [PATCH_TOP]/7156414/oracle/forms/handler
$ cp UICommon.class $ORACLE_HOME/forms60/java/oracle/forms/handler/UICommon.class
$ cp ComponentItem.class $ORACLE_HOME/forms60/java/oracle/forms/handler/ComponentItem.class
$ cp BlockScroller.class $ORACLE_HOME/forms60/java/oracle/forms/handler/BlockScroller.class
$ cp FormCanvas.class $ORACLE_HOME/forms60/java/oracle/forms/handler/FormCanvas.class
$ cp FormWindow.class $ORACLE_HOME/forms60/java/oracle/forms/handler/FormWindow.class
$ cd [PATCH_TOP]/7156414/oracle/forms/ui
$ cp VBean.class $ORACLE_HOME/forms60/java/oracle/forms/ui/VBean.class
- Regenerate Jar files
- Execute adadmin
- Select the "Generate Applications Files menu" option
- Select "Generate product JAR files"
- Do you wish to force regeneration of all jar files? => Yes
- Spot check that the JAR files have been generated by verifying the timestamp
$ cd $OA_JAVA/oracle/apps/fnd/jar
$ ll fndforms.jar fndewt.jar
4. Apply patch 6125732
- Unzip patch file + Apply patch
$ unzip p6125732_60828_LINUX.zip
$ cd 6125732
$ sh patch.sh
5. Apply patch 6857221
- Unzip patch file + Apply patch
$ unzip p6857221_60828_LINUX.zip
$ cd 6857221
$ sh patch.sh
- Relink f60webmx for Oracle Applications
$ adrelink.sh force=y "fnd f60webmx"
6. Apply patch 3830807
- Unzip patch file + Apply patch
$ unzip p3830807_8063_LINUX.zip
$ cd 3830807
$ ./patch.sh
- Relink all Applications executables:
adadmin -> "Maintain Applications Files" -> "Relink Applications programs"
7. Apply patch 4586086
- Unzip patch file
$ unzip p4586086_600_LINUX.zip
- Backup old file
$ cd $ORACLE_HOME/forms60/lib
$ mv env_forms60.mk env_forms60.mk.PRE_BUG4586086
- Copy patch file to the appropriate directory
$ cd [PATCH_HOME]/bug4586086
$ cp env_forms60.mk $ORACLE_HOME/forms60/lib
- Generate shared object + Relink f60webmx for apps
$ cd $ORACLE_HOME/forms60/lib
$ make -f cus_forms60w.mk libso_install
$ adrelink.sh force=y "fnd f60webmx"
8. Relink applications executables
- Run adadmin
- Select (2) "Maintain Applications Files Menu"
- Select (1) "Relink Applications programs"
- List of product to link: fnd
- Generate specific executables …: Yes
- Relink with debug: No
- Enter executables to relink: f60webmx ar60run ar60runb ar60rund
9. Apply patch 7343387 (Apps Interoperability)
- Unzip patch file
$ unzip p7343387_11i_GENERIC.zip
- Enable maintenance mode: adadmin -> (5) Change Maintenance Mode -> (1) Enable Maintenance Mode
- apply patch with adpatch
- Disable maintenance mode: adadmin -> (5) Change Maintenance Mode -> (2) Disable Maintenance Mode
10. Verify your upgrade
- Check the timestamp for the following files:
$ cd $OA_JAVA/oracle/apps/fnd/jar
$ ll fndforms.jar fndewt.jar
If the timestamp is not current - run adadmin => Maintain Applications Files => Generate Product JAR Files.
11. Start all applications processes (adstrtall.sh)
- You can also verify your upgrade by login to forms responsibility -> Help -> About Oracle Applications
You should see: Oracle Forms version : 6.0.8.28.0
Related - Note 125767.1 - Upgrading Developer 6i with Oracle Applications 11i.
Shailesh Gudimalla Oracle Apps DBA All Posting is my own workshop example,if you're using this then please check first in your test environment.
Tuesday, September 9, 2008
OracleAS 10g with the Oracle E-Business Suite
Integrating Oracle E-Business Suite Release 11i with Oracle Internet Directory and Oracle Single Sign-On
Purpose of Internet Directory instead of storing the information directly in an Oracle database
User identities and credentials
User profiles
User application preferences
Application authorization policies
Application-discovery information
Application- and service-specific management and configuration data, and
Network configuration and management policy data
What is Oracle Application Server?
Oracle Application Server provides the infrastructure to develop and deploy e-business portals, transactional applications, and Web services.
Oracle AS 10g includes Oracle Containers for J2EE (OC4J), Oracle HTTP Server (powered by Apache), Oracle JDeveloper, Oracle Forms, Oracle Identity Management, Oracle Portal, Oracle Business Intelligence, Oracle Business Integration, and Oracle WebCache.
Installing Oracle Application Server 10g with Oracle E-Business Suite Release 11i Doc ID: Note:233436.1
Integrate AS10g with Apps 11i.
Go to FND_TOP/bin and run below script. Its located in FND_TOP.
[applmgr@sys4 bin]$ txkrun.pl -script=SetSSOReg
Enter the host name where Oracle iAS Infrastructure database is installed ? sys38.doyen.in
Enter the Oracle iAS Infrastructure database port number ? 1521
Enter the Oracle iAS Infrastructure database SID ? test
Enter the LDAP Port on Oracle Internet Directory server ? 389
Enter Oracle E-Business apps database user password ? apps
Enter Oracle iAS Infrastructure database ORASSO schema password ? orasso
Enter Oracle E-Business SYSTEM database user password ? oracle
Enter E-Business Suite existing SSOSDK schema password or choose a password to use with the new SSOSDK schema if the schema does not exist ? SSOSDK
Enter the Oracle Internet Directory Administrator (orcladmin) Bind password ? welcome99
Enter the instance password that you would like to register this application instance with ? welcome99
*** ALL THE FOLLOWING FILES ARE REQUIRED FOR RESOLVING RUNTIME ERRORS
*** Log File = /oracle/app/apps/viscomn/rgf/VIS_sys4/sso/txkSetSSOReg_Fri_Jan_4_16_00_37_2008.log
Program : /oracle/app/apps/visappl/fnd/11.5.0/patch/115/bin/txkSetSSOReg.pl started @ Fri Jan 4 16:01:22 2008
*** Log File = /oracle/app/apps/viscomn/rgf/VIS_sys4/sso/txkSetSSOReg_Fri_Jan_4_16_00_37_2008.log
######################## WARNING ########################################
This application works with SSOSDK version 9.0.2 or higher. If lower version
(3.0.9) of SSOSDK was installed in your system and you have a registered
partner application, this process will remove the 3.0.9 version of the SSOSDK
schema and install the 9.0.2 version.
######################## WARNING ########################################
Beginning input parameter validation for SSO registration.
Beginning loading SSO SDK into database if necessary.
Loading of SSO SDK into database completed successfully.
Input parameters validation for OID registration completed.
BEGIN SSO REGISTRATION:
Beginning to register partner application.
Partner application has been registered successfully.
Single Sign-On partner application registered successfully.
BEGIN OID REGISTRATION:
Beginning to register Application and Service containers if necessary.
Application and Service containers were created successfully.
Beginning to register application in Oracle Internet Directory.
Registration of application in Oracle Internet Directory completed successfully.
Beginning to register instance password in Oracle Internet Directory.
Registration of instance password in Oracle Internet Directory completed successfully.
Beginning to test application registration in Oracle Internet Directory.
Testing of application registration in Oracle Internet Directory completed successfully.
Beginning to register provisioning profile in Oracle Internet Directory.
Registration of provisioning profile in Oracle Internet Directory completed successfully.
Application is now registered successfully with provisioning in Oracle Internet Directory.
End of /oracle/app/apps/visappl/fnd/11.5.0/patch/115/bin/txkSetSSOReg.pl : No Errors encountered
Once register sucessfully you can proceed below.
a. do an anonymous bind...
ldapbind -h sys38.doyen.in -p 389
b. do a superuser bind....
ldapbind -h sys38.doyen.in -p 389 -D "cn=orcladmin" -w welcome99
c. do an encrypted super user bind...
ldapbind -h sys38.doyen.in -p 389 -U 1 -D cn=orcladmin -w welcome99
d. do a specific user bind....for example:
ldapbind -h sys38.doyen.in -p 389 -D "cn=orcladmin,cn=users,dc=doyen,dc=in" -w welcome99
Exporting Application Accounts into Intermediate LDIF File
Determine which accounts to migrate
Applications SSO Login Types (APPS_SSO_LOCAL_LOGIN) – An account will not be migrated if the user level profile value of the account is ‘LOCAL’, i.e. the account is a local account.
Applications SSO LDAP Synchronization (APPS_SSO_LDAP_SYNC) -- An account will not be migrated if the user level profile value of the account is ‘N’, i.e. the account is marked to not to synchronize with Oracle Internet Directory.
Note: The site level profile value will be used in the cases where the user level profile value is not set.
Oracle E-Business Suite ships a number of standard accounts, such as SYSADMIN and GUEST. These accounts should not be migrated. To enforce this, the SYSADMIN and GUEST accounts are pre-seeded with Applications SSO Login Types (APPS_SSO_LOCAL_LOGIN) set to ‘LOCAL’ and Applications SSO LDAP Synchronization (APPS_SSO_LDAP_SYNC) set to ‘N’.
Administrators should check whether there are any additional accounts that should not be migrated, especially accounts with user_id less than 10 (check with: select user_name from FND_USER where user_id<10).>Use AppsUserExport to extract user information
For example:
java oracle.apps.fnd.oid.AppsUserExport \
-v \
-dbc $FND_TOP/secure/myebiz.dbc \
-o users.txt \
-pwd welcome \
-g \
-l users.log
The resulting data file and log file may contain confidential information, such as the start and end dates for a user’s account, and should therefore be secured appropriately.
java oracle.apps.fnd.oid.AppsUserExport -dbc /oracle/app/apps/visappl/fnd/11.5.0/secure/VIS_sys4/vis.dbc -o /oracle/app/apps/visappl/fnd/11.5.0/secure/VIS_sys4/vis01.out -pwd apps
User Export to /oracle/app/apps/visappl/fnd/11.5.0/secure/VIS_sys4/vis01.out
User Export to /oracle/app/apps/visappl/fnd/11.5.0/secure/VIS_sys4/vis01.out started..
User Export completed successfully. For further details please refer to log file at: /oracle/app/apps/visappl/fnd/11.5.0/secure/VIS_sys4/vis01.out.log
[oracle@sys38 ~]$ $ORACLE_HOME/bin/ldapsearch -h sys38 -p 389 -D "cn=orcladmin" -w welcome99 -b "cn=Provisioning Profiles, cn=Changelog Subscriber, cn=Oracle Internet Directory" -s sub "objectclass=*" > profiles.ldif
[oracle@sys38 ~]$ $ORACLE_HOME/bin/ldapsearch -h sys38 -p 389 -D "cn=orcladmin" -w welcome99 -s sub "orclguid=42E42E799F8C50F5E040A8C0260051FA" -b "" dn
orclApplicationCommonName=VIS,cn=EBusiness,cn=Products,cn=OracleContext,dc=doyen,dc=in
[oracle@sys38 ~]$ oidprovtool operation=disable ldap_host=sys38.doyen.in ldap_port=389 ldap_user_dn=cn=orcladmin ldap_user_password=welcome99 application_dn=orclApplicationCommonName=VIS,cn=EBusiness,cn=Products,cn=OracleContext,dc=doyen,dc=in profile_mode=BOTH
This Provisioning Profile is disabled.
Converting Intermediate LDIF File to Final LDIF File
Before performing loading data into Oracle Internet Directory, the Oracle Internet Directory administrator needs to ensure that:
The extracted data file is copied from the Oracle E-Business Suite instance to Oracle Internet Directory.
If the provisioning profile has been set up for the Oracle E-Business Suite instance and the profile mode is either OUTBOUND or BOTH
To convert the intermediate LDIF file to the final LDIF format:
. Use oidprovtool with operation=DISABLE to disable the profile before the migration is started.
For example:
oidprovtool operation=disable ldap_host=sys38.doyen.in ldap_port=389 ldap_user_dn=cn=orcladmin ldap_user_password=welcome99 application_dn=orclApplicationCommonName=VIS,cn=EBusiness,cn=Products,cn=OracleContext,dc=doyen,dc=in profile_mode=BOTH
After migration is complete, update the lastchangenumber attribute of the profile:
First, find the current last change number in Oracle Internet Directory with the ldapsearch command:
ldapsearch –h sys38.doyen.in -p welcome99 -D cn=oracladmin -w welcome99 -s base -b "" "objectclass=*" lastchangenumber=2623
Next, use the following command to update the lastchangenumber attribute to the number n that was discovered in the last step:
[oracle@sys38 bin]$ oidprovtool operation=MODIFY ldap_host=sys38.doyen.in ldap_port=389 ldap_user_dn=cn=orcladmin ldap_user_password=welcome99 application_dn=orclApplicationCommonName=VIS,cn=EBusiness,cn=Products,cn=OracleContext,dc=doyen,dc=in orclLastAppliedChangeNumber=2623
The Provisioning Profile for the Application has been modified.
3. Use oidprovtool with operation=ENABLE to enable the profile.
[oracle@sys38 bin]$ oidprovtool operation=enable ldap_host=sys38.doyen.in ldap_port=389 ldap_user_dn=cn=orcladmin ldap_user_password=welcome99 application_dn=orclApplicationCommonName=VIS,cn=EBusiness,cn=Products,cn=OracleContext,dc=doyen,dc=in profile_mode=BOTH
This Provisioning Profile is enabled.
4. The intermediate LDIF file created by AppsUserExport has two variables that an Oracle Internet Directory administrator needs to instantiate using the Oracle Internet Directory ldifmigrator utility:
[oracle@sys38 bin]$ ldifmigrator "input_file=/home/oracle/mig_user/vis01.out" "output_file=data.ldif" "s_UserContainerDN=cn=users,dc=doyen,dc=in" "s_UserNicknameAttribute=uid"
Migration of LDIF data completed. All the entries are successfully migrated
Loading Final LDIF file into Oracle Internet Directory
Once the final LDIF file has been generated, the user data is ready to be loaded into Oracle Internet Directory using the Oracle Internet Directory bulkload tool.
Before performing a bulk load:
1. Stop all OID processes before using the bulkload utility to load the LDIF file:
$ORACLE_HOME/opmn/bin/opmnctl stopall
Note the OID password, which should be the same as the instance and orcladmin passwords. You will be prompted for this when running the utility.
2. In case the oidmon or oidctl commands were used to manually start the oid proceses, you must make sure that they have stopped:
On Unix Run: $ORACLE_HOME/ldap/bin/ldapcheck
[oracle@sys38 bin]$ ./ldapcheck
Checking Oracle Internet Directory Processes ...ALL
Not Running ---- Process oidmon
Not Running ---- Process oidldapd
Not Running ---- Process oidrepld
Not Running ---- Process odisrv
No LDAP Processes are Running
3. If any other OID processes such as odisrv are still running, you must stop them manually using:
oidctl connect=test server=oidsrv instance=1 stop
You must ensure that no OID processes are running before continuing with the bulkload.sh command.
1. Run the bulkload utility with the -check and –generate options to verify that there are no duplicate users.
For example:
bulkload.sh –connect -check –generate
[oracle@sys38 bin]$ ./bulkload.sh -connect "test" -check -generate /home/oracle/orainfra/opmn/bin/data.ldif
Verifying node "test"
-----------------------------
This tool can only be executed if you know database user password
for OiD on test
Enter OiD password ::
------------------------------------------------------------------
Checking Internet Directory current schema state
------------------------------------------------------------------
-------------------------------------------------------------------
Checking and Generating Internet Directory data for bulk loading
-------------------------------------------------------------------
Schema Check Errors are logged in : /home/oracle/orainfra/ldap/log/bulkload.log
Bad Entries are logged in : /home/oracle/orainfra/ldap/load/badentry.ldif
Non-Unique Distinguished Names are logged in : /home/oracle/orainfra/ldap/log/duplicateDN.log
-------------------------------------------------------------------
Data Generated for bulk loading
-------------------------------------------------------------------
Please Remove the errors
[oracle@sys38 bin]$ ./bulkload.sh -connect "test" -check -generate /home/oracle/orainfra/opmn/bin/data.ldif
Verifying node "test"
-----------------------------
This tool can only be executed if you know database user password
for OiD on test
Enter OiD password ::
------------------------------------------------------------------
Checking Internet Directory current schema state
------------------------------------------------------------------
-------------------------------------------------------------------
Checking and Generating Internet Directory data for bulk loading
-------------------------------------------------------------------
No Schema Check Errors.
No Bad Entries found.
No Duplicate DN Entries.
-------------------------------------------------------------------
Data Generated for bulk loading
-------------------------------------------------------------------
2. Check the log file for duplicate users
If you get any Bad Entries and Duplicate DN Entries, Just remove those entries and run again setp 1.
3. If the log file indicates duplicate users, manually remove these users from the LDIF file.
4. Rerun Step 1 to verify all duplicates have been successfully removed.
5. Once all duplicates are removed, run the bulkload utility with the –load option to load the users.
For example:
bulkload.sh –connect –load
[oracle@sys38 bin]$ ./bulkload.sh -connect "test" -load /home/oracle/orainfra/opmn/bin/data.ldif
Verifying node "test"
-----------------------------
This tool can only be executed if you know database user password
for OiD on test
Enter OiD password ::
It is recommended to use -check option before generating/loading data
Do you want to continue (y/n?) [n]
y
Loading data on : "test"
===============================
------------------------------------------------------------------
Preparing Internet Directory schema for bulk data loading
------------------------------------------------------------------
------------------------------------------------------------------
Initiating bulk load...
------------------------------------------------------------------
Loading Attribute Search Catalogs..
battr_store001..
battr_store002..
battr_store003..
attr_store001..
attr_store002..
attr_store003..
c..
cn..
ctcaladmd..
ctcalcountry..
ctcalhost..
ctcalmobiletelephonetype..
ctcalorganization..
ctcalorgunit1..
ctcalorgunit2..
ctcalorgunit3..
ctcalorgunit4..
ctcalprmd..
ctcalpublishedtype..
ctcalresourcecapacity..
ctcalresourcenumber..
ctcalxitemid..
dc..
description..
employeenumber..
facsimiletelephonenumber..
generationqualifier..
givenname..
homephone..
initials..
krbprincipalname..
labeleduri..
l..
mail..
manager..
member..
middlename..
mobile..
name..
objectclass..
o..
orclaci..
orclcalendarhost..
orclcalendarresourcecapacity..
orclcalendarresourcenumber..
orclcalendarstore..
orclcertificatehash..
orclcertificatematch..
orclcommonkrbprincipalattribute..
orcldasispersonal..
orcldassearchable..
orcldasvalidatepwdreset..
orcldasviewable..
orcldbaqgeneric..
orcldbaqobjname..
orcldbaqobjowner..
orcldbaqobjtype..
orcldbaqpointerattr..
orcldbaqreglocation..
orcldbaqregnamespace..
orcldbaqregrejected..
orcldbaqregservers..
orcldbaqregsubscription..
orcldbaqregunreachable..
orcldbaqreguser..
orcldbdistinguishedname..
orcldbentroleassigned..
orcldbentuser..
orcldbglobalname..
orcldblscolumnname..
orcldblsfullname..
orcldblsgroupparent..
orcldblsnumerictag..
orcldbnativeuser..
orcldbroleoccupant..
orcldbservermember..
orcldbserverrole..
orcldbtargetuser..
orcldbtrusteddomain..
orcldbtrusteduser..
orclentrylevelaci..
orcleventtime..
orcleventtype..
orclglobalid..
orclguid..
orclhostname..
orclipaddress..
orclisenabled..
orclisvisible..
orcljazncodebase..
orcljaznjavaclass..
orcljaznpermissionactions..
orcljaznpermissiontarget..
orcljaznprincipal..
orcljaznrealmisexternal..
orcljaznsigner..
orcljaznsubscriberdn..
orclldapinstanceid..
orclldapprocessid..
orclmailaci..
orclmailaddresscategory..
orclmailemail..
orclmailfolderdn..
orclmailgroupadminmailid..
orclmailgrouphasarchive..
orclmailgroupisexternal..
orclmaillistsuspendedmember..
orclmailnewsfoldercreatetime..
orclmailnntpactivegroup..
orclmailnntplocalgroup..
orclmailnntpmoderatedgroup..
orclmailowner..
orclmailpublicdisplayname..
orclmailrenamedsharedfolder..
orclmailrulescope..
orclmailstore..
orclmailstoredn..
orclmailuserdldn..
orclnethostname..
orclnetservicename..
orclnewsgroupdn..
orclnormdn..
orclobjectguid..
orclodipagentname..
orclodipprofileexecgroupid..
orclodipprofilename..
orclownerguid..
orclrealmname..
orclreplicadn..
orclresourcename..
orclresourcetypename..
orclsamaccountname..
orclsecondaryuid..
orclservicemember..
orclservicesubtype..
orclservicetype..
orclstatus..
orclsuitetype..
orclumattendantextension..
orclumdeviceaddress..
orclumlocale..
orclumnamehash..
orcluserapplnprovstatus..
orcluserdn..
orclwirelessaccountnumber..
ou..
owner..
pager..
personalmobile..
personalpager..
postalcode..
pwdaccountlockedtime..
sn..
st..
street..
targetdn..
telephonenumber..
title..
uid..
uniquemember..
vpimmail..
x509issuer..
Loading Distinguished Name Catalog..
------------------------------------------------------------------
Performing post bulk load processing for Internet Directory schema
------------------------------------------------------------------
------------------------------------------------------------------
Creating Indexes ...
------------------------------------------------------------------
-------------------------------------------------------------
Verifying Index creation ...
-------------------------------------------------------------
All indexes created successfully
-------------------------------------------------------------
Index creation verification Done ...
-------------------------------------------------------------
-------------------------------------------------------------
Altering Index ...
-------------------------------------------------------------
-------------------------------------------------------------
Altering Index Done ...
-------------------------------------------------------------
------------------------------------------------------------------
Generating Database Statistics ...
------------------------------------------------------------------
-------------------------------------------------------------
Done.
-------------------------------------------------------------
Migrating Existing Accounts from Oracle Internet Directory to Oracle E-Business Suite Release 11i
The LDAPUserImport command-line utility takes an LDIF file generated from Oracle Internet Directory, and inserts appropriate data into the E-Business Suite schema. It can be used for bulk migration of existing accounts from Oracle Internet Directory to Oracle E-Business Suite. LDAPUserImport updates both FND and TCA schema.
Export Oracle Internet Directory users into LDIF file Using ldifwrite
The Oracle Internet Directory ldifWrite command-line utility is used to create an LDIF file that can be loaded into the E-Business Suite schema via the LDAPUserImport command-line utility.
General Syntax:
ldifwrite –c -b -f
Example:
ldifwrite -c test -b "cn=Users,dc=doyen,dc=in" -f output.ldif
[oracle@sys38 bin]$ ldifwrite -c test -b "cn=Users,dc=doyen,dc=in" -f output.ldif
This tool can only be executed if you know database user password for OiD
Enter OiD Password ::
------------------------------------------------------------
Reading entries under BaseDN "cn=users,dc=doyen,dc=in"...
-------------------------------------------------------------
------------------------------------------------------------
1872 Entries are written to "output.ldif".
------------------------------------------------------------
There is no need to modify the output file output.ldif in any way before proceeding with Task 2.
Task 2: Import LDAP Users into Oracle E-Business Suite using LDAPUserImport
The LDAPUserImport tool is invoked from the command line.
1. Ensure the environment is set up properly: $APPL_TOP/java must be in the CLASSPATH environment variable),
2. Invoke the LDAPUserImport tool with the following syntax:
java oracle.apps.fnd.oid.LDAPUserImport \
-v \
-dbc $FND_TOP/secure/myebiz.dbc \
-f users.ldif \
-n uid \
-l users.log
For example:
[applmgr@sys4 VIS_sys4]$ java oracle.apps.fnd.oid.LDAPUserImport -v -dbc /oracle/app/apps/visappl/fnd/11.5.0/secure/VIS_sys4/vis.dbc -f /oracle/app/apps/visappl/fnd/11.5.0/secure/VIS_sys4/output.ldif -n uid -l ouput.log
LDAP user import from /oracle/app/apps/visappl/fnd/11.5.0/secure/VIS_sys4/output.ldif started..
LDAP user import completed sucessfully. For further details refer to log file at ouput.log
PatchSet:
1. 11i.ATG_PF.H.delta.6 (RUP 5) or above.
2. 6117031 - 11i.ATG_PF.H RUP6 SSO 10g Integration,
Check and apply all the prerequisites.
Important Metalink Documents
186981.1 : Frequently Asked Questions
293849.1 : Roadmap: Using OracleAS 10g with the Oracle E-Business Suite (Overview Presentation)
233436.1 : OracleAS 10g + E-Business Suite Installation Guide
261914.1 : Integrating Oracle E-Business Suite Release 11i with Oracle Internet Directory and Oracle Single Sign-On
305918.1: Portal 10g + E-Business Suite Installation Guide
313418.1: Discoverer 10g + E-Business Suite Installation Guide
306653.1: Web Cache 10g + E-Business Suite Installation Guide
223927.1 : Oracle Application Server Integration with Oracle E-Business Suite: Statement of Direction
Wednesday, August 6, 2008
Concurrent Manager : troubleshooting
Summary of Possible Reasons and Solutions for the Problem Where All Concurrent Requests Stuck in Pending Phase
Below are several different possible solutions to the problem where concurrent
requests are stuck in pending status:
1. When shutting down the concurrent manager are there any FNDLIBR processes still running at the OS level? If so, do a kill -9 on them. Then restart the concurrent manager.
2. Try Relinking $FND_TOP.
3. Rebuild the concurrent manager views. As applmgr run the following from
the OS:
This is non-destructive. Concurrent Manager views can be rebuild by running the following command at the command line:
Ensure that concurrent manager is shutdown.
FNDLIBR FND FNDCPBWV apps/apps SYSADMIN 'System Administrator' SYSADMIN
restart the concurrent mgr.
4. Another possibility is that the Profile Option "Concurrent: OPS Request Partitioning" is set to OFF (by default). Unless Concurrent OPS is being used, the setting for this profile option should be NULL.
5. Yet another possibility is that System Profile Option: Concurrent Active
Requests is set to 0.
1. Log into Oracle Applications as SYSADMIN.
2. Select System Administrator responsibility.
3. Navigate to PROFILE --> SYSTEM.
4. Query for %CONC%ACTIVE%.
5. Change the profile option for Concurrent: Active Request Limit to Null (blank).
6. Exit Oracle Applications and log in again for the change to take affect.
7. Run a new concurrent request.
6. Another possibility is that Concurrent managers were brought down, while an
outstanding request was still running in the background. In which case, Update
the FND_CONCURRENT_REQUESTS table as follows:
.
sql> update fnd_concurrent_requests
set status_code='X', phase_code='C'
where status_code='T';
sql> commit;
7. The control_code for concurrent_queue_name = 'FNDCRM' is 'N' in the FND_CONCURRENT_QUEUES table, which means 'Target node/queue unavailable'. This value should be NULL (CRM is running; target and actual process amount are the same), or 'A' ('Activate concurrent manager' control status).
Set the control_code to 'A' in fnd_concurrent_queues for the Conflict Resolution Manager:
1. Logon to Oracle Applications database server as 'applmgr'.
2. Verify the Applications environment is setup correctly ($ORACLE_HOME and $ORACLE_SID).
3. Logon to SQL*Plus as 'APPS' and run the following SQL statement:
update fnd_concurrent_queues
set control_code = 'A'
where concurrent_queue_name = 'FNDCRM';
commit;
4. Verify the status of the concurrent managers through the
Concurrent -> Manager -> Administer form.
If the CRM is still not active, bounce (deactivate, activate) the Internal Concurrent Manager. This is done through the Concurrent -> Manager ->
Administer form from the 'System Administrator' responsibility. It can also be done through the CONCSUB command at the command level.
Setting the control_code to 'A' in the fnd_concurrent_queues table for the Conflict Resolution Manager indicates that this concurrent manager is to be activated with the parameter values specified through this table for this manager (MAX_PROCESSES, CACHE_SIZE, etc).
8. What is the cache size? Try increasing it then bounce the concurrent manager.
If concurrent requests are rarely prioritized and there are managers that service short-running requests, consider setting the cache size to equal at least twice the number of target processes. This increases the throughput of the concurrent manaagers by attempting to avoid any sleep time. For example, if more than one manager or worker processes the same type of requests with only a small cache size, it may be unable to process any jobs in a single processing cycle, because other processes have already run the cached requests. When this happens, it is important to note that the manager will sleep before refreshign its cache. To increase manager throughput where there are sufficient requests of the required type in the queue, increase the cache size to improve the chance of the manager finding work to process and thus avoid having to enter a sleep phase.
TIP: Ensure that the system is not resource-constrained before attempting to increase the rate of concurrent processing in this way; otherwise, these changes may actually reduce concurrent processing throughput because jobs take longer to run..
Enter the number of requests your manager remembers each time it reads which requests to run. For example, if a manager's workshift has 1 target process and a cache value of 3, it will read three requests,, and will wait until these three requests have been run before reading new requests.
In reading requests, the manager will only put requests it is allowed to run into its cache. For example, if you have defined your manager to run only Order Entry reports then the manager will put only Order Entry requests into its cache.
If you enter 1, the concurrent manager must look at its requests list each time it is ready to process another request. By setting the cache size at a higher number, the concurrent manager does not have to read its requests list each time it runs a request. However, the manager does not recognizea nay priority changes you make for a particular request if it has already read that request into its cache. Further, even if you give a higher priority to a new request, that new request must wait until the buffer isempty and the manager returns to look at the requests list. That request may have to wait a long time if you set the buffer size to a high number.
You should use cache size to tune your concurrent managers to work most efficiently for you site's needs. If your organization tends to reprioritize jobs going to a certain manager, that manager should have its buffer size set fairly low.
*Suggestion: *Enter a value of 1 when defining a manager that runs long, time-consuming jobs, and a value of 3 or 4 for managers that run small, quick jobs.
9. Please check the sleep seconds set for the concurrent manager which runs the report that is taking long time for completion. Reducing the sleep time will improve performance.
1. Check for the value set for the sleep seconds for the concurrent manager using the following path: System Administrator Responsibilty -> Concurrent -> Manager -> Define.
2. Check the processes running for the concurent manager using the following command:
ps -ef | grep 'INVLIBR'
As all concurrent programs are dealt by INVLIBR, the number of processes returned here must tally with the value specified for the processes defined for the concurrent manager.
3. Also, check for the duration for which the processes are sleeping. Reducing the value assigned for it would improve performance.
As a workaround to improve performance, you could change the priority of concurent request.
Explanation
-----------
The sleep state would be assigned to some tasks when the program running it has to handle more tasks than it has been configured to process. For example, if the number of processes has been defined as say 10, then at any point of time there is a provision to run 10 tasks. Now say, 12 tasks arrive for the program, then time slots are alloted for 10 and the rest 2 are put to sleep. So, if the concurrent program running the problem report is handling larger number of processes the sleep and run behaviour can be observed.
Below are several different possible solutions to the problem where concurrent
requests are stuck in pending status:
1. When shutting down the concurrent manager are there any FNDLIBR processes still running at the OS level? If so, do a kill -9 on them. Then restart the concurrent manager.
2. Try Relinking $FND_TOP.
3. Rebuild the concurrent manager views. As applmgr run the following from
the OS:
This is non-destructive. Concurrent Manager views can be rebuild by running the following command at the command line:
Ensure that concurrent manager is shutdown.
FNDLIBR FND FNDCPBWV apps/apps SYSADMIN 'System Administrator' SYSADMIN
restart the concurrent mgr.
4. Another possibility is that the Profile Option "Concurrent: OPS Request Partitioning" is set to OFF (by default). Unless Concurrent OPS is being used, the setting for this profile option should be NULL.
5. Yet another possibility is that System Profile Option: Concurrent Active
Requests is set to 0.
1. Log into Oracle Applications as SYSADMIN.
2. Select System Administrator responsibility.
3. Navigate to PROFILE --> SYSTEM.
4. Query for %CONC%ACTIVE%.
5. Change the profile option for Concurrent: Active Request Limit to Null (blank).
6. Exit Oracle Applications and log in again for the change to take affect.
7. Run a new concurrent request.
6. Another possibility is that Concurrent managers were brought down, while an
outstanding request was still running in the background. In which case, Update
the FND_CONCURRENT_REQUESTS table as follows:
.
sql> update fnd_concurrent_requests
set status_code='X', phase_code='C'
where status_code='T';
sql> commit;
7. The control_code for concurrent_queue_name = 'FNDCRM' is 'N' in the FND_CONCURRENT_QUEUES table, which means 'Target node/queue unavailable'. This value should be NULL (CRM is running; target and actual process amount are the same), or 'A' ('Activate concurrent manager' control status).
Set the control_code to 'A' in fnd_concurrent_queues for the Conflict Resolution Manager:
1. Logon to Oracle Applications database server as 'applmgr'.
2. Verify the Applications environment is setup correctly ($ORACLE_HOME and $ORACLE_SID).
3. Logon to SQL*Plus as 'APPS' and run the following SQL statement:
update fnd_concurrent_queues
set control_code = 'A'
where concurrent_queue_name = 'FNDCRM';
commit;
4. Verify the status of the concurrent managers through the
Concurrent -> Manager -> Administer form.
If the CRM is still not active, bounce (deactivate, activate) the Internal Concurrent Manager. This is done through the Concurrent -> Manager ->
Administer form from the 'System Administrator' responsibility. It can also be done through the CONCSUB command at the command level.
Setting the control_code to 'A' in the fnd_concurrent_queues table for the Conflict Resolution Manager indicates that this concurrent manager is to be activated with the parameter values specified through this table for this manager (MAX_PROCESSES, CACHE_SIZE, etc).
8. What is the cache size? Try increasing it then bounce the concurrent manager.
If concurrent requests are rarely prioritized and there are managers that service short-running requests, consider setting the cache size to equal at least twice the number of target processes. This increases the throughput of the concurrent manaagers by attempting to avoid any sleep time. For example, if more than one manager or worker processes the same type of requests with only a small cache size, it may be unable to process any jobs in a single processing cycle, because other processes have already run the cached requests. When this happens, it is important to note that the manager will sleep before refreshign its cache. To increase manager throughput where there are sufficient requests of the required type in the queue, increase the cache size to improve the chance of the manager finding work to process and thus avoid having to enter a sleep phase.
TIP: Ensure that the system is not resource-constrained before attempting to increase the rate of concurrent processing in this way; otherwise, these changes may actually reduce concurrent processing throughput because jobs take longer to run..
Enter the number of requests your manager remembers each time it reads which requests to run. For example, if a manager's workshift has 1 target process and a cache value of 3, it will read three requests,, and will wait until these three requests have been run before reading new requests.
In reading requests, the manager will only put requests it is allowed to run into its cache. For example, if you have defined your manager to run only Order Entry reports then the manager will put only Order Entry requests into its cache.
If you enter 1, the concurrent manager must look at its requests list each time it is ready to process another request. By setting the cache size at a higher number, the concurrent manager does not have to read its requests list each time it runs a request. However, the manager does not recognizea nay priority changes you make for a particular request if it has already read that request into its cache. Further, even if you give a higher priority to a new request, that new request must wait until the buffer isempty and the manager returns to look at the requests list. That request may have to wait a long time if you set the buffer size to a high number.
You should use cache size to tune your concurrent managers to work most efficiently for you site's needs. If your organization tends to reprioritize jobs going to a certain manager, that manager should have its buffer size set fairly low.
*Suggestion: *Enter a value of 1 when defining a manager that runs long, time-consuming jobs, and a value of 3 or 4 for managers that run small, quick jobs.
9. Please check the sleep seconds set for the concurrent manager which runs the report that is taking long time for completion. Reducing the sleep time will improve performance.
1. Check for the value set for the sleep seconds for the concurrent manager using the following path: System Administrator Responsibilty -> Concurrent -> Manager -> Define.
2. Check the processes running for the concurent manager using the following command:
ps -ef | grep 'INVLIBR'
As all concurrent programs are dealt by INVLIBR, the number of processes returned here must tally with the value specified for the processes defined for the concurrent manager.
3. Also, check for the duration for which the processes are sleeping. Reducing the value assigned for it would improve performance.
As a workaround to improve performance, you could change the priority of concurent request.
Explanation
-----------
The sleep state would be assigned to some tasks when the program running it has to handle more tasks than it has been configured to process. For example, if the number of processes has been defined as say 10, then at any point of time there is a provision to run 10 tasks. Now say, 12 tasks arrive for the program, then time slots are alloted for 10 and the rest 2 are put to sleep. So, if the concurrent program running the problem report is handling larger number of processes the sleep and run behaviour can be observed.
Wednesday, July 30, 2008
Access Oracle Apps R12 / 11i from Linux Client (Mozilla Firefox)
In Oracle Applications professional Users can access professional forms via Appletin web browser. This Form Applet must run with in Java Virtual Machine (JVM) and Oracle bundles its own JVM as Oracle Jinitiator. This Jinitiator is available only for Windows Client and for Unix/Linux you have to use Java Plug-In.
Till Oracle Apps 11i default JVM was Jinitiator but with Oracle Apps R12 default JVM under which form Applet run is J2SE Plug-In. If you are accessing Oracle Applications (11i/R12), Apps will automatically prompt you to install Jinitiator/J2SE Plug-in (If Jinitiator/J2SE is not installed in client machine) but if you are accessing same Oracle Applications from Linux/Unix it does not prompt to install plug-in and you can’t apps forms from Linux client.
How to access Oracle Apps 11i/R12 professional forms from Linux Client ?
In you to access forms from Linux client, Three steps are installed (You can skip first if Mozilla is installed on your Linux client) –
1. Install Mozilla Browser
2. Install JRE on client machine (JRE version to install will depend on Server configuration, for R 12.0.o you need JRE 5 update 10) .
3. Use JRE installed above on client machine in Browser (Mozilla) Plugin
1. Install FireFox Mozilla
–Download Mozilla for Linux from http://www.mozilla.com/en-US/firefox/all.html#en firefox-2.0.0.7.tar.gz
– “gunzip -d firefox-2.0.0.7.tar.gz” (You will get unzipped file with name as firefox-2.0.0.7.tar)
– Extract tar file as “tar -xvf firefox-2.0.0.7.tar”
– This will create directory called “firefox” which is under you will see executable called “firefox“; Use this executable to start FireFox on Linux machine.
2. Install JRE on client machine
–Download JRE 5.0 Update 10 for Linux from http://java.sun.com/products/archive/j2se/5.0_10/index.html ”jre-1_5_0_10-linux-i586-rpm.bin”
–”chmod 755 jre-1_5_0_10-linux-i586-rpm.bin”
–./jre-1_5_0_10-linux-i586-rpm.bin (You will be asked to accept license agreement , click enter and when prompted to accept license enter Yes)
–This will install jre 1.5.10 in linux machine under /usr/java and plugin is installed under /usr/java/jre1.5.0_10/plugin/i386/ns7/libjavaplugin_oji.so
Configure JRE Plug-in in browser
–Go to Mozilla FireFox plug-in directory which is $location_where_you_unziped_firefox_directory/plugins and create soft link like
–ln -s /usr/java/jre1.5.0_10/plugin/i386/ns7/libjavaplugin_oji.so ./libjavaplugin_oji.so
Till Oracle Apps 11i default JVM was Jinitiator but with Oracle Apps R12 default JVM under which form Applet run is J2SE Plug-In. If you are accessing Oracle Applications (11i/R12), Apps will automatically prompt you to install Jinitiator/J2SE Plug-in (If Jinitiator/J2SE is not installed in client machine) but if you are accessing same Oracle Applications from Linux/Unix it does not prompt to install plug-in and you can’t apps forms from Linux client.
How to access Oracle Apps 11i/R12 professional forms from Linux Client ?
In you to access forms from Linux client, Three steps are installed (You can skip first if Mozilla is installed on your Linux client) –
1. Install Mozilla Browser
2. Install JRE on client machine (JRE version to install will depend on Server configuration, for R 12.0.o you need JRE 5 update 10) .
3. Use JRE installed above on client machine in Browser (Mozilla) Plugin
1. Install FireFox Mozilla
–Download Mozilla for Linux from http://www.mozilla.com/en-US/firefox/all.html#en firefox-2.0.0.7.tar.gz
– “gunzip -d firefox-2.0.0.7.tar.gz” (You will get unzipped file with name as firefox-2.0.0.7.tar)
– Extract tar file as “tar -xvf firefox-2.0.0.7.tar”
– This will create directory called “firefox” which is under you will see executable called “firefox“; Use this executable to start FireFox on Linux machine.
2. Install JRE on client machine
–Download JRE 5.0 Update 10 for Linux from http://java.sun.com/products/archive/j2se/5.0_10/index.html ”jre-1_5_0_10-linux-i586-rpm.bin”
–”chmod 755 jre-1_5_0_10-linux-i586-rpm.bin”
–./jre-1_5_0_10-linux-i586-rpm.bin (You will be asked to accept license agreement , click enter and when prompted to accept license enter Yes)
–This will install jre 1.5.10 in linux machine under /usr/java and plugin is installed under /usr/java/jre1.5.0_10/plugin/i386/ns7/libjavaplugin_oji.so
Configure JRE Plug-in in browser
–Go to Mozilla FireFox plug-in directory which is $location_where_you_unziped_firefox_directory/plugins and create soft link like
–ln -s /usr/java/jre1.5.0_10/plugin/i386/ns7/libjavaplugin_oji.so ./libjavaplugin_oji.so
Oracle Apps on Mozilla Firefox
You actually don't need to install JInitiator (jinit 1.3.1.21) to run Oracle Applications on Firefox if you already installed the Sun JRE 1.4.2 and above. You will need to edit pluginreg.dat
On Windows, that file is located at %APPDATA%\Mozilla\Firefox. Make a copy of the existing one first in case something goes wrong.
Search for NPJava14.dll because Oracle runs on Java 1.4. This will appear whether you have installed Java 5 or 6.
You will need to add the following line to at the end of the plugins.
6|application/x-jinit-applet;version=1.3.1.21|Java||$
Then update the count at the top of the section. Your modified pluginreg.dat will look like:
C:\Program Files\Java\jre1.5.0_09\bin\NPJava14.dll|$
|$
1160594743000|1|5|$
Java Plug-in 1.5.0_09 for Netscape Navigator (DLL Helper)|$
Java(TM) 2 Platform Standard Edition 5.0 Update 9|$
7
0|application/x-java-applet;version=1.4.2|Java Applet||$
1|application/x-java-bean;version=1.4.2|JavaBeans||$
2|application/x-java-applet;version=1.4.1|Java Applet||$
3|application/x-java-bean;version=1.4.1|JavaBeans||$
4|application/x-java-applet;version=1.5|Java Applet||$
5|application/x-java-bean;version=1.5|JavaBeans||$
6|application/x-jinit-applet;version=1.3.1.21|Java||$
Just replace the | with : if you're in Linux. Run Firefox and you're good to go.
On Windows, that file is located at %APPDATA%\Mozilla\Firefox. Make a copy of the existing one first in case something goes wrong.
Search for NPJava14.dll because Oracle runs on Java 1.4. This will appear whether you have installed Java 5 or 6.
You will need to add the following line to at the end of the plugins.
6|application/x-jinit-applet;version=1.3.1.21|Java||$
Then update the count at the top of the section. Your modified pluginreg.dat will look like:
C:\Program Files\Java\jre1.5.0_09\bin\NPJava14.dll|$
|$
1160594743000|1|5|$
Java Plug-in 1.5.0_09 for Netscape Navigator (DLL Helper)|$
Java(TM) 2 Platform Standard Edition 5.0 Update 9|$
7
0|application/x-java-applet;version=1.4.2|Java Applet||$
1|application/x-java-bean;version=1.4.2|JavaBeans||$
2|application/x-java-applet;version=1.4.1|Java Applet||$
3|application/x-java-bean;version=1.4.1|JavaBeans||$
4|application/x-java-applet;version=1.5|Java Applet||$
5|application/x-java-bean;version=1.5|JavaBeans||$
6|application/x-jinit-applet;version=1.3.1.21|Java||$
Just replace the | with : if you're in Linux. Run Firefox and you're good to go.
Monday, July 21, 2008
Manual Database Creation steps for Single-Instance.
Oracle RAC
=====================================================
Here are the steps to be followed:
1. Make a init.ora in your $ORACLE_HOME/dbs directory. On Windows this
file is in $ORACLE_HOME\database. To simplify, you can copy init.ora to
init.ora and modify the file.
*** Path names, file names, and sizes will need to be modified
Example parameter settings :
db_block_size=8192
db_cache_size=52428800
background_dump_dest=/u01/32bit/app/oracle/product/9.0.1/rdbms/log
core_dump_dest=/u01/32bit/app/oracle/product/9.0.1/rdbms/log
user_dump_dest=/u01/32bit/app/oracle/product/9.0.1/rdbms/log
timed_statistics=TRUE
control_files=("/u01/rbdb1/control_01.ctl", "/u01/rbdb1/control_02.ctl")
db_name=rbdb1
shared_pool_size=52428800
sort_area_size=524288
undo_management=AUTO
undo_tablespace=UNDOTBS
** You can also use an spfile as described in Note 162491.1.
2. Run the following sqlplus command to connect to the database:
sqlplus '/ as sysdba'
3. Startup up the database in NOMOUNT mode:
SQL> startup nomount
4. Create the Database :
*** Path names, file names, and sizes will need to be modified
CREATE DATABASE
MAXLOGFILES 255
MAXINSTANCES 1
MAXDATAFILES 256
MAXLOGHISTORY 256
DATAFILE '/u01/oracle/rbdb1/system_01.dbf' SIZE 400M REUSE
UNDO TABLESPACE "UNDOTBS" DATAFILE '/u01/oracle/rbdb1/undotbs_01.dbf'
SIZE 200M REUSE AUTOEXTEND ON NEXT 5120K MAXSIZE UNLIMITED
CHARACTER SET US7ASCII
LOGFILE GROUP 1 ('/u01/oracle/rbdb1/redo1_01.dbf') SIZE 100M REUSE,
GROUP 2 ('/u01/oracle/rbdb1/redo1_02.dbf') SIZE 100M REUSE;
5. Create a Users Tablespace :
*** Path names, file names, and sizes will need to be modified
CREATE TABLESPACE "USERS" DATAFILE '/u01/oracle/rbdb1/users01.dbf'
SIZE 300M REUSE AUTOEXTEND ON
NEXT 5M MAXSIZE 1500M;
6. Create a Temporary Tablespace :
*** Path names, file names, and sizes will need to be modified
CREATE TEMPORARY TABLESPACE "TEMP" TEMPFILE '/u01/oracle/rbdb1/temp_01.dbf'
SIZE 40M REUSE AUTOEXTEND ON NEXT 640K MAXSIZE UNLIMITED
EXTENT MANAGEMENT LOCAL;
ALTER DATABASE DEFAULT TEMPORARY TABLESPACE "TEMP";
7. Run the scripts necessary to build views, synonyms, etc. :
The primary scripts that you must run are:
i> CATALOG.SQL-- creates the views of data dictionary tables and the
dynamic performance views.
ii> CATPROC.SQL-- establishes the usage of PL/SQL functionality and
creates many of the PL/SQL Oracle supplied packages.
==============================================================
Manual Database Creation steps for Real Application Clusters
==============================================================
Here are the steps to be followed to create a Real Application Clusters database:
1. Make a init.ora in your $ORACLE_HOME/dbs directory. On Windows this
file is in $ORACLE_HOME\database. To simplify, you can copy init.ora to
init.ora and modify the file. Remember that your control file must
be pointing to a pre-existing raw device or cluster file system location.
*** Path names, file names, and sizes will need to be modified
Example parameter settings for the first instance:
Cluster-Wide Parameters for Database "RAC":
db_block_size=8192
db_cache_size=52428800
background_dump_dest=/u01/32bit/app/oracle/product/9.0.1/rdbms/log
core_dump_dest=/u01/32bit/app/oracle/product/9.0.1/rdbms/log
user_dump_dest=/u01/32bit/app/oracle/product/9.0.1/rdbms/log
timed_statistics=TRUE
control_files=("/dev/RAC/control_01.ctl", "/dev/RAC/control_02.ctl")
db_name=RAC
shared_pool_size=52428800
sort_area_size=524288
undo_management=AUTO
cluster_database=true
cluster_database_instances=2
remote_listener=LISTENERS_RAC
Instance Specific Parameters for Instance "RAC1":
instance_name=RAC1
instance_number=1
local_listener=LISTENER_RAC1
thread=1
undo_tablespace=UNDOTBS
* The local_listener parameter requires that you first add the listener
address to the TNSNAMES.ORA - remember to do so on both Node 1 and Node 2.
** You can also use an spfile as described in Note 136327.1.
2. Run the following sqlplus command to connect to the database:
sqlplus '/ as sysdba'
3. Startup up the database in NOMOUNT mode:
SQL> startup nomount
4. Create the Database (All raw devices must be pre-created) :
*** Path names, file names, and sizes will need to be modified
CREATE DATABASE
CONTROLFILE REUSE
MAXDATAFILES 254
MAXINSTANCES 32
MAXLOGHISTORY 100
MAXLOGMEMBERS 5
MAXLOGFILES 64
DATAFILE '/dev/RAC/system_01_400.dbf' SIZE 400M
REUSE AUTOEXTEND ON NEXT 10240K MAXSIZE UNLIMITED
UNDO TABLESPACE "UNDOTBS" DATAFILE
'/dev/RAC/undotbs_01_210.dbf' SIZE 200M REUSE
NEXT 5120K MAXSIZE UNLIMITED
CHARACTER SET US7ASCII
LOGFILE GROUP 1 ('/dev/RAC/redo1_01_100.dbf') SIZE 100M REUSE,
GROUP 2 ('/dev/RAC/redo1_02_100.dbf') SIZE 100M REUSE;
5. Create a Users Tablespace:
*** Path names, file names, and sizes will need to be modified
CREATE TABLESPACE "USERS" LOGGING DATAFILE
'/dev/RAC/users_01_125.dbf' SIZE 120M REUSE
NEXT 1280K MAXSIZE UNLIMITED EXTENT MANAGEMENT LOCAL;
6. Create a Temporary Tablespace:
*** Path names, file names, and sizes will need to be modified
CREATE TEMPORARY TABLESPACE "TEMP" TEMPFILE
'/dev/RAC/temp_01_50.dbf' SIZE 40M REUSE
7. Create a 2nd Undo Tablespace:
*** Path names, file names, and sizes will need to be modified
CREATE UNDO TABLESPACE "UNDOTBS2" DATAFILE
'/dev/RAC/undotbs_02_210.dbf' SIZE 200M REUSE
NEXT 5120K MAXSIZE UNLIMITED;
8. Run the necessary scripts to build views, synonyms, etc.:
The primary scripts that you must run are:
i> CATALOG.SQL--creates the views of data dictionary tables and the
dynamic performance views
ii> CATPROC.SQL--establishes the usage of PL/SQL functionality and
creates many of the PL/SQL Oracle supplied packages
iii> CATPARR.SQL--creates RAC specific views
9. Edit init.ora and set appropriate values for the 2nd instance on the
2nd Node:
*** Names may need to be modified
instance_name=RAC2
instance_number=2
local_listener=LISTENER_RAC2
thread=2
undo_tablespace=UNDOTBS2
10. From the first instance, run the following command:
*** Path names, file names, and sizes will need to be modified
alter database
add logfile thread 2
group 3 ('/dev/RAC/redo2_01_100.dbf') size 100M,
group 4 ('/dev/RAC/redo2_02_100.dbf') size 100M;
alter database enable public thread 2;
12. Start the second Instance. (Assuming that your cluster configuration
is up and running).
=====================================================
Here are the steps to be followed:
1. Make a init
file is in $ORACLE_HOME\database. To simplify, you can copy init.ora to
init
*** Path names, file names, and sizes will need to be modified
Example parameter settings :
db_block_size=8192
db_cache_size=52428800
background_dump_dest=/u01/32bit/app/oracle/product/9.0.1/rdbms/log
core_dump_dest=/u01/32bit/app/oracle/product/9.0.1/rdbms/log
user_dump_dest=/u01/32bit/app/oracle/product/9.0.1/rdbms/log
timed_statistics=TRUE
control_files=("/u01/rbdb1/control_01.ctl", "/u01/rbdb1/control_02.ctl")
db_name=rbdb1
shared_pool_size=52428800
sort_area_size=524288
undo_management=AUTO
undo_tablespace=UNDOTBS
** You can also use an spfile as described in Note 162491.1.
2. Run the following sqlplus command to connect to the database:
sqlplus '/ as sysdba'
3. Startup up the database in NOMOUNT mode:
SQL> startup nomount
4. Create the Database :
*** Path names, file names, and sizes will need to be modified
CREATE DATABASE
MAXLOGFILES 255
MAXINSTANCES 1
MAXDATAFILES 256
MAXLOGHISTORY 256
DATAFILE '/u01/oracle/rbdb1/system_01.dbf' SIZE 400M REUSE
UNDO TABLESPACE "UNDOTBS" DATAFILE '/u01/oracle/rbdb1/undotbs_01.dbf'
SIZE 200M REUSE AUTOEXTEND ON NEXT 5120K MAXSIZE UNLIMITED
CHARACTER SET US7ASCII
LOGFILE GROUP 1 ('/u01/oracle/rbdb1/redo1_01.dbf') SIZE 100M REUSE,
GROUP 2 ('/u01/oracle/rbdb1/redo1_02.dbf') SIZE 100M REUSE;
5. Create a Users Tablespace :
*** Path names, file names, and sizes will need to be modified
CREATE TABLESPACE "USERS" DATAFILE '/u01/oracle/rbdb1/users01.dbf'
SIZE 300M REUSE AUTOEXTEND ON
NEXT 5M MAXSIZE 1500M;
6. Create a Temporary Tablespace :
*** Path names, file names, and sizes will need to be modified
CREATE TEMPORARY TABLESPACE "TEMP" TEMPFILE '/u01/oracle/rbdb1/temp_01.dbf'
SIZE 40M REUSE AUTOEXTEND ON NEXT 640K MAXSIZE UNLIMITED
EXTENT MANAGEMENT LOCAL;
ALTER DATABASE DEFAULT TEMPORARY TABLESPACE "TEMP";
7. Run the scripts necessary to build views, synonyms, etc. :
The primary scripts that you must run are:
i> CATALOG.SQL-- creates the views of data dictionary tables and the
dynamic performance views.
ii> CATPROC.SQL-- establishes the usage of PL/SQL functionality and
creates many of the PL/SQL Oracle supplied packages.
==============================================================
Manual Database Creation steps for Real Application Clusters
==============================================================
Here are the steps to be followed to create a Real Application Clusters database:
1. Make a init
file is in $ORACLE_HOME\database. To simplify, you can copy init.ora to
init
be pointing to a pre-existing raw device or cluster file system location.
*** Path names, file names, and sizes will need to be modified
Example parameter settings for the first instance:
Cluster-Wide Parameters for Database "RAC":
db_block_size=8192
db_cache_size=52428800
background_dump_dest=/u01/32bit/app/oracle/product/9.0.1/rdbms/log
core_dump_dest=/u01/32bit/app/oracle/product/9.0.1/rdbms/log
user_dump_dest=/u01/32bit/app/oracle/product/9.0.1/rdbms/log
timed_statistics=TRUE
control_files=("/dev/RAC/control_01.ctl", "/dev/RAC/control_02.ctl")
db_name=RAC
shared_pool_size=52428800
sort_area_size=524288
undo_management=AUTO
cluster_database=true
cluster_database_instances=2
remote_listener=LISTENERS_RAC
Instance Specific Parameters for Instance "RAC1":
instance_name=RAC1
instance_number=1
local_listener=LISTENER_RAC1
thread=1
undo_tablespace=UNDOTBS
* The local_listener parameter requires that you first add the listener
address to the TNSNAMES.ORA - remember to do so on both Node 1 and Node 2.
** You can also use an spfile as described in Note 136327.1.
2. Run the following sqlplus command to connect to the database:
sqlplus '/ as sysdba'
3. Startup up the database in NOMOUNT mode:
SQL> startup nomount
4. Create the Database (All raw devices must be pre-created) :
*** Path names, file names, and sizes will need to be modified
CREATE DATABASE
CONTROLFILE REUSE
MAXDATAFILES 254
MAXINSTANCES 32
MAXLOGHISTORY 100
MAXLOGMEMBERS 5
MAXLOGFILES 64
DATAFILE '/dev/RAC/system_01_400.dbf' SIZE 400M
REUSE AUTOEXTEND ON NEXT 10240K MAXSIZE UNLIMITED
UNDO TABLESPACE "UNDOTBS" DATAFILE
'/dev/RAC/undotbs_01_210.dbf' SIZE 200M REUSE
NEXT 5120K MAXSIZE UNLIMITED
CHARACTER SET US7ASCII
LOGFILE GROUP 1 ('/dev/RAC/redo1_01_100.dbf') SIZE 100M REUSE,
GROUP 2 ('/dev/RAC/redo1_02_100.dbf') SIZE 100M REUSE;
5. Create a Users Tablespace:
*** Path names, file names, and sizes will need to be modified
CREATE TABLESPACE "USERS" LOGGING DATAFILE
'/dev/RAC/users_01_125.dbf' SIZE 120M REUSE
NEXT 1280K MAXSIZE UNLIMITED EXTENT MANAGEMENT LOCAL;
6. Create a Temporary Tablespace:
*** Path names, file names, and sizes will need to be modified
CREATE TEMPORARY TABLESPACE "TEMP" TEMPFILE
'/dev/RAC/temp_01_50.dbf' SIZE 40M REUSE
7. Create a 2nd Undo Tablespace:
*** Path names, file names, and sizes will need to be modified
CREATE UNDO TABLESPACE "UNDOTBS2" DATAFILE
'/dev/RAC/undotbs_02_210.dbf' SIZE 200M REUSE
NEXT 5120K MAXSIZE UNLIMITED;
8. Run the necessary scripts to build views, synonyms, etc.:
The primary scripts that you must run are:
i> CATALOG.SQL--creates the views of data dictionary tables and the
dynamic performance views
ii> CATPROC.SQL--establishes the usage of PL/SQL functionality and
creates many of the PL/SQL Oracle supplied packages
iii> CATPARR.SQL--creates RAC specific views
9. Edit init
2nd Node:
*** Names may need to be modified
instance_name=RAC2
instance_number=2
local_listener=LISTENER_RAC2
thread=2
undo_tablespace=UNDOTBS2
10. From the first instance, run the following command:
*** Path names, file names, and sizes will need to be modified
alter database
add logfile thread 2
group 3 ('/dev/RAC/redo2_01_100.dbf') size 100M,
group 4 ('/dev/RAC/redo2_02_100.dbf') size 100M;
alter database enable public thread 2;
12. Start the second Instance. (Assuming that your cluster configuration
is up and running).
Monday, July 14, 2008
important commands on solaris & linux operating system we are using oracle
Today I am sharing the some important commands on solaris & linux operating system we are using oracle
it's will give the perfect ipaddress
nslookup <>
--> firing "awk" command
ls -l | grep 'Feb 15' | awk '{print $9}' | xargs -i rm {}
ls -l | grep 'Dec Jan' | awk '{print $9}' | xargs -i rm {}
I use the following ps commands in order to check for performance probelms:
1) Displaying top CPU_consuming processes:
ps aux | head -1; ps aux | sort -rn +2 | head -10
2) Displaying top 10 memory-consuming processes:
ps aux | head -1; ps aux | sort -rn +3 | head
3) Displaying process in order of being penalized:
ps -eakl | head -1; ps -eakl | sort -rn +5 |grep -i aioserver|wc -l --(to check aioserver)
4) Displaying process in order of priority:
ps -eakl | sort -n +6 | head
5) Displaying process in order of nice value
ps -eakl | sort -n +7
6) Displaying the process in order of time
ps vx | head -1;ps vx | grep -v PID | sort -rn +3 | head -10
7) Displaying the process in order of real memory use
ps vx | head -1; ps vx | grep -v PID | sort -rn +6 | head -10
8) Displaying the process in order of I/O
ps vx | head -1; ps vx | grep -v PID | sort -rn +4 | head -10
9) Displaying WLM classes
ps -a -o pid, user, class, pcpu, pmem, args
10) Determinimg process ID of wait processes:
ps vg | head -1; ps vg | grep -w wait
11) Wait process bound to CPU
ps -mo THREAD -p
REVERTING BACK FROM 64 BIT TO 32 BIT
Login as root on both servers
# bootinfo -K
# ln -sf /usr/lib/boot/unix_mp /unix
# ln -sf /usr/lib/boot/unix_mp /usr/lib/boot/unix
# bosboot -ad /dev/ipldevice
-- comment the line containing "orapw:2:wait:/etc/loadext -l /etc/pw-syscall64"
-- remove the comment from line "orapw:2:wait:/etc/loadext -L /etc"
# shutdown -Fr
you can find it the xclock this location at solaris operating system
/usr/openwin/bin/xclock
How can we verify the how many archives are generating per day
ls -ltr *|grep "Jul 8"|wc -l
cut -f 1,2 -d : /etc/passwd (it's displaying the first two fields of the password file)
using this command is changing the archives format
for FILENAME in `ls verpp_*.arc.Z`
do
NF=`echo $FILENAME | sed 's/verpp/verpq2/'`
mv $FILENAME $NF
done
This is of particularly the concurrent processes is running or not we can verify
ps -fu applerpu1 |grep -i FND | awk '{print $2}'
Killing the concurrent processes
ps -fu applerpu1 |grep -i FND | awk '{print $2}' | xargs kill -9
These are the different applications we are verifying
ps -ef|grep -i defunc
ps -ef|grep -i applerpu2
ps -fu applerpu2
FIND THE RAM MEMORY IN SOLARIS
/usr/sbin/prtdiag | more
cpio -idmv > (patchnumber) ---------à While installation .cpio extention patcheswe need to unzip using this command
DISPLAYING PROCESSES STATISTICS
prstat -a
Displaying the who are logging at OS level If you type (w) character.
-------------
w
-------------
This is the command in vi file how to take a space in starting line instead of kama (,)
In column mode like this
:g/,/s// /g (if you give this command in column mode you can receive space instead of coma)
find /U01/vol1/arc/*.arc -type f -mtime +1 -exec rm {} \; ---------In the cronjobs they are mentioning of removing archives older than oneday
For analyzing schema
exec dbms_stats.gather_schema_stats ( ownname=>'ARN', options=>'GATHER', estimate_percent =>dbms_stats.auto_sample_size, cascade=>TRUE, degree=>15 );
exec dbms_stats.gather_schema_stats (ownname => 'SCOTT',options => 'GATHER',estimate_percent => dbms_stats.auto_sample_size, method_opt => 'for all columns size auto',cascade => true, degree => 4 );
USING THIS QUERY YOU CAN FIND IT HOW MANY DATAFILES & THEIR LOCATION FOR CLONING PURPOSE IT'S USEFUL
select distinct substr(file_name,1,13) from dba_data_files;
How can you check the contents in a procedure (or)package
select TEXT from dba_source where NAME='OWNER.PACKAGE (OR)PROCEDURE';
CONSTRAINT
alter table disable constraint ;
LOAD TEST OF COMMANDS
select count(1) from v$open_cursor;
select sid, count(1) from v$open_cursor group by sid order by 2;
SELECT sid, user_name, COUNT(*) "Cursors per session" FROM v$open_cursor
GROUP BY sid, user_name;
select username,status,sid,serial#,osuser,machine,program from v$session;
SELECT sess.sid,stxt.piece,stxt.sql_text FROM v$session sess,v$sqltext stxt WHERE sess.sql_address = stxt.address
AND sess.sql_hash_value = stxt.hash_value AND sess.sid = &sid ORDER BY stxt.piece
sar
top
vmstat
IF YOU CANNOT FIND THE TOP COMMAND IN SOLARIS
instead of top command you can execute this /usr/bin/prstat
perfstat/perfstat
@?/rdbms/admin/spreport.sql
we can find the cpu usage of inactive sessions using this command
select p.spid,s.sid,s.serial#,s.username,s.osuser,s.status,s.schemaname from v$process p,v$session s where s.paddr=p.addr and s.sid=18
HIGHER VERSION IMPORTING
TAKE EXPORT like this
Exp user/password@ db file='local file path.dmp' log='local path.log'
BLOCK CORRUPTION
v$copy_corruption
v$database_block_corruption
v$backup_corruption
SQL> select CORRUPTION_CHANGE#,CORRUPTION_TYPE,BLOCK#,a.BLOCKS,TABLE_NAME,OWNER from v$database_block_corruption a, dba_tables b
where a.BLOCKS=b.BLOCKS and b.TABLE_NAME='SYMC2_CUF_TXN';
SQL> SELECT SEGMENT_TYPE,OWNER||'.'||SEGMENT_NAME FROM DBA_EXTENTS WHERE FILE_ID = 32 AND 328013 BETWEEN BLOCK_ID AND BLOCK_ID+BLOCKS -1;
SQL> alter index owner.indexname rebuild online;
select ds.*
from dba_segments ds, sys.uet$ e
where ds.header_file=e.segfile#
and ds.header_block=e.segblock# and ds.owner='EAIMGR'
and between e.block# and e.block#+e.length-1;
and e.header_file=
and between e.block# and e.block#+e.length-1;
Creating Database LINK
CREATING DATABASE LINK
create database link STAGE_DATBASE connect to USER0 identified by ST3G1 using 'ALIAS';
select 'grant '||privilege||' to '||r.grantee||';' from dba_role_privs r, dba_sys_privs s where r.granted_role = 'CONNECT' and s.grantee = 'CONNECT' and r.grantee <> 'SYS';
select * from dba_dml_locks where name='AGG_ORDER_STG';
How can you check the table corrupted using this view
SELECT segment_name,segment_type,owner,tablespace_name,block_id,blocks FROM dba_extents WHERE file_id=393 AND 114 BETWEEN block_id and block_id + blocks -1 ;
SELECT segment_name,segment_type, owner, tablespace_name, block_id, blocks FROM dba_extents WHERE file_id = 388 and block_id=33;
alter index indexname modify partition partition_name unuseable;
alter index indexname rebuild online;
This is procedure of EXPLAIN PLAN
explain plan for <>
After that you execute this procedure
@$ORACLE_HOME/rdbms/admin/utlxpls
How to check the OEM VERSIONG
select * from dba_registry;
Procedure of Datapump
First create a directory on OS level.
Then create directory on sql prompt using the OS directory path by using the user who is going to take the export.
Ex. Create directory pqr as 'path of os directory';
Expdp user/passwd directory=pqr dumpfile=xyz.dmp logfile=xyz.log schemas/tables=a,b,c
Mooving archives using this date
nohup mv `ls -ltr *.gz|grep "Mar 7"|tr -s " "|cut -d " " -f9` /U01/vol9/arc_bkp &
How can we verify the how many archives are generating per day
ls -ltr *|grep "Jul 8"|wc -l
How to take export using datapump
U01> Create directory export as '/U01/vol1/bkp/export';
Directory created.
expdp system/xxx directory=export dumpfile=23May2008.dmp logfile=23May2008.log tables='STAGE.RPT_SKU','STAGE.SU_SUBSCRIPTIONS_SPD_ORIG'
impdp dumpfile=23May2008.dmp logfile=imp_23May2008.log REMAP_TABLESPACE=STAGE_DATA01:SASSTGD_DATA01
YOU CAN CREATE A DUMP FILES USING THIS PARALLEL=4 WHILE TAKING EXPORT AT A TIME IN DATAPUMP
nohup expdp system/xxxx dumpfile=SR_ETL_exp_tables_%U.dmp directory=SD LOGFILE=SR_ETL_exp_table_1.log PARALLEL=4 &
nohup impdp system/xxxx dumpfile=SR_ETL_exp_tables_%U.dmp directory=HD LOGFILE=SR_ETL_imp_tables_1.log PARALLEL=4 &
How to analyze table
exec dbms_stats.gather_table_stats(ownname=>'USER',tabname=>'TABLENAME',estimate_percent=>20, cascade=>true,degree=>8,method_opt=>'FOR ALL COLUMNS size 250');
export & import
nohup exp system/xxxxx owner=xxxx rows=n file=xxxx.dmp log=xxxx.log Buffer=80000000 &
nohup imp \"/ as sysdba\" file=xxxxx.dmp log=xxxxxx.log fromuser=xxxxxx touser=xxxxxx buffer=800000 feedback=20000 ignore=y &
Taking export using PAR file Below is an example of an export parameter file: export_options.par.
compress=n
direct=y
buffer=1000
rows=n
tables=table_with_one_million_rows, table_with_one_million_rows_1
userid=scott/tiger
file= file.dmp
log=file.log
Using this parameter file, the export command line is executed by the following:
exp parfile=export_options.par
some important views
select s.username, sum(p.pga_alloc_mem), sum (p.pga_used_mem) from v$session s, v$process p where s.paddr = p.addr and sid=35 group by s.username order by 2;
select a.username,a.account_status,a.lock_date,a.expiry_date,a.profile,b.resource_name,b.resource_type,b.limit from dba_users a, dba_profiles b where a.profile=b.profile and a.username like 'SYSTEM';
select owner,object_name,object_type,status
2 from dba_objects
3 where status != 'VALID'
4 and substr(object_name,1,1) != chr(95)
5 order by 1,2;
select owner,constraint_name,constraint_type TYPE,status,table_name
2 from dba_constraints
3 where status != 'ENABLED'
4 order by 1,2;
select owner,trigger_name,table_name
2 from dba_triggers
3 where status = 'DISABLED' and owner != 'SYS';
select TABLE_NAME, TABLE_NAME, PRIVILEGE from dba_tab_privs where GRANTOR ='USER';
select * from dba_role_privs where grantee='USER';
Creating Tablespace
Create tablespace VEN_REF01_DATA datafile '/U01/vol3/dat/data_01.dbf' SIZE 5120m
LOGGING ONLINE PERMANENT EXTENT MANAGEMENT LOCAL AUTOALLOCATE SEGMENT SPACE MANAGEMENT AUTO;
ANALYZING TABLE
EXEC DBMS_STATS.GATHER_TABLE_STATS(OWNNAME=>'HYBRID',TABNAME=>'PS_INSTALLBASE',ESTIMATE_PERCENT=>20,CASCADE=>TRUE,DEGREE=>8);
it's will give the perfect ipaddress
nslookup <
--> firing "awk" command
ls -l | grep 'Feb 15' | awk '{print $9}' | xargs -i rm {}
ls -l | grep 'Dec Jan' | awk '{print $9}' | xargs -i rm {}
I use the following ps commands in order to check for performance probelms:
1) Displaying top CPU_consuming processes:
ps aux | head -1; ps aux | sort -rn +2 | head -10
2) Displaying top 10 memory-consuming processes:
ps aux | head -1; ps aux | sort -rn +3 | head
3) Displaying process in order of being penalized:
ps -eakl | head -1; ps -eakl | sort -rn +5 |grep -i aioserver|wc -l --(to check aioserver)
4) Displaying process in order of priority:
ps -eakl | sort -n +6 | head
5) Displaying process in order of nice value
ps -eakl | sort -n +7
6) Displaying the process in order of time
ps vx | head -1;ps vx | grep -v PID | sort -rn +3 | head -10
7) Displaying the process in order of real memory use
ps vx | head -1; ps vx | grep -v PID | sort -rn +6 | head -10
8) Displaying the process in order of I/O
ps vx | head -1; ps vx | grep -v PID | sort -rn +4 | head -10
9) Displaying WLM classes
ps -a -o pid, user, class, pcpu, pmem, args
10) Determinimg process ID of wait processes:
ps vg | head -1; ps vg | grep -w wait
11) Wait process bound to CPU
ps -mo THREAD -p
REVERTING BACK FROM 64 BIT TO 32 BIT
Login as root on both servers
# bootinfo -K
# ln -sf /usr/lib/boot/unix_mp /unix
# ln -sf /usr/lib/boot/unix_mp /usr/lib/boot/unix
# bosboot -ad /dev/ipldevice
-- comment the line containing "orapw:2:wait:/etc/loadext -l /etc/pw-syscall64"
-- remove the comment from line "orapw:2:wait:/etc/loadext -L /etc"
# shutdown -Fr
you can find it the xclock this location at solaris operating system
/usr/openwin/bin/xclock
How can we verify the how many archives are generating per day
ls -ltr *|grep "Jul 8"|wc -l
cut -f 1,2 -d : /etc/passwd (it's displaying the first two fields of the password file)
using this command is changing the archives format
for FILENAME in `ls verpp_*.arc.Z`
do
NF=`echo $FILENAME | sed 's/verpp/verpq2/'`
mv $FILENAME $NF
done
This is of particularly the concurrent processes is running or not we can verify
ps -fu applerpu1 |grep -i FND | awk '{print $2}'
Killing the concurrent processes
ps -fu applerpu1 |grep -i FND | awk '{print $2}' | xargs kill -9
These are the different applications we are verifying
ps -ef|grep -i defunc
ps -ef|grep -i applerpu2
ps -fu applerpu2
FIND THE RAM MEMORY IN SOLARIS
/usr/sbin/prtdiag | more
cpio -idmv > (patchnumber) ---------à While installation .cpio extention patcheswe need to unzip using this command
DISPLAYING PROCESSES STATISTICS
prstat -a
Displaying the who are logging at OS level If you type (w) character.
-------------
w
-------------
This is the command in vi file how to take a space in starting line instead of kama (,)
In column mode like this
:g/,/s// /g (if you give this command in column mode you can receive space instead of coma)
find /U01/vol1/arc/*.arc -type f -mtime +1 -exec rm {} \; ---------In the cronjobs they are mentioning of removing archives older than oneday
For analyzing schema
exec dbms_stats.gather_schema_stats ( ownname=>'ARN', options=>'GATHER', estimate_percent =>dbms_stats.auto_sample_size, cascade=>TRUE, degree=>15 );
exec dbms_stats.gather_schema_stats (ownname => 'SCOTT',options => 'GATHER',estimate_percent => dbms_stats.auto_sample_size, method_opt => 'for all columns size auto',cascade => true, degree => 4 );
USING THIS QUERY YOU CAN FIND IT HOW MANY DATAFILES & THEIR LOCATION FOR CLONING PURPOSE IT'S USEFUL
select distinct substr(file_name,1,13) from dba_data_files;
How can you check the contents in a procedure (or)package
select TEXT from dba_source where NAME='OWNER.PACKAGE (OR)PROCEDURE';
CONSTRAINT
alter table
LOAD TEST OF COMMANDS
select count(1) from v$open_cursor;
select sid, count(1) from v$open_cursor group by sid order by 2;
SELECT sid, user_name, COUNT(*) "Cursors per session" FROM v$open_cursor
GROUP BY sid, user_name;
select username,status,sid,serial#,osuser,machine,program from v$session;
SELECT sess.sid,stxt.piece,stxt.sql_text FROM v$session sess,v$sqltext stxt WHERE sess.sql_address = stxt.address
AND sess.sql_hash_value = stxt.hash_value AND sess.sid = &sid ORDER BY stxt.piece
sar
top
vmstat
IF YOU CANNOT FIND THE TOP COMMAND IN SOLARIS
instead of top command you can execute this /usr/bin/prstat
perfstat/perfstat
@?/rdbms/admin/spreport.sql
we can find the cpu usage of inactive sessions using this command
select p.spid,s.sid,s.serial#,s.username,s.osuser,s.status,s.schemaname from v$process p,v$session s where s.paddr=p.addr and s.sid=18
HIGHER VERSION IMPORTING
TAKE EXPORT like this
Exp user/password@
BLOCK CORRUPTION
v$copy_corruption
v$database_block_corruption
v$backup_corruption
SQL> select CORRUPTION_CHANGE#,CORRUPTION_TYPE,BLOCK#,a.BLOCKS,TABLE_NAME,OWNER from v$database_block_corruption a, dba_tables b
where a.BLOCKS=b.BLOCKS and b.TABLE_NAME='SYMC2_CUF_TXN';
SQL> SELECT SEGMENT_TYPE,OWNER||'.'||SEGMENT_NAME FROM DBA_EXTENTS WHERE FILE_ID = 32 AND 328013 BETWEEN BLOCK_ID AND BLOCK_ID+BLOCKS -1;
SQL> alter index owner.indexname rebuild online;
select ds.*
from dba_segments ds, sys.uet$ e
where ds.header_file=e.segfile#
and ds.header_block=e.segblock# and ds.owner='EAIMGR'
and between e.block# and e.block#+e.length-1;
and e.header_file=
and between e.block# and e.block#+e.length-1;
Creating Database LINK
CREATING DATABASE LINK
create database link STAGE_DATBASE connect to USER0 identified by ST3G1 using 'ALIAS';
select 'grant '||privilege||' to '||r.grantee||';' from dba_role_privs r, dba_sys_privs s where r.granted_role = 'CONNECT' and s.grantee = 'CONNECT' and r.grantee <> 'SYS';
select * from dba_dml_locks where name='AGG_ORDER_STG';
How can you check the table corrupted using this view
SELECT segment_name,segment_type,owner,tablespace_name,block_id,blocks FROM dba_extents WHERE file_id=393 AND 114 BETWEEN block_id and block_id + blocks -1 ;
SELECT segment_name,segment_type, owner, tablespace_name, block_id, blocks FROM dba_extents WHERE file_id = 388 and block_id=33;
alter index indexname modify partition partition_name unuseable;
alter index indexname rebuild online;
This is procedure of EXPLAIN PLAN
explain plan for <
After that you execute this procedure
@$ORACLE_HOME/rdbms/admin/utlxpls
How to check the OEM VERSIONG
select * from dba_registry;
Procedure of Datapump
First create a directory on OS level.
Then create directory on sql prompt using the OS directory path by using the user who is going to take the export.
Ex. Create directory pqr as 'path of os directory';
Expdp user/passwd directory=pqr dumpfile=xyz.dmp logfile=xyz.log schemas/tables=a,b,c
Mooving archives using this date
nohup mv `ls -ltr *.gz|grep "Mar 7"|tr -s " "|cut -d " " -f9` /U01/vol9/arc_bkp &
How can we verify the how many archives are generating per day
ls -ltr *|grep "Jul 8"|wc -l
How to take export using datapump
U01> Create directory export as '/U01/vol1/bkp/export';
Directory created.
expdp system/xxx directory=export dumpfile=23May2008.dmp logfile=23May2008.log tables='STAGE.RPT_SKU','STAGE.SU_SUBSCRIPTIONS_SPD_ORIG'
impdp dumpfile=23May2008.dmp logfile=imp_23May2008.log REMAP_TABLESPACE=STAGE_DATA01:SASSTGD_DATA01
YOU CAN CREATE A DUMP FILES USING THIS PARALLEL=4 WHILE TAKING EXPORT AT A TIME IN DATAPUMP
nohup expdp system/xxxx dumpfile=SR_ETL_exp_tables_%U.dmp directory=SD LOGFILE=SR_ETL_exp_table_1.log PARALLEL=4 &
nohup impdp system/xxxx dumpfile=SR_ETL_exp_tables_%U.dmp directory=HD LOGFILE=SR_ETL_imp_tables_1.log PARALLEL=4 &
How to analyze table
exec dbms_stats.gather_table_stats(ownname=>'USER',tabname=>'TABLENAME',estimate_percent=>20, cascade=>true,degree=>8,method_opt=>'FOR ALL COLUMNS size 250');
export & import
nohup exp system/xxxxx owner=xxxx rows=n file=xxxx.dmp log=xxxx.log Buffer=80000000 &
nohup imp \"/ as sysdba\" file=xxxxx.dmp log=xxxxxx.log fromuser=xxxxxx touser=xxxxxx buffer=800000 feedback=20000 ignore=y &
Taking export using PAR file Below is an example of an export parameter file: export_options.par.
compress=n
direct=y
buffer=1000
rows=n
tables=table_with_one_million_rows, table_with_one_million_rows_1
userid=scott/tiger
file= file.dmp
log=file.log
Using this parameter file, the export command line is executed by the following:
exp parfile=export_options.par
some important views
select s.username, sum(p.pga_alloc_mem), sum (p.pga_used_mem) from v$session s, v$process p where s.paddr = p.addr and sid=35 group by s.username order by 2;
select a.username,a.account_status,a.lock_date,a.expiry_date,a.profile,b.resource_name,b.resource_type,b.limit from dba_users a, dba_profiles b where a.profile=b.profile and a.username like 'SYSTEM';
select owner,object_name,object_type,status
2 from dba_objects
3 where status != 'VALID'
4 and substr(object_name,1,1) != chr(95)
5 order by 1,2;
select owner,constraint_name,constraint_type TYPE,status,table_name
2 from dba_constraints
3 where status != 'ENABLED'
4 order by 1,2;
select owner,trigger_name,table_name
2 from dba_triggers
3 where status = 'DISABLED' and owner != 'SYS';
select TABLE_NAME, TABLE_NAME, PRIVILEGE from dba_tab_privs where GRANTOR ='USER';
select * from dba_role_privs where grantee='USER';
Creating Tablespace
Create tablespace VEN_REF01_DATA datafile '/U01/vol3/dat/data_01.dbf' SIZE 5120m
LOGGING ONLINE PERMANENT EXTENT MANAGEMENT LOCAL AUTOALLOCATE SEGMENT SPACE MANAGEMENT AUTO;
ANALYZING TABLE
EXEC DBMS_STATS.GATHER_TABLE_STATS(OWNNAME=>'HYBRID',TABNAME=>'PS_INSTALLBASE',ESTIMATE_PERCENT=>20,CASCADE=>TRUE,DEGREE=>8);
Subscribe to:
Posts (Atom)