Tuesday, October 31, 2017

Configuring Kernel Parameters and Resource Limits

example
[root@prince bin]# sysctl -w net.core.rmem_max=4194304
net.core.rmem_max = 4194304

Friday, October 20, 2017

ORA-12709 error while loading create database character set

sqlplus '/as sysdba'

SQL*Plus: Release 12.2.0.1.0 Production on Fri Oct 20 15:15:36 2017

Copyright (c) 1982, 2016, Oracle.  All rights reserved.

Connected to an idle instance.

SQL> startup
ORACLE instance started.

Total System Global Area 9999220736 bytes
Fixed Size                 12341968 bytes
Variable Size            1879051568 bytes
Database Buffers         8086618112 bytes
Redo Buffers               21209088 bytes
ORA-12709: error while loading create database character set










Solution :
got to /home/oracle/product/obiedb/12c/12.2.0.1/nls/data/old
[oracle@prince old]$ perl cr9idata.pl
Creating directory /home/oracle/product/obiedb/12c/12.2.0.1/nls/data/9idata ...
Copying files to /home/oracle/product/obiedb/12c/12.2.0.1/nls/data/9idata...
Copy finished.
Please reset environment variable ORA_NLS10 to /home/oracle/product/obiedb/12c/12.2.0.1/nls/data/9idata!
[oracle@prince old]$

qlplus '/as sysdba'

SQL*Plus: Release 12.2.0.1.0 Production on Fri Oct 20 15:25:07 2017

Copyright (c) 1982, 2016, Oracle.  All rights reserved.

Connected to an idle instance.

SQL> shutdown abort
ORACLE instance shut down.
SQL> startup
ORACLE instance started.

Total System Global Area 9999220736 bytes
Fixed Size                 12341968 bytes
Variable Size            1879051568 bytes
Database Buffers         8086618112 bytes
Redo Buffers               21209088 bytes
Database mounted.
Database opened.
SQL>


[FATAL] [DBT-06103] The port (5,500) is already in use. INFO: Read: ACTION: Specify a free port

Today I was installing oracle 12.2.1 db on Linux server, I got the error message.  
 
Read: [FATAL] [DBT-06103] The port (5,500) is already in use.
INFO: [FATAL] [DBT-06103] The port (5,500) is already in use.
WARNING: Skipping line: [FATAL] [DBT-06103] The port (5,500) is already in use.
INFO: Read:    ACTION: Specify a free port.
INFO:    ACTION: Specify a free port.
WARNING: Skipping line:    ACTION: Specify a free port.
INFO: Completed Plugin named: Oracle Database Configuration Assistant
 
 
Solution: 
edit your /etc/hosts and the entry if you do not have
 
#ipaddress hostname shotname
 
xxx.xxx.xxx.xxx example.test.haha example
 
 
After I retry the installation it works fine.
 
 
 

Thursday, October 5, 2017

OUD Installation



#! /bin/ksh
export JAVA_HOME=/apps2/jdk/jdk1.8.0_144/bin
export FMW=/apps2/OUD/fmw
export OUD_HOME=/apps2/OUD/fmw/Oracle_OUD1
export OUDIstance=/apps2/OUD/fmw/asinst_1


setup your inventory, fusion middleware home. setup your java











Go to /apps2/OUD/fmw/Oracle_OUD1

OUD Instance location successfully created /apps2/OUD/fmw/Oracle_OUD1/../asinst_1"


/OUD/fmw/Oracle_OUD1$ ./oud-setup
OUD Instance location successfully created - /apps2/OUD/fmw/Oracle_OUD1/../asinst_1"
Launching graphical setup...























Equivalent non-interactive command-line to setup server:

oud-setup \
          --cli \
          --baseDN dc=domain,dc=com \
          --sampleData 1000 \
          --adminConnectorPort xxx \
          --ldapPort xxxx\
          --rootUserDN cn=Directory\ Manager \
          --rootUserPasswordFile ****** \
          --ldapsPort xxxx \
          --generateSelfSignedCertificate \
          --hostname server.domain.name \
          --serverTuning -Xms1033m\ -Xmx1033m\ -d64\ -XX:+UseCompressedOops\ -server\ -XX:MaxTenuringThreshold=1\ -XX:+UseConcMarkSweepGC\ -XX:CMSInitiatingOccupancyFraction=55 \
          --offlineToolsTuning -Xms1033m\ -Xmx1033m\ -d64\ -XX:+UseCompressedOops\ -server\ -XX:+UseParallelGC\ -XX:+UseNUMA \
          --no-prompt \

          --noPropertiesFile

/apps2/OUD/fmw/Oracle_OUD1$ netstat -an |grep xxxx
      *.xxxx               *.*                  0      0  256000      0 LISTEN
      *.xxx                           *.*                               0      0  256000      0 LISTEN    


/apps2/OUD/fmw/Oracle_OUD1$ netstat -an |grep xxxx port number
      *.xxxx              *.*                  0      0  256000      0 LISTEN
      *.xxxx                            *.*                               0      0  256000      0 LISTEN    

