Wednesday, November 30, 2011

11g Oracle DBA -- Part 2

  11g Oracle DBA -- Part 2

Introduction of 11g Database

Here we will go through the basic concepts of 11g Database. As an Oracle DBA you have to do the bellow activities. You have to install a Database. You may have to create a database. If required a DBA sometimes have to do an upgrade of the Database Server and the Database also. As per requirements it is a general requirement in a project that the database need to be started, stopped or restarted. They have plan the storage and memory structure of the database. It is one of the primary duty of a DBA to maintain user list and their securities. You have to manage all the database objects such as views, tables, indexes etc. To do backups and recoveries whenever required.  

Weather a DBA will do all these activities or there will be divisions in terms of responsibilities, that depends upon the requirement, scope, and size and budget of the project.

For doing the above activities a DBA uses the bellow tools. These are the weapons of a DBA to complete his tasks. 

  • Oracle Universal Installer (OUI)
  • Oracle Database Configuration Assistant (DBCA)
  • Database Upgrade Assistant (DBUA)
  • Net Configuration Assistant (NETCA)
  • Oracle Enterprise Manager Database Control
  • SQL* Loader
  • Recovery Manager (RMAN)

More in Next Part 

  11g Oracle DBA -- Part 1

  11g Oracle DBA -- Part 1

In this section we will cover the various section a DBA need to cope up to administering 11g Oracle Database.

  1. Introduction of 11g Database
  2. How to install Oracle Database and how to create a Database
  3. Starting Oracle Database administration
  4. How to configure Network for Oracle Database
  5. How to manage Oracle Database Instance
  6. How to manage Oracle Database storage Structures
  7. How to control User Accounts and Security
  8. How to manage Oracle Database Schema Objects
  9. How to do backup and recovery objectives
  10. How to Monitor and Tune a database
  11. Managing and Troubleshooting Oracle Database
  12. Managing ORacle Database Software

In this section we have given a brief idea about the Oracle 11g DBA Activities.

More in next post........

Oracle iRecruitment (iRec) External Candidate (Site Visitor) Configuration - Login Steps

 

 Oracle iRecruitment (iRec) External Candidate (Site Visitor) Configuration & Login Steps

1. Make sure that you are using seeded iRecruitment External candidate responsibilities.

2. Set the SSO Profile settings with the values.

Applications SSO Login Types - Both
Applications SSO Type - SSWA
Applications SSO User Creation and Updation Allowed - Enabled
Application SSO LDAP Synchronization - Enabled

3. Schedule the following concurrent processes:
• iRecruitment Index Synchronization
This ensures the job posting and document indexes are kept up to date and should be scheduled to run as follows:
– Online index rebuild – to run every 5 minutes
– Full index rebuild – to run each night

• Synchronize WF Roles

4. Check the IRC: Registration Business Group profile pointing to a correct business group for the iRecruitment External candidate Responsibility.

5. Add site visitor responsibilities to your Guest user
Assign the iRecruitment Employee Site Visitor and iRecruitment External Site Visitor responsibilities to your guest user (identified by the Guest User Password profile option). This step is required to allow
access to the site visitor screens without logging in to the application.

6. Also, download IrcVisitor.jsp page from the server and open the page in text editor and check if the Responsibility ID of 'iRecruitment Site Visitor' login page pointing to upon login. Pointing to a correct responsibility and this responsibility should be pointing in the login jsp page.

7. Set up proxy server
Use the following profiles to set up your proxy server:

• Applications Server Side Proxy Host and Domain
• Applications Proxy Bypass Domain
• IRC: Proxy Authorization Password
• IRC: Proxy Authorization User Name

8. Configure and Freeze your flexfields
Configure and Freeze all flexfields used in iRecruitment. This stops error messages appearing on the screen telling you that your flexfields have not been frozen.

