Showing posts with label Load Balancer. Show all posts
Showing posts with label Load Balancer. Show all posts

Monday, July 25, 2011

How to create user in OID with orcladmin privileges.


 

My environment details:

Hostname: oidoam.tap

OID Port: 389

Root user: orcladmin

Password: abc123

New user to be created: qasim

Step 1: First of all from the ORACLE_HOME/bin execute following command.

$ ldapsearch -h oidoam.tap -p 389 -D "cn=orcladmin" -w abc123 "uniquemember=cn=orcladmin,cn=Users,dc=tap,dc=com" "dn" > '/tmp/group.ldif'

This command will create an ourput file group.ldif in /tmp.

Sample group.ldif output:

cn=OracleContextAdmins,cn=Groups,cn=OracleContext,dc=tap,dc=com

cn=OracleUserSecurityAdmins,cn=Groups,cn=OracleContext,dc=tap,dc=com

cn=iASAdmins, cn=Groups,cn=OracleContext,dc=tap,dc=com

cn=UserProxyPrivilege, cn=Groups,cn=OracleContext,dc=tap,dc=com

cn=OracleDASAdminGroup, cn=Groups,cn=OracleContext,dc=tap,dc=com

cn=OracleSuperUserAdminGroup, cn=Groups, cn=OracleContext,dc=tap,dc=com

cn=ASPAdmins, cn=groups,cn=OracleContext,dc=tap,dc=com

cn=IAS & User Mgmt Application Admins, cn=Groups,cn=OracleContext,dc=tap,dc=com

cn=Trusted Applications Admins, cn=Groups,cn=OracleContext,dc=tap,dc=com


 


 

Step 2.

Edit the group.ldif file to following format:

dn: cn=OracleContextAdmins,cn=Groups,cn=OracleContext,dc=tap,dc=com

changetype: modify

add: uniquemember

uniquemember: cn=qasim,cn=Users,dc=tap,dc=com


 

dn: cn=OracleUserSecurityAdmins,cn=Groups,cn=OracleContext,dc=tap,dc=com

changetype: modify

add: uniquemember

uniquemember: cn=qasim,cn=Users,dc=tap,dc=com


 

dn: cn=iASAdmins, cn=Groups,cn=OracleContext,dc=tap,dc=com

changetype: modify

add: uniquemember

uniquemember: cn=qasim,cn=Users,dc=tap,dc=com


 

dn: cn=UserProxyPrivilege, cn=Groups,cn=OracleContext,dc=tap,dc=com

changetype: modify

add: uniquemember

uniquemember: cn=qasim,cn=Users,dc=tap,dc=com


 

dn: cn=OracleDASAdminGroup, cn=Groups,cn=OracleContext,dc=tap,dc=com

changetype: modify

add: uniquemember

uniquemember: cn=qasim,cn=Users,dc=tap,dc=com


 

dn: cn=OracleSuperUserAdminGroup, cn=Groups, cn=OracleContext,dc=tap,dc=com

changetype: modify

add: uniquemember

uniquemember: cn=qasim,cn=Users,dc=tap,dc=com


 

dn: cn=ASPAdmins, cn=groups,cn=OracleContext,dc=tap,dc=com

changetype: modify

add: uniquemember

uniquemember: cn=qasim,cn=Users,dc=tap,dc=com


 

dn: cn=IAS & User Mgmt Application Admins, cn=Groups,cn=OracleContext,dc=tap,dc=com

changetype: modify

add: uniquemember

uniquemember: cn=qasim,cn=Users,dc=tap,dc=com


 

dn: cn=Trusted Applications Admins, cn=Groups,cn=OracleContext,dc=tap,dc=com

changetype: modify

add: uniquemember

uniquemember: cn=qasim,cn=Users,dc=tap,dc=com


 

dn: cn=Common User Attributes, cn=Groups,cn=OracleContext,dc=tap,dc=com

changetype: modify

add: uniquemember

uniquemember: cn=qasim,cn=Users,dc=tap,dc=com


 

dn: cn=Common Group Attributes, cn=Groups,cn=OracleContext,dc=tap,dc=com

changetype: modify

add: uniquemember

uniquemember: cn=qasim,cn=Users,dc=tap,dc=com


 

Step 4:

Save the group.ldif file and execute the following command:

$ ldapmodify -h oidoam.tap -p 389 -D "cn=orcladmin" -w abc123 -f '/tmp/group.ldif'

To confirm if the user has been really created, kindly execute the below command:

$ ldapsearch -h oidoam.tap -p 389 -D "cn=orcladmin" -w abc123 "uniquemember=cn=qasim,cn=Users,dc=tap,dc=com" "dn"

Saturday, November 27, 2010

Inastallation of Oracle Web Cashe as Load Balancer

Inastallation of Oracle Web Cashe as Load Balancer
We are going to install Oracle Web Cashe on Solaris SPARK system.

Step 1.
Create a user and give it DBA group.
Step 2.
Create folder and give read write permissions for this folder to the user.
Step 3.
Create entery in oraInst.loc in oraInventory.
Step 4.
Set the DISPLAY variable as to your ip address and export it.
Run the windowing service.
Login as the user the run the file runInstaller.
Give the PATH on which you want to install the webcashe.
At the end Installation will fail because on Solaris you need to add one patch which is a pre-requisite.Patch Number -4025481
Shutdown the services and start again.

Thursday, November 11, 2010

SQL tracing for Oracle Database

Current Session Trace
To start a SQL trace for the current session, execute:
ALTER SESSION SET sql_trace = true;
You can also add an identifier to the trace file name for later identification:
ALTER SESSION SET sql_trace = true;
ALTER SESSION SET tracefile_identifier = mysqltrace;

You can find the trace file through below queries:

To find the trace file for your current session:
SELECT value FROM v$diag_info WHERE name = ‘Default Trace File’;
To find all trace files for the current instance:
SELECT value FROM v$diag_info WHERE name = ‘Diag Trace’;
To determine the trace file for each Oracle Database process:
SELECT pid, program, tracefile FROM v$process;
To find the trace file with specific name:
SQL> select value from v$diag_info where value like '%tracefilename%';
Stop session trace
To stop SQL tracing for the current session, execute:
ALTER SESSION SET sql_trace = false;

Tracing other user's sessions
DBA's can use DBMS_SYSTEM.SET_SQL_TRACE_IN_SESSION to trace problematic database sessions.
Steps:
• Get the SID and SERIAL# for the process you want to trace.
SQL> select sid, serial# from sys.v_$session where username = ‘MOHY’;

SID SERIAL#
---------- ----------
18 54
Enable tracing for your selected process:
SQL> ALTER SYSTEM SET timed_statistics = true;
SQL> execute dbms_system.set_sql_trace_in_session(18, 54, true);
• Ask user to run just the necessary to demonstrate his problem.
To find if trace file has been created:
SQL> select value from v$diag_info where value like '%MOHY%';

• Disable tracing for your selected process:
SQL> execute dbms_system.set_sql_trace_in_session(18,54, false);

To enable SQL tracing for the entire database:
ALTER SYSTEM SET sql_trace = true SCOPE=MEMORY;
To stop:
ALTER SYSTEM SET sql_trace = false SCOPE=MEMORY;