USER@SERVER:/apps2/OUD/fmw/asinst_1/OUD/bin$ ./status


>>>> Specify Oracle Unified Directory LDAP connection parameters

Administrator user bind DN [cn=Directory Manager]:

Password for user 'cn=Directory Manager':

          --- Server Status ---
Server Run Status:        Started
Open Connections:         1

          --- Server Details ---
Host Name:                server.domain.xxx
Administrative Users:     cn=Directory Manager
Installation Path:        /apps2/OUD/fmw/Oracle_OUD1
Instance Path:            /apps2/OUD/fmw/asinst_1/OUD
Version:                  Oracle Unified Directory 11.1.2.3.0
Java Version:             1.8.0_144
Administration Connector: Port port#(LDAPS)

          --- Connection Handlers ---
Address:Port : Protocol : State
-------------:----------:---------
--           : LDIF     : Disabled
0.0.0.0:xxx  : SNMP     : Disabled
0.0.0.0:xxxx : LDAP     : Enabled
0.0.0.0:xxxx : JMX      : Disabled
0.0.0.0:xxx : LDAPS    : Enabled

          --- Data Sources ---
Base DN:     cn=virtual acis
Backend ID:  virtualAcis
Entries:     0
Replication: Disabled

Base DN:     dc=domain,dc=com
Backend ID:  userRoot
Entries:     1002
Replication: Disabled


USER@SERVER:/apps2/OUD/fmw/asinst_1/OUD/bin$

Now install weblogic on the middleware directory with fmw.
apps2/jdk/jdk1.8.0_144/bin/java -d64 -jar wls1036_generic.jar
























you need to install AD for ODSM web interface. Adf should be installed in FMW directory.



















run confisg.sh
/apps2/OUD/fmw/oracle_common/common/bin$














After installation you can see the directory structure
:/apps2/OUD/fmw$ ls -ltr
total 383
drwxr-x---   3 UID group        3 Sep 28 10:34 asinst_1
drwxr-x---  21  UID group       31 Sep 28 10:34 Oracle_OUD1
drwxr-xr-x   7 UID group      481 Sep 28 11:54 modules
drwxr-xr-x   8 UID group        9 Sep 28 11:54 utils
-rw-r--r--   1 UID group      854 Sep 28 11:54 ocm.rsp
-rw-r--r--   1 UID group   108875 Sep 28 11:54 registry.dat
-rw-r--r--   1 UID group     1901 Sep 28 11:54 registry.xml
drwxr-xr-x   8 UID group       10 Sep 28 11:54 wlserver_10.3
drwxr-xr-x   6 UID group        9 Sep 28 11:54 coherence_3.7
drwxrwx---   5 UID group        9 Sep 28 15:01 oraInventory_oud
drwxr-x---  32 UID group       35 Sep 28 15:02 oracle_common
drwxr-x---   3 UID group        3 Sep 28 15:13 user_projects
-rw-rw----   1 UID group      423 Sep 29 12:18 domain-registry.xml
drwxr-xr-x   2 UID group       18 Oct  2 13:57 logs

set your boot.properties.
/apps2/OUD/fmw/user_projects/domains/domainoud_domain/servers/AdminServer/security$ ls -ltr
total 2
-rw-r-----   1 username group      186 Sep 29 12:18 boot.properties

Now you have to start OUD
:/apps2/OUD/fmw/asinst_1/OUD/bin$ sh start-ds

then start weblogic

/apps2/OUD/fmw/user_projects/domains/domainoud_domain/bin
Sh  setDomainEnv.sh
Sh startWebLogic.sh

now you can login to console make sure your service is running. then you can login into odsm.


Thursday, July 13, 2017

Mutlicast Checker

http://radio-weblogs.com/0132383/stories/2004/05/21/mutlicastChecker.html

Example
java -jar mcastserver.jar -ipaddress xxx.x.x.x -port xxxxx 


Debugging an OracleAS clustered environment, with server configurations, application code requirements, replication settings, etc. can be a somewhat engaging process -- particularly if you are in a hurry and need to get it working ASAP.  Using a methodical approach, it's very easy to do, but we're not always in a methodical mood right? ;-).
One step that can be quite easily overlooked is to check to see if the actual network environment you are using for your cluster setup supports Multicast.  OracleAS relies on the use of multicast to replicate in-memory held data for web application sessions, and stateful session EJBs  amongst the other instances contained in the cluster.  If multicast isn't available on the system then the state replication aspect just won't work ... no matter what other configuration items you check, change and swear at.
So to help verify that multicast actually is available, I've written two small Java apps which can send and receive multicast datagrams on your network. This should enable you to confirm that multicast is working before you dive off and start looking for other possible causes of problems.
This zip file mcasttester.zip file contains two executable JAR files and the source code for the application.  Extract this into a directory of your choosing.

mcastserver