9. Check the log–in URL for iRecruitment users
The URL for connecting to the iRecruitment system varies according to the user group. For example, the internal site visitor URL is different from the external site visitor URL.
For external site visitors, you access the IrcVisitor.jsp. The location of this jsp will depend on your applications server, however, it is of the form:
http://hostname:port/OA_HTML/IrcVisitor.jsp
For internal site visitors, you access the IrcEmpVisitor.jsp. The location of this jsp also depends on your applications server, however, it is of the form:
http://hostname:port/OA_HTML/IrcEmpVisitor.jsp
You should replace the http://hostname:port/OA_HTML part of the URL with the URL of the html directory on your applications server.
Note: If you have installed other languages, you activate iRecruitment in the required language by adding the following suffix to the log–in URLs:
?L=<language code>
For example,
http://hostname:port/OA_HTML/IrcVisitor.jsp?L=F would activate the French language version.
The language codes are available in the table FND_INSTALLED_LANGUAGES.
If you do not specify a language code, the default (US) is used

10. Configure the web pages for iRecruitment
You configure the web page layout using the Personalization Framework. If applicable, configure flexfields, instructions and tips, and the delivered logos.

Tuesday, November 29, 2011

Untitled

Day to Day activities of Oracle Apps DBA:

A DBA has to do various activities, it can be listed down according to priority, frequency of that activity. It can be devided in bellow pattern.

  • Daily Activities: These are the activities a DBA needs to do daily.
  1. VERIFY ALL INSTANCES ARE UP
  2. LOOK FOR ANY NEW ALERT LOG ENTRIES
  3. VERIFY DBSNMP IS RUNNING
  4. VERIFY SUCCESS OF DATABASE BACKUP
  5. VERIFY SUCCESS OF DATABASE ARCHIVING TO TAPE
  6. VERIFY ENOUGH RESOURCES FOR ACCEPTABLE PERFORMANCE
  7. READ DBA MANUALS FOR ONE HOUR
  • Weekly Activities: These are the activities a DBA needs to excersize weekly.
  1. LOOK FOR OBJECTS THAT BREAK RULES
  2. LOOK FOR SECURITY POLICY VIOLATIONS
  3. LOOK IN SQL*NET LOGS FOR ERRORS, ISSUES
  4. ARCHIVE ALL ALERT LOGS TO HISTORY
  5. VISIT HOME PAGES OF KEY VENDORS
  • Monthly Procedure: These are the procedures 
  1. LOOK FOR HARMFUL GROWTH RATES
  2. REVIEW TUNING OPPORTUNITIES
  3. LOOK FOR I/O CONTENTION
  4. REVIEW FRAGMENTATION
  5. PROJECT PERFORMANCE INTO THE FUTURE
    PERFORM TUNING AND MAINTENANCE

 

Untitled

Day to Day activities of Oracle Apps DBA:

A DBA has to do various activities, it can be listed down according to priority, frequency of that activity. It can be devided in bellow pattern.

  • Daily Activities: These are the activities a DBA needs to do daily.
  1. VERIFY ALL INSTANCES ARE UP
  2. LOOK FOR ANY NEW ALERT LOG ENTRIES
  3. VERIFY DBSNMP IS RUNNING
  4. VERIFY SUCCESS OF DATABASE BACKUP
  5. VERIFY SUCCESS OF DATABASE ARCHIVING TO TAPE
  6. VERIFY ENOUGH RESOURCES FOR ACCEPTABLE PERFORMANCE
  7. READ DBA MANUALS FOR ONE HOUR
  • Weekly Activities: These are the activities a DBA needs to excersize weekly.
  1. LOOK FOR OBJECTS THAT BREAK RULES
  2. LOOK FOR SECURITY POLICY VIOLATIONS
  3. LOOK IN SQL*NET LOGS FOR ERRORS, ISSUES
  4. ARCHIVE ALL ALERT LOGS TO HISTORY
  5. VISIT HOME PAGES OF KEY VENDORS
  • Monthly Procedure: These are the procedures 
  1. LOOK FOR HARMFUL GROWTH RATES
  2. REVIEW TUNING OPPORTUNITIES
  3. LOOK FOR I/O CONTENTION
  4. REVIEW FRAGMENTATION
  5. PROJECT PERFORMANCE INTO THE FUTURE
    PERFORM TUNING AND MAINTENANCE

 

How to setup network printer in Oracle Apps R12

How to do printer setup in Oracle Application R12.

It is mainly required for automatic printing of concurrent request output. For this setup you have to setup a network printer in the Oracle Application. For setting up the printer you have to do the following activities.

First you have to install the printer at os level.

- Download CUPS software
- Download the driver for your printer
- Add the printer

Once the instllation has been done you have ot check the printer from the command line that you are able to print a file.

This can be tested by the lp command.

lpstat -a
printer accepting requests since Fri 25 Nov 2011 05:34:15 PM IST

lpstat -t
scheduler is running
system default destination: printer
device for printer: lpd://192.168.1.26
printer accepting requests since Fri 25 Nov 2011 05:34:15 PM IST
printer printer is idle.  enabled since Fri 25 Nov 2011 05:34:15 PM IST

Go to http://www.cups.org and download the latest software and install it into the os.

Download the printer driver rpm and install it there in the server. 

Configure the printer at OS level. Once done test the printer using the lp command.

lp <filename>

Then go to command promt, and modify the pasta_pdf.cfg file according to the requirement.

cd $FND_TOP/resource

cp   pasta_pdf.cfg   pasta_pdf.cfg_orig

vi pasta_pdf.cfg

Existing one - old value

"

preprocess=pdftops {inline}  {outline}

"

New one - New value for PDF printing

"

preprocess=pdf2ps {inline}  {outline}

"

Register the Printer in Oracle Applications

Navigation: System Administrator ==>> Install ==>> Printer

We need to Register the Printer with the same name which has been derived at the Linux BOX level, 

If Driver is not already setup you have to setup the printer driver.

Navigation: System Administrator ==>> Install ==>> Printer ==>> Driver

In this we will be having four options where we can define a Custom Printer as well as Custom
Printer Drivers for Printer.
We need to register a Printer in the following Steps: Driver ==>> Styles ==>> Types ==>> Register
In order to make use of PDF Printing Directly from a Concurrent Program we need to have
PASTA_PDF Driver existing in the Oracle Applications.
Navigation: System Administrator ==>> Install ==>> Printer ==>> Driver
Driver Name : PASTA_PDF
User Driver : Pasta PDF Driver
Description : Pasta driver to print pdf converted to PostScript by 3rd party utility
Driver Method : Program
Driver Method Parameters : Spool File
Program Name : FNDPSTAX
Arguments: -pn$PROFILES$.PRINTER -f$PROFILES$.FILENAME – c$PROFILES$.CONC_COPIES -Fpasta_pdf.cfg


Defining and Assigning the Printer at Concurrent Program Level
Let us consider the Example of Defining a printer for Concurrent Program.
Usually we define Portrait or Landscape for the Style in the Concurrent Program at Output Tab.
Here we need to specific PDF Publisher as the Style in Concurrent Program and as well we have to mention the Name of the Printer which was registered in the Oracle Applications.

Run this program to get the output at Printer Tray
Select Options to select printer name and give number of copies as 1
Bounce the Concurrent Managers in case things didn’t work

Monday, November 28, 2011

Apps Front end Password reset scripts