The multicast server program is contained within the mcastserver.jar file. It's an executable JAR file so all you need to do run it is type
>java -jar mcastserver.jar
If no parameters are specified, it uses a default multicast address of 230.230.230.1 and a port of 2608, and will send a message of "no worries mate" every ten seconds.
If you want to change the default settings such as the address, port, message, delay, random timer, verbose mode, then you can specify the new values via command line parameters.
Here's the help screen:
Usage:  sab.mcast.Server [-ipaddress aaa.bbb.ccc.ddd] [-port n] [-delay amount][-message "message to display"] [-useRandom] [-verbose] [-h | -help]
 [-h | -help]                 : prints this help message.
 [-ipaddress aaa.bbb.ccc.ddd] : sets the multicast address the client binds to.
 [-port nnnn]                 : sets the multicast port the client listens on.
 [-delay n]                   : sets the delay between requests, or max delay if using random.
 [-useRandom]                 : sets the use of random delays, up to the max delay value.
 [-verbose]                   : dumps out verbose info.
 [-message "text to send"]  : sets the message to send.
Example Usage:
  sab.mcast.Server -ipaddress 240.240.240.1 -port 9127 -delay 5000 -random -verbose -message "here it comes"
mcastclient
The multicast client program is contained within the mcastclient.jar file. It's an executable JAR file so all you need to do run it is type
>java -jar mcastclient.jar
If no parameters are specified, it listens on the default multicast address of 230.230.230.1 and port of 2608. These match the default settings used my the mcastserver.
You can specify specific a multicast address and port using command line parameters. Note that the ipaddress and port setings must match those used by the server, otherwise it'll be listening, but noone will be home ... ;-)
Usage: sab.mcast.Client [-ipaddress aaa.bbb.ccc.ddd] [-port nnnn] [-verbose] [-sequencecheck] [-h | -help]
  [-ipaddress aaa.bbb.ccc.ddd] : sets the multicast address the client binds to.
  [-port nnnn]                 : sets the multicast port the client listens on.
  [-sequencecheck]             : keeps track of the message sequence numbers and reports jumps.
  [-verbose]                   : dumps out verbose info.
  [-h]                         : prints this help message.
Example Usage:
  sab.mcast.Client -ipaddress 240.240.240.1 -port 9127 -verbose
The Quick Test
To quickly establish if multicast is working in your environment, put the mcastserver.jar on one box, and put the mcastclient.jar on the other boxes in your cluster.
On the server node, start mcastserver.jar with the default parameters:
>java -jar mcastserver.jar
You should see the following output
Server running with multicast address [230.230.230.1:2608]
On the client node(s), start mcastclient.jar with the default parameters:
>java -jar mcastclient.jar
You should see the following output and then messages appear every ten seconds
Client running using multicast address of [230.230.230.1:2608]
Message (1) received from [/140.83.24.117:4679] with message of "no worries mate!"
Message (2) received from [/140.83.24.117:4679] with message of "no worries mate!"
and onwards.
To verify that a specific multicast, port combination you want to use works, you can specify it on both the client and the server using the -ipaddress and -port command line parameters.
>java -jar mcastserver.jar -ipaddress 235.235.237.1 -port 12345
To send a specific message, set the -message parameter on the server
>java -jar mcastserver.jar -message 

SQL Patch Utility

From 11.2.0.3 the SQL Patch utility was introduced to control SQL statements by adding hints but without changing the SQL code. The process for setting this up is extremely simple.

SQL> exec sys.dbms_sqldiag_internal.i_create_patch(
  sql_text => 'select count(*), max(empno) from emp where deptno = :deptno',
    hint_text => 'BIND_AWARE',
    name =>'My_Patch');
The value for “hint_text” can be any valid hint.
If you want to include multiple hints, you can do so just by separating the hints with spaces. If you have a hint that require quotes such as
optimizer_features_enable('11.2.0.4')
don’t forget to ‘protect’ the quotes by putting two quotes (see below)
SQL> exec sys.dbms_sqldiag_internal.i_create_patch(
  sql_text=>'select count(*) from sales',
  hint_text=>'BIND_AWARE optimizer_features_enable(''11.2.0.4'')',
  name=>'MYPATCH');
This results in the following plan#
Execution Plan
----------------------------------------------------------
Plan hash value: 3730320257
------------------------------------------------------------------------------------
| Id  | Operation                      | Name              | Rows  | Cost (%CPU)| Ps
------------------------------------------------------------------------------------
|   0 | SELECT STATEMENT               |                   |     1 |     0   (0)|
|   1 |  SORT AGGREGATE                |                   |     1 |            |
|   2 |   PARTITION RANGE ALL          |                   |   918K|            |
|   3 |    BITMAP CONVERSION COUNT     |                   |   918K|            |
|   4 |     BITMAP INDEX FAST FULL SCAN| SALES_CHANNEL_BIX |       |            |
------------------------------------------------------------------------------------


Tuesday, July 11, 2017

After linux patch oracle Report was not working in R12 .1 application

Error : emsg:was terminated by signal 11
Enter Password:

Program was terminated by signal 11
Concurrent Manager encountered an error while running Oracle*Report



 solution :Report Server will not Start After Linux Kernel OS Updates (Doc ID 2280616.1)