Password reset scripts:
This is the procedure to reset the password of Oracle Apps user password. It is a PL/SQL Procedure. Password reset scripts is mainly used for resetting all the apps user password, it is mainly used after cloning the development or test instance from production instance.
declare
CURSOR cur_user_dtl IS
SELECT USER_ID, USER_NAME FROM fnd_user WHERE user_id >1000
ORDER BY creation_DATE DESC;
result boolean;
BEGIN
FOR c_user_dtl IN cur_user_dtl LOOP
result := fnd_user_pkg.changepassword(username => c_user_dtl.user_name,
newpassword => 'password123');
IF result THEN
NULL;
ELSE
dbms_output.put_line('The password of ' || c_user_dtl.user_name || ' has failed to reset.');
END IF;
END LOOP;
result := fnd_user_pkg.changepassword(username => 'SYSADMIN',
newpassword => 'welcome1');
end;
/

Welcome

How to reset Oracle Apps User Password from  Backend?

Oracle Apps User password can be resetted form the front end. But if in some case it is not possible to reset the password from the Oracle Apps GUI Screen.

It can be done by two ways,

  1. FNDCPASS utility
  2. Oracle Apps Procedure

1. FNDCPASS utility: It is a command line utility provided by Oracle Application to change the password. 

(i) SYSTEM ,It is used to change APPS/APPLSYS password

FNDCPASS < logon > 0 Y < system/password> SYSTEM < username > < new_password>

(ii) USER , It is used to change oracle applications user like SYSADMIN

FNDCPASS < logon> 0 Y < system/password> USER < username> < new_password>

(iii) ORACLE, It is used to change the password of oracle schema like GL,AP

FNDCPASS apps/apps 0 Y system/manager ORACLE GL gl1

(iv) ALLORACLE , It is used to change all passwords of all schema.

FNDCPASS apps/apps 0 Y system/manager ALLORACLE welcome

 

2.   Oracle Apps Procedure

You can use the bellow procedure to reset any Oracle Application user password like SYSADMIN

declare

result boolean;

begin

result := fnd_user_pkg.changepassword(username => :username, newpassword => :newpassword);

end;

Wednesday, October 26, 2011

How to Install Oracle Database Software and Create a New Database

How to Install Oracle Database Software and Create a New Database

For installing Oracle Database Software, you have to take the help of Oracle Universal Installer or OUI. It is graphical tool to install and maintain oracle products installed or to be installed. But before installing Oracle Database software you should fulfill the following requirement.
1. You have to fullfill minimum physical memory requirement. This is 512 MB for Microsoft Windows or Linux and 1024 MB or 1 GB for UNIX or other Operating Systems.
2. You should have enough paging space.
3. Your operation system should be updated to the required Service Pack Level or Kernel version level.
4. You should follow the required file format for the Oracle Database as per Oracle Guidelines.

Whenever you are going to install oracle database software, you have to decide which type of Oracle Database Software Installation you want. The list is like bellow,
Enterprise Edition: It is the installation, where you will get the Oracle Database Product with full features, which is required for the data management at enterprise level.
Standard Edition: It is the installation, where you will get the Oracle Database Product to provide support to a medium size organization. It will provide all the basic database services.
Personal Edition: This type of installation is available only in Microsoft windows. It is same with the Enterprise Edition in case of Features but the limitation is single user option, which is mainly taken for development and deployment scenario.
Custom Install: Here the features are customized from the enterprise edition according to the requirement of the USER.

At the time of installation you can pick the advance installation option. If you pick this option you will be asked some question, which will guide you for the completion of the installation.
 Install Sample Schema?
 What type of storage mechanism do you want your database to use?( File System/Automatic Storage Management/ Raw Devices)
 What are your database management options?
Steps to Install Oracle Database Software
For being Oracle Database basic installation you have to follow the bellow steps.
1. For doing the installation you have to logon as the administrator user. That means that the user should have the authority to install oracle database software, create and run the database.
2. If you are installing from a media, click or run the Oracle Universal Installer (OUI).
3. Then you have to select the Product, In this case Oracle Database 11g. Then Click Next.
4. Select Basic Installation type. You have to give the following input, Oracle Home, Oracle Base Location, Installation Type, UNIX DBA Group, Create Starter Database.
5. If you are doing first time installation, then specify a location which will be Oracle Inventory location. And it is different from ORACLE_HOME
6. It is for UNIX and Linux only; OUI will perform some environment checks and give a success or failure status.
7. In case of windows click next if all the Product-Specific Prerequisite check status succeeded. In case of failure take corrective actions.
8. Click next in the Oracle Configuration Manager Registration window.
9. Start the Install button, after reviewing the summary given in the screen.
10. An optional step is there as in Password Management you can unlock the required user accounts.
11. Click OK to continue installation.
12. At the end of the installation exit the OUI confirming YES.

How to use DBCA to create a Database and manage it?
Coming in Next post.

Saturday, February 19, 2011

manually undeploy the application if you are not able to do so from dcm

At the time of undeploying an application in Oracle Application Server 10.1.2 it is fiving the following error


Error

An error occured while undeploying the application. Base Exception:

No ApplicationInfo is associated with application named: Sth

Resolution:





You have to manually undeploy the application if you are not able to do so from dcm.



1. Shut down the HTTP server of the OAS

2. Shut down all the OC4J instances in the OAS



-bash-3.2$ cd /u01/10G_AS/Midd/

-bash-3.2$ ./opmn/bin/opmnctl status



Processes in Instance: midd.tcs186246.tcskolkata.co.in

-------------------+--------------------+---------+---------

ias-component
process-type
pid
status

-------------------+--------------------+---------+---------

DSA
DSA
N/A
Down

LogLoader
logloaderd
N/A
Down

dcm-daemon
dcm-daemon
17680
Alive

OC4J
home
17521
Alive

OC4J
OC4J_Portal
N/A
Down

WebCache
WebCache
17488
Alive

WebCache
WebCacheAdmin
17477
Alive

HTTP_Server
HTTP_Server
17479
Alive



-bash-3.2$ ./opmn/bin/opmnctl stopall

opmnctl: stopping opmn and all managed processes...



3. Run dcmctl getState -v -d and check if you are in synch or not



-bash-3.2$ ./dcm/bin/dcmctl getState -v -d





Current State for Instance:midd.tcs186246.tcskolkata.co.in



Component Type Up Status In Sync Status

================================================================================

1 HTTP_Server HTTP_Server Down True

2 OC4J_Portal OC4J Down True

3 home OC4J Down True



4. Goto the following path

-bash-3.2$ cd ./j2ee/OC4J_Portal/config



5. Take the Backup of server.xml and default-web-site.xml file.



-bash-3.2$ cp server.xml server.xml_bkp

-bash-3.2$ cp default-web-site.xml default-web-site.xml_bkp



6. Edit both files to delete the entries respective to the application, which you want to delete.



-bash-3.2$ vi server.xml

-bash-3.2$ vi default-web-site.xml

-bash-3.2$ vi server.xml



7. Go to the following directory and remove the ear and the directories of the specified applications.



-bash-3.2$ cd ../applications

-bash-3.2$ ls -lrt

total 17864

drwxrwx--- 4 oracletrg dba 4096 Feb 1 12:59 portalHelp2

-rw-rw---- 1 oracletrg dba 2687627 Feb 1 12:59 jpdk.ear

drwxrwx--- 5 oracletrg dba 4096 Feb 1 12:59 jpdk

drwxrwx--- 7 oracletrg dba 4096 Feb 1 12:59 UltrasearchQuery

drwxrwx--- 6 oracletrg dba 4096 Feb 1 12:59 UltrasearchAdmin

drwxrwx--- 4 oracletrg dba 4096 Feb 1 12:59 orauddi

drwxrwx--- 4 oracletrg dba 4096 Feb 1 12:59 portalHelp

drwxrwx--- 4 oracletrg dba 4096 Feb 1 12:59 UltrasearchPortlet

drwxrwx--- 8 oracletrg dba 4096 Feb 1 12:59 portalTools

drwxrwx--- 4 oracletrg dba 4096 Feb 1 12:59 portal

drwxrwx--- 5 oracletrg dba 4096 Feb 1 12:59 oraudrepl

-rw-r--r-- 1 oracletrg dba 5441117 Feb 11 18:15 SimpleStruts2.ear

drwxr-xr-x 4 oracletrg dba 4096 Feb 11 18:15 SimpleStruts2

-rw-r--r-- 1 oracletrg dba 10075940 Feb 14 10:58 Sth.ear

drwxr-xr-x 4 oracletrg dba 4096 Feb 14 10:58 Sth

-bash-3.2$ rm -rf SimpleStruts2.ear SimpleStruts2 Sth.ear Sth





8. Go to the following directory and remove the directories of the specified applications.



-bash-3.2$ cd ../application-deployments/

-bash-3.2$ ls -lrt

total 52

drwxrwx--- 4 oracletrg dba 4096 Feb 1 12:58 default

drwxrwx--- 6 oracletrg dba 4096 Feb 1 12:59 oraudrepl

drwxrwx--- 4 oracletrg dba 4096 Feb 1 12:59 orauddi

drwxrwx--- 5 oracletrg dba 4096 Feb 10 15:28 UltrasearchQuery

drwxrwx--- 4 oracletrg dba 4096 Feb 10 15:28 UltrasearchPortlet

drwxrwx--- 6 oracletrg dba 4096 Feb 10 15:28 UltrasearchAdmin

drwxrwx--- 8 oracletrg dba 4096 Feb 10 15:28 portalTools

drwxrwx--- 4 oracletrg dba 4096 Feb 10 15:28 portalHelp2

drwxrwx--- 4 oracletrg dba 4096 Feb 10 15:28 portalHelp

drwxrwx--- 4 oracletrg dba 4096 Feb 10 15:28 portal

drwxrwx--- 5 oracletrg dba 4096 Feb 10 15:28 jpdk

drwxr-xr-x 4 oracletrg dba 4096 Feb 11 18:15 SimpleStruts2

drwxr-xr-x 4 oracletrg dba 4096 Feb 14 10:58 Sth

-bash-3.2$ rm -rf SimpleStruts2 Sth



9. Go to $ORACLE_HOME(MID)/Apache/Apache/conf/



-bash-3.2$ cd ../../../Apache/Apache/conf/



10. Take a backup of mod_oc4j.conf file.



-bash-3.2$ cp mod_oc4j.conf mod_oc4j.conf_bkp



11. Edit the mod_oc4j.conf file to remove the entries regarding the applications.



-bash-3.2$ vi mod_oc4j.conf



12. Goto $ORACLE_HOME(MID)/dcm/bin/ and update the configuration



-bash-3.2$ cd dcm/bin/

-bash-3.2$ ./dcmctl updateConfig -v -d



13. Start the opmnctl



-bash-3.2$ ./../../opmn/bin/opmnctl startall

opmnctl: starting opmn and all managed processes...



14. Check the status of the opmnctl



-bash-3.2$ ./../../opmn/bin/opmnctl status



Processes in Instance: midd.tcs186246.tcskolkata.co.in

-------------------+--------------------+---------+---------
ias-component process-type         pid          status
-------------------+--------------------+---------+---------
DSA              DSA                        N/A       Down
LogLoader     LogLoader              N/A       Down
dcm-daemon dcm-daemon            14784   Alive
OC4J            home                        15646   Alive
OC4J            OC4J_Portal            15645   Alive
WebCache    WebCache               15618   Alive
WebCache    WebCacheAdmin     15607   Alive
HTTP_Server HTTP_Server          15609  Alive



Command to do active duplicate for Oracle Database

1. First login to target server 2. Validate tns connectivity between Source DB and Target DB 3. Prepare and validate space availability 4. S...