13 October 2007

Installing and Preparing CentOS 5.0 for the Installation of Oracle 11g Database

CentOS (Community Enterprise Operating System) 2, 3, 4 and 5 are built from publicly available open source SRPMS provided by a prominent North American Enterprise Linux vendor. CentOS conforms fully with the upstream vendors redistribution policies and aims to be 100% binary compatible. (CentOS mainly changes packages to remove upstream vendor branding and artwork).

CentOS is free! The "Prominent North american Enterprise Linux Vendor" and "Upstream Vendor" is Red Hat. In the last three years using CentOS I don't have any compatibility problem! To learn more about CentOS please visit http://www.centos.org

Installation environment
Linux Box is virtual machine created using VMware Workstation 6.0.
Guest OSRed Hat Enterprise Linux 5
Memory1024 MB
Hard Disk60 GB, Hard disk contents are stored in one or more files up to 2 GB each
CD-ROMAuto detect, use physical drive
EthernetBridged: Connected directly to the physical network.
USB-ControlerPresent
Sound AdapterAuto detect
DisplayAuto detect
Processors1
To learn more about VMware Workstation please visit http://www.vmware.com.

Download CentOS 5
The downloads sites of CentOS ISO images You can find here: http://isoredirect.centos.org/centos/5/isos/i386/
My DVD ISO Image I downloaded from here: http://centos.serveroffice.at/5.0/isos/i386/CentOS-5.0-i386-bin-DVD.iso

CentOS Installation
The installation uses mostly the default values. I made following changes:
Hard Drive PartitioningCreate Custom Layout.
Swap Space 2 GB and
one 58 GB root partition "/"
Network deviceConfigured manualy with static IP Address.
Disabled "Use of DHCP"
Disabled "Enable IPv6 support"
IPv4 Address: 192.168.0.95
Netmask: 255.255.255.0
Hostname: vl095.fla.net
Gateway: 192.168.0.1
Primary DNS: 192.168.0.1
RegionEurope/Vienna. select "System clock uses UTC"
Software SelectLeave default: Only Desktop Gnome selected and Radio Button "Customize later" activated
FirewallDisabled
SELinuxPermissive

Here is the Diashow of my CentOS installation:


Install the Required OS Packages

Please download the Oracle 11g Installation Documentation: http://www.oracle.com/pls/db111/to_pdf?pathname=install.111/b32002.pdf

The following package (or later version) must be installed:
binutils-2.17.50.0.6-2.el5
compat-libstdc++-33-3.2.3-61
elfutils-libelf-0.125-3.el5
elfutils-libelf-devel-0.125
gcc-4.1.1-52
gcc-c++-4.1.1-52
glibc-2.5-12
glibc-common-2.5-12
glibc-devel-2.5-12
glibc-headers-2.5-12
libaio-0.3.106
libaio-devel-0.3.106
libgcc-4.1.1-52
libstdc++-4.1.1
libstdc++-devel-4.1.1-52.e15
make-3.81-1.1
sysstat-7.0.0
unixODBC-2.2.11
unixODBC-devel-2.2.11

I installed the required OS Packages using "yum" (Yellowdog Updater, Modified).
Connect to Linux Box as root and start the "yum" command:

yum -y install binutils compat-libstdc++-33 elfutils-libelf elfutils-libelf-devel gcc gcc-c++ glibc glibc-common glibc-devel glibc-headers libaio libaio-devel libgcc libstdc++ libstdc++-devel make sysstat unixODBC unixODBC-devel

[root@vl095 ~]# yum -y install binutils compat-libstdc++-33 elfutils-libelf elfutils-libelf-devel gcc gcc-c++ glibc glibc-common glibc-devel glibc-headers libaio libaio-devel libgcc libstdc++ libstdc++-devel make sysstat unixODBC unixODBC-devel
Loading "installonlyn" plugin
Setting up Install Process
Setting up repositories
base 100% |=========================| 1.1 kB 00:00
updates 100% |=========================| 951 B 00:00
addons 100% |=========================| 951 B 00:00
extras 100% |=========================| 1.1 kB 00:00
Reading repository metadata in from local files
Parsing package install arguments
Resolving Dependencies
--> Populating transaction set with selected packages. Please wait.
---> Downloading header for sysstat to pack into transaction set.
sysstat-7.0.0-3.el5.i386. 100% |=========================| 14 kB 00:00
---> Package sysstat.i386 0:7.0.0-3.el5 set to be updated
---> Downloading header for unixODBC-devel to pack into transaction set.
unixODBC-devel-2.2.11-7.1 100% |=========================| 16 kB 00:00
---> Package unixODBC-devel.i386 0:2.2.11-7.1 set to be updated
---> Downloading header for unixODBC to pack into transaction set.
unixODBC-2.2.11-7.1.i386. 100% |=========================| 28 kB 00:00
---> Package unixODBC.i386 0:2.2.11-7.1 set to be updated
---> Downloading header for gcc-c++ to pack into transaction set.
gcc-c++-4.1.1-52.el5.2.i3 100% |=========================| 52 kB 00:00
---> Package gcc-c++.i386 0:4.1.1-52.el5.2 set to be updated
---> Downloading header for gcc to pack into transaction set.
gcc-4.1.1-52.el5.2.i386.r 100% |=========================| 59 kB 00:00
---> Package gcc.i386 0:4.1.1-52.el5.2 set to be updated
---> Downloading header for glibc-devel to pack into transaction set.
glibc-devel-2.5-12.i386.r 100% |=========================| 105 kB 00:00
---> Package glibc-devel.i386 0:2.5-12 set to be updated
---> Downloading header for glibc-headers to pack into transaction set.
glibc-headers-2.5-12.i386 100% |=========================| 138 kB 00:00
---> Package glibc-headers.i386 0:2.5-12 set to be updated
---> Downloading header for libaio-devel to pack into transaction set.
libaio-devel-0.3.106-3.2. 100% |=========================| 6.7 kB 00:00
---> Package libaio-devel.i386 0:0.3.106-3.2 set to be updated
---> Downloading header for libgcc to pack into transaction set.
libgcc-4.1.1-52.el5.2.i38 100% |=========================| 49 kB 00:00
---> Package libgcc.i386 0:4.1.1-52.el5.2 set to be updated
---> Downloading header for compat-libstdc++-33 to pack into transaction set.
compat-libstdc++-33-3.2.3 100% |=========================| 7.2 kB 00:00
---> Package compat-libstdc++-33.i386 0:3.2.3-61 set to be updated
---> Downloading header for libstdc++ to pack into transaction set.
libstdc++-4.1.1-52.el5.2. 100% |=========================| 49 kB 00:00
---> Package libstdc++.i386 0:4.1.1-52.el5.2 set to be updated
---> Downloading header for libstdc++-devel to pack into transaction set.
libstdc++-devel-4.1.1-52. 100% |=========================| 130 kB 00:00
---> Package libstdc++-devel.i386 0:4.1.1-52.el5.2 set to be updated
---> Downloading header for elfutils-libelf-devel to pack into transaction set.
elfutils-libelf-devel-0.1 100% |=========================| 13 kB 00:00
---> Package elfutils-libelf-devel.i386 0:0.125-3.el5 set to be updated
--> Running transaction check
--> Processing Dependency: elfutils-libelf-devel-static = 0.125-3.el5 for package: elfutils-libelf-devel
--> Processing Dependency: libgomp.so.1 for package: gcc
--> Processing Dependency: libgomp = 4.1.1-52.el5.2 for package: gcc
--> Processing Dependency: cpp = 4.1.1-52.el5.2 for package: gcc
--> Restarting Dependency Resolution with new changes.
--> Populating transaction set with selected packages. Please wait.
---> Downloading header for elfutils-libelf-devel-static to pack into transaction set.
elfutils-libelf-devel-sta 100% |=========================| 13 kB 00:00
---> Package elfutils-libelf-devel-static.i386 0:0.125-3.el5 set to be updated
---> Downloading header for cpp to pack into transaction set.
cpp-4.1.1-52.el5.2.i386.r 100% |=========================| 52 kB 00:00
---> Package cpp.i386 0:4.1.1-52.el5.2 set to be updated
---> Downloading header for libgomp to pack into transaction set.
libgomp-4.1.1-52.el5.2.i3 100% |=========================| 49 kB 00:00
---> Package libgomp.i386 0:4.1.1-52.el5.2 set to be updated
--> Running transaction check

Dependencies Resolved

=============================================================================
Package Arch Version Repository Size
=============================================================================
Installing:
compat-libstdc++-33 i386 3.2.3-61 base 232 k
elfutils-libelf-devel i386 0.125-3.el5 base 20 k
gcc i386 4.1.1-52.el5.2 updates 4.9 M
gcc-c++ i386 4.1.1-52.el5.2 updates 3.3 M
glibc-devel i386 2.5-12 base 2.0 M
glibc-headers i386 2.5-12 base 605 k
libaio-devel i386 0.3.106-3.2 base 11 k
libstdc++-devel i386 4.1.1-52.el5.2 updates 9.4 M
sysstat i386 7.0.0-3.el5 base 163 k
unixODBC i386 2.2.11-7.1 base 832 k
unixODBC-devel i386 2.2.11-7.1 base 739 k
Updating:
libgcc i386 4.1.1-52.el5.2 updates 82 k
libstdc++ i386 4.1.1-52.el5.2 updates 350 k
Installing for dependencies:
elfutils-libelf-devel-static i386 0.125-3.el5 base 60 k
libgomp i386 4.1.1-52.el5.2 updates 69 k
Updating for dependencies:
cpp i386 4.1.1-52.el5.2 updates 2.6 M

Transaction Summary
=============================================================================
Install 13 Package(s)
Update 3 Package(s)
Remove 0 Package(s)

Total download size: 25 M
Downloading Packages:
(1/16): sysstat-7.0.0-3.e 100% |=========================| 163 kB 00:00
(2/16): elfutils-libelf-d 100% |=========================| 60 kB 00:00
(3/16): unixODBC-devel-2. 100% |=========================| 739 kB 00:01
(4/16): unixODBC-2.2.11-7 100% |=========================| 832 kB 00:01
(5/16): gcc-c++-4.1.1-52. 100% |=========================| 3.3 MB 00:07
(6/16): gcc-4.1.1-52.el5. 100% |=========================| 4.9 MB 00:12
(7/16): glibc-devel-2.5-1 100% |=========================| 2.0 MB 00:05
(8/16): glibc-headers-2.5 100% |=========================| 605 kB 00:02
(9/16): cpp-4.1.1-52.el5. 100% |=========================| 2.6 MB 00:06
(10/16): libaio-devel-0.3 100% |=========================| 11 kB 00:00
(11/16): libgcc-4.1.1-52. 100% |=========================| 82 kB 00:00
(12/16): compat-libstdc++ 100% |=========================| 232 kB 00:00
(13/16): libstdc++-4.1.1- 100% |=========================| 350 kB 00:00
(14/16): libstdc++-devel- 100% |=========================| 9.4 MB 00:26
(15/16): elfutils-libelf- 100% |=========================| 20 kB 00:00
(16/16): libgomp-4.1.1-52 100% |=========================| 69 kB 00:00
warning: rpmts_HdrFromFdno: Header V3 DSA signature: NOKEY, key ID e8562897
Importing GPG key 0xE8562897 "CentOS-5 Key (CentOS 5 Official Signing Key) " from http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-5
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
Updating : libgcc ####################### [ 1/19]
Updating : libstdc++ ####################### [ 2/19]
Installing: libstdc++-devel ####################### [ 3/19]
Installing: libgomp ####################### [ 4/19]
Updating : cpp ####################### [ 5/19]
Installing: glibc-headers ####################### [ 6/19]
Installing: glibc-devel ####################### [ 7/19]
Installing: gcc ####################### [ 8/19]
Installing: unixODBC ####################### [ 9/19]
Installing: unixODBC-devel ####################### [10/19]
Installing: gcc-c++ ####################### [11/19]
Installing: compat-libstdc++-33 ####################### [12/19]
Installing: libaio-devel ####################### [13/19]
Installing: sysstat ####################### [14/19]
Installing: elfutils-libelf-devel ####################### [15/19]
Installing: elfutils-libelf-devel-static ####################### [16/19]
Cleanup : cpp ####################### [17/19]
Cleanup : libgcc ####################### [18/19]
Cleanup : libstdc++ ####################### [19/19]

Installed: compat-libstdc++-33.i386 0:3.2.3-61 elfutils-libelf-devel.i386 0:0.125-3.el5 gcc.i386 0:4.1.1-52.el5.2 gcc-c++.i386 0:4.1.1-52.el5.2 glibc-devel.i386 0:2.5-12 glibc-headers.i386 0:2.5-12 libaio-devel.i386 0:0.3.106-3.2 libstdc++-devel.i386 0:4.1.1-52.el5.2 sysstat.i386 0:7.0.0-3.el5 unixODBC.i386 0:2.2.11-7.1 unixODBC-devel.i386 0:2.2.11-7.1
Dependency Installed: elfutils-libelf-devel-static.i386 0:0.125-3.el5 libgomp.i386 0:4.1.1-52.el5.2
Updated: libgcc.i386 0:4.1.1-52.el5.2 libstdc++.i386 0:4.1.1-52.el5.2
Dependency Updated: cpp.i386 0:4.1.1-52.el5.2
Complete!
Check and Modify /etc/hosts file

[root@vl095 ~]# cat /etc/hosts
# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1 localhost.localdomain localhost
192.168.0.95 vl095.fla.net vl095
Set Kernel Parameters

Recommended minimum values are:
fs.file-max = 512 * PROCESSES
kernel.shmall = 2097152
kernel.shmmax = 2147483648
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
net.ipv4.ip_local_port_range = 1024 65000
net.core.rmem_default = 262144
net.core.rmem_max = 4194304
net.core.wmem_default = 262144
net.core.wmem_max = 262144

Check Your current value using following commands:
/sbin/sysctl -a | grep sem
/sbin/sysctl -a | grep shm
/sbin/sysctl -a | grep file-max
/sbin/sysctl -a | grep ip_local_port_range
/sbin/sysctl -a | grep rmem_default
/sbin/sysctl -a | grep rmem_max
/sbin/sysctl -a | grep wmem_default
/sbin/sysctl -a | grep wmem_max

Content of the Kernel configuration file /etc/sysctl.conf
[root@vl095 ~]# cat /etc/sysctl.conf
# Kernel sysctl configuration file for Red Hat Linux
#
# For binary values, 0 is disabled, 1 is enabled. See sysctl(8) and
# sysctl.conf(5) for more details.
# Controls IP packet forwarding
net.ipv4.ip_forward = 0
# Controls source route verification
net.ipv4.conf.default.rp_filter = 1
# Do not accept source routing
net.ipv4.conf.default.accept_source_route = 0
# Controls the System Request debugging functionality of the kernel
kernel.sysrq = 0
# Controls whether core dumps will append the PID to the core filename
# Useful for debugging multi-threaded applications
kernel.core_uses_pid = 1
# Controls the use of TCP syncookies
net.ipv4.tcp_syncookies = 1
# Controls the maximum size of a message, in bytes
kernel.msgmnb = 65536
# Controls the default maxmimum size of a mesage queue
kernel.msgmax = 65536
# Controls the maximum shared segment size, in bytes
kernel.shmmax = 4294967295
# Controls the maximum number of shared memory segments, in pages
kernel.shmall = 268435456
# Parameters for oracle
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
fs.file-max = 65536
net.ipv4.ip_local_port_range = 1024 65000
net.core.rmem_default = 4194304
net.core.rmem_max = 4194304
net.core.wmem_default = 262144
net.core.wmem_max = 262144
To change the current values of the kernel parameters enter: /sbin/sysctl -p
[root@vl095 ~]# /sbin/sysctl -p
net.ipv4.ip_forward = 0
net.ipv4.conf.default.rp_filter = 1
net.ipv4.conf.default.accept_source_route = 0
kernel.sysrq = 0
kernel.core_uses_pid = 1
net.ipv4.tcp_syncookies = 1
kernel.msgmnb = 65536
kernel.msgmax = 65536
kernel.shmmax = 4294967295
kernel.shmall = 268435456
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
fs.file-max = 65536
net.ipv4.ip_local_port_range = 1024 65000
net.core.rmem_default = 4194304
net.core.rmem_max = 4194304
net.core.wmem_default = 262144
net.core.wmem_max = 262144
Configure owner and groups for Oracle Software

Create groups "oinstall" and "dba". Please check if group-id's 5001 and 5002 are free. If not take some other group-id.
[root@vl095 ~]# groupadd -g 5001 oinstall
[root@vl095 ~]# groupadd -g 5002 dba
Create directory for oracle user "home".
[root@vl095 ~]# mkdir -p /appl/home
[root@vl095 ~]# chgrp oinstall /appl/home
Create "oracle" user:
[root@vl095 ~]# useradd -u 5001 -g oinstall -G dba -c "Oracle Software Owner" -d /appl/home/oracle -s /bin/bash oracle
Change password for user "oracle" (my password is qwertz):
[root@vl095 ~]# passwd oracle
Changing password for user oracle.
New UNIX password:
BAD PASSWORD: it is based on a dictionary word
Retype new UNIX password:
passwd: all authentication tokens updated successfully.

Configure Oracle software owner limits

Add to the /etc/security/limits.conf file:
oracle soft nproc 2047
oracle hard nproc 16384
oracle soft nofile 1024
oracle hard nofile 65536

Add to the /etc/pam.d/login file:
session required /lib/security/pam_limits.so
session required pam_limits.so

Create file "oracle.sh" in directory /etc/profile.d with the following lines:
if [ $USER = "oracle" ]; then
if [ $SHELL = "/bin/ksh" ]; then
ulimit -p 16384
ulimit -n 65536
else
ulimit -u 16384 -n 65536
fi
fi
Connect to Linux Box as "oracle" user and run the "xclok" to check if X11 is working.
[root@vl095 ~]# ssh -Xl oracle vl095
The authenticity of host 'vl095 (192.168.0.95)' can't be established.
RSA key fingerprint is 8d:58:db:80:97:20:7f:e4:5e:cb:8a:10:4b:98:40:5f.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added 'vl095,192.168.0.95' (RSA) to the list of known hosts.
oracle@vl095's password:
/usr/bin/xauth: creating new authority file /appl/home/oracle/.Xauthority
[oracle@vl095 ~]$ xclock
CentOS is now prepared for the installation of the Oracle 11g software.

Regards,
Flavio

KEYWORDS: centos 5, centos 5.0, oracle 11g 11 rel 1, database, set, setting, prepare, install,configure, preparation, installation configuration yum, howto, linux enterprise, unix, os, operating system, rhel 5.0, red hat, redhat, hardware, software, vmware workstation 6 6.0, virtual machine.

11 October 2007

Installing Oracle Workflow 2.6.4 (Oracle 10g) on SLES 10.0

Previous Posts:
Oracle 10g Rel 2 on SLES 10.0
Installation Prepation
Hardware and Software check
Software Installation
Patch Oracle Database Software
Create Database
Install Oracle HTTP Server
Install APEX
Install BI Publisher
Automate Startup/Shutdown

In this post I will try to describe the Installation of Oracle Workflow 2.6.4 (OWF or WF) on SuSE Linux Enterprise Server 10.0 (SLES).

Downloads
The Installation Software:
Oracle Database 10g Companion CD Release 2 (10.2.0.1.0) for Linux x86
Installation Documentation:
Companion CD Installation Guide for Linux x86

To install OWF You must have installed the Oracle Software, created the Oracle Database and Installed the Oracle HTTP Server. This steps are described in previous posts:
Hardware and Software check
Software Installation
Patch Oracle Database Software
Create Database
Install Oracle HTTP Server

First check if You have SLES 10.0 installed with OpenMotif. To do this connect to Your Linux Box as user "root".
vl094:~ # rpm -q openmotif openmotif-2.2.4-21.2

You can find and install the rpm-packages with OpenMotif on SLES 10.0 distribution media:


Make the "oraInventory" log directory writable for the group "oinstall":
vl094:~ # chmod 770 /appl/oracle/oraInventory/logs

The downloaded ZIP file 10201_companion_linux32.zip is unziped in /appl/home/orahs/companion.

Install Oracle Workflow Server
First we have to install Oracle Workflow Server as user oracle (Unix owner of Oracle Database Software).
Connect to Linux Box as user Oracle
vl094:~ # ssh -Xl oracle vl094
Password:
Last login: Wed Oct 3 23:38:30 2007 from vl094.fla.net
oracle@vl094:~>
With xclock check if the X-server configuration is OK.
Check the DB configurations parameter:
job_queue_processes, must be at least 10 and
aq_tm_processes must be at least 2.
oracle@vl094:~> sqlplus

SQL*Plus: Release 10.2.0.3.0 - Production on Mon Oct 1 21:16:16 2007

Copyright (c) 1982, 2006, Oracle. All Rights Reserved.

Enter user-name: / as sysdba

Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 - Production
With the Partitioning, OLAP and Data Mining options

SQL> show parameter job

NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
job_queue_processes integer 10
SQL> show parameter aq_

NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
aq_tm_processes integer 0
SQL> alter system set aq_tm_processes=2 scope=both;

System altered.

SQL>
Start Installer:
oracle@vl094:~> ../orahs/companion/runInstaller
Starting Oracle Universal Installer...

Checking installer requirements...

Checking operating system version: must be redhat-3, SuSE-9, redhat-4, UnitedLinux-1.0, asianux-1 or asianux-2
Passed


All installer requirements met.

Preparing to launch Oracle Universal Installer from /tmp/OraInstall2007-10-01_08-21-09PM. Please wait ...oracle@vl094:~> Oracle Universal Installer, Version 10.2.0.1.0 Production
Copyright (C) 1999, 2005, Oracle. All rights reserved
.Form : WelcomePress: Next
--------------------------
Form: Select a Product to Install
Select second option: Oracle Database 10g Products 10.2.0.1.
Press: Next
--------------------------
Form: Specify Home Details
For Destination enter:
Name: OraDb10g_home1
Path: /appl/oracle/product/10.2.0.0/db_1
Press: Next
--------------------------
Form: Product-Specific Prerequiste Checks
Press: Next
--------------------------
Form: Summary
Press: Install
--------------------------
Form: Install
Wait until Installation finished.
Press: Next
--------------------------
Form: End of Installation
Press: Exit
--------------------------
Form: Exit
Press: Yes

Now I have configured and installed the Oracle Worflow in the Database using Oracle Workfow Configuration Assistant:
oracle@vl094:~> /appl/oracle/product/10.2.0/db_1/wf/install/wfinstall.csh
Workflow Configuration Assistant - Linux
4
Parameter "wfdir" = /appl/oracle/product/10.2.0/db_1/wf
Parameter "orahome" = /appl/oracle/product/10.2.0/db_1
WorkflowCA: /appl/oracle/product/10.2.0/db_1/wf/install/workflow.log
WorkflowCA:
WorkflowCA: Workflow Configuration in progress...
WorkflowCA: Mon Oct 01 21:18:25 CEST 2007
WorkflowCA:
WorkflowCA: Screen width -1024-, screen height -768-
WorkflowCA:
WorkflowCA: Graphics User Interface mode
WorkflowCA:
WorkflowCA:
Form: Oracle Workflow Configuration Assistant

Enter following information:
Install Option: Server Only
Workflow Account: owf_mgr
Workflow Password: qwertz
SYS Password: qwertz
TNS Connect Descriptor: (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=vl094.fla.net)(PORT=1521))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=DB094.fla.net)))
Leave other selections empty and Language Selection must be set to US.
Press: Submit
--------------------
Form: Workflow Configuration Assistant
Press: OK

Now I have added the German language to Oracle Workflow.
oracle@vl094:~> /appl/oracle/product/10.2.0/db_1/wf/install/wfinstall.csh
Workflow Configuration Assistant - Linux
4
Parameter "wfdir" = /appl/oracle/product/10.2.0/db_1/wf
Parameter "orahome" = /appl/oracle/product/10.2.0/db_1
WorkflowCA: /appl/oracle/product/10.2.0/db_1/wf/install/workflow.log
WorkflowCA:
WorkflowCA: Workflow Configuration in progress...
WorkflowCA: Mon Oct 01 21:18:25 CEST 2007
WorkflowCA:
WorkflowCA: Screen width -1024-, screen height -768-
WorkflowCA:
WorkflowCA: Graphics User Interface mode
WorkflowCA:
WorkflowCA:
Form: Oracle Workflow Configuration Assistant

Enter following information:
Install Option: Add Language
Workflow Account: owf_mgr
Workflow Password: qwertz
SYS Password: qwertz
TNS Connect Descriptor: (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=vl094.fla.net)(PORT=1521))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=DB094.fla.net)))
Language Selection: D
Press: Submit.
------------------------------
Form: Workflow Configuration Assistant
Press: OK.

Install Oracle Workflow middle-tier components.
Press: OK.
The Installation of Oracle Workflow middle-tier components is executed from Linux User orahs - owner of Oracle HTTP Server software installation.
vl094:~ # ssh -Xl orahs vl094
Password:
Last login: Sun Sep 30 00:09:17 2007 from vl094.fla.net
orahs@vl094:~> export DISPLAY=:0.0
orahs@vl094:~> xclock
orahs@vl094:~>

vl094:~ # chmod 770 /appl/oracle/oraInventory/logs/

orahs@vl094:~> ./companion/runInstaller
Starting Oracle Universal Installer...

Checking installer requirements...

Checking operating system version: must be redhat-3, SuSE-9, redhat-4, UnitedLinux-1.0, asianux-1 or asianux-2
Passed


All installer requirements met.

Preparing to launch Oracle Universal Installer from /tmp/OraInstall2007-10-01_08-51-33PM. Please wait ...orahs@vl094:~> Oracle Universal Installer, Version 10.2.0.1.0 Production
Copyright (C) 1999, 2005, Oracle. All rights reserved.

Form: Welcome
Press: Next
--------------------------
Form: Select a Product to Install
Select: Oracle 10g Companion Products 10.2.0.1.0
Press: Next
--------------------------
Form: Specify Home Details
Enter following informations:
Name: OraDb10g_home
Path: /appl/orahs/product/10.2.0/db_1
Press: Next
--------------------------
Form: Available product Components
Select Oracle Workflow Middle Tier 2.6.4.0.0
Press: Next
--------------------------
form: Product-Specific prerequiste Check
In this Oracle Home is installed Oracle HTTP Server. This two products is allowed to install in the same Oracle Home.
Select Checking for Oracle Home incompatibilities - so I ignored this recommendation.
Press: Next
--------------------------
Form: Oracle Workflow Middle Tier Configration
Enter following mandatory Informations:
Workflow Schema: OWF_MGR
DB Hostname: vl094.fla.net
Port Number: 1521
Oracle SID: DB094
Press: Next
--------------------------
Form: Oracle Workflow Middle Tier Configuration
Enter Password for OWF_MGR: qwertz
Press: Next
--------------------------
Form: Summary
Press: Install
--------------------------
Form: Install

Wait until all components installed.
--------------------------
Form End of Installation
Press: Exit
----------------------------
Form: Exit
Press: Yes

After this Installation I compiled the invalid Object. You must be connected to Linux Box as user oracle and to the database as user SYS.
Start sqlplus and execute the SQL script: @?/rdbms/admin/utlrp.sql
Using unzip Linux utility unzip extract the "doc" directory from $ORACLE_HOME/wf/wfdoc.zip.
We will need this file for Oracle Workflow HTML Help.
oracle@vl094:/appl/oracle/product/10.2.0/db_1/wf> unzip wfdoc.zip
Archive: wfdoc.zip
replace doc/US/wf/accmon.htm? [y]es, [n]o, [A]ll, [N]one, [r]ename: y
inflating: doc/US/wf/accmon.htm
replace doc/US/wf/accmon01.htm? [y]es, [n]o, [A]ll, [N]one, [r]ename: A
To start Oracle Workflow use:
oracle@vl094:~> /appl/oracle/product/10.2.0/db_1/wf/admin/wfmgrstart.csh
To stop Oracle Workflow use:
oracle@vl094:~> /appl/oracle/product/10.2.0/db_1/wf/admin/wfmgrstop.csh

Try to connect with Oracle Workflow Manager: http://vl094.fla.net:7780/pls/wf/wfa_html.home

The Oracle Workflow - Server and Middle Tier - are installed!

Regards,
Flavio

28 September 2007

Automate Startup/Shutdown of Oracle Products on SLES 10.0

Previous Posts:
Oracle 10g Rel 2 on SLES 10.0
Installation Prepation
Hardware and Software check
Software Installation
Patch Oracle Database Software
Create Database
Install Oracle HTTP Server
Install APEX
Install BI Publisher
Next Posts:
Install Oracle Workflow

Automated Startup and Shutdown of installed Oracle products will be implemented using shell script "dbora". This script is based on description that You can find in Oracle Metalink.

First check that the file /etc/oratab contains entry for the Database that You like to Start/shut:
vl094:~ # cat /etc/oratab
DB094:/appl/oracle/product/10.2.0/db_1:Y


For the Start/Shut for the Database and the Listener I will use scripts distributed with Oracle DB Software located in $ORACLE_HOME/bin:
dbstart $ORACLE_HOME - to start the database and listener and
dbshut $ORACLE_HOME - to stop the database and listener. You must remember that this two scripts requires one parameter, this parameter is ORACLE_HOME.

You must save the Script in /etc/init.d.
Set scripts permissions:
vl094:~ # cd /etc/init.d/
vl094:/etc/init.d # chmod 755 dbora

Register Service:
vl094:/etc/init.d # /sbin/chkconfig --add dbora
dbora 0:off 1:off 2:off 3:on 4:off 5:on 6:off


"chkconfig" will create symbolic links under rc3.d and rc5.d to /etc/init.d/dbora.

SLES "insserv" utility (used from "chkconfig") uses the following header to define run level and start/shut order:
     6  ### BEGIN INIT INFO
7 # Provides: dbora
8 # Required-Start: $local_fs $remot_fs $netdeamons
9 # Required-Stop:
10 # Default-Start: 3 5
11 # Default-Stop: 0 1 2 3 4 5 6
12 # Description: start/shutdown of Database and other Oracle Products
13 ### END INIT INFO
Script to start BI Publisher is not running in background after the start. So I started the BI Publisher Script with "nohup" and in background with "&".
After the start I simply wait for 60 seconds, and then continue with the next step. Naturally, there is better methods to check if the process is started, but for me it works perfectly.
    46      # oracle bi publisher
47 echo "Starting BI Publisher..."
48 su - $OBIP_USER -c "nohup $OBIP_HOME/oc4j_bi/bin/oc4j -start
>>$OBIP_HOME/startbip.log &"

49 RET_BIP=$?
50 echo "Sleeping 60 sec..."
51 sleep 60

I noticed that the Oracle HTTP Server processes need sometimes about a minute to startup - so I am "sleeping"for 60 seconds after start of Oracle HTTP Server. Not so elegant - but in my style.
    55      # oracle http server
56 su - $OHS_USER -c "$OHS_HOME/opmn/bin/opmnctl startall"
57 RET_HS=$?
58 echo "Sleeping 60 sec..."
59 sleep 60
The "touch" command would create a file at the startup of the database. The Oracle process would now have a lock on the above file which should be released at time of OS reboot. The script which is called by 'inittab' whenever the run level is changed, looks for the existence of a lock file in "/var/lock/subsys". If this lock file does not exist, the stop command will not be issued.
    60      # touch lock file
61 touch /var/lock/subsys/dbora

I added simple logging - log file will be located in /tmp/dbora.log

Here is the complete Script:

vl094:/etc/init.d # cat -n dbora

1 #! /bin/sh
2 #
3 # Author: Flavio, Modified script "dbora"
found on "metalink.oracle.com"

4 # Homepage: OracleByFla.blogspot.com
5 #
6 ### BEGIN INIT INFO
7 # Provides: dbora
8 # Required-Start: $local_fs $remot_fs $netdeamons
9 # Required-Stop:
10 # Default-Start: 3 5
11 # Default-Stop: 0 1 2 3 4 5 6
12 # Description: start/shutdown of Database
and other Oracle Products

13 ### END INIT INFO
14
15 #
16 #
17 # home's of oracle products
18 #
19 # oracle db, listener, em
20 ODB_HOME="/appl/oracle/product/10.2.0/db_1"
21 # oracle http server
22 OHS_HOME="/appl/orahs/product/10.2.0/db_1"
23 # oracle bi publisher
24 OBIP_HOME="/appl/orabip/OraHome_1"
25 #
26 # operating system users, owners of oracle
software products

27 #
28 # oracle db, listener, em
29 ODB_USER="oracle"
30 # oracle http server
31 OHS_USER="orahs"
32 # oracle bi publisher
33 OBIP_USER="orabip"
34
35 #
36 # oradb log file
37 #
38 DBORALOG="/tmp/dbora.log"
39
40 case "$1" in
41 start)
42 echo "`date` Begin of Oracle Start Block
43 # oracle database and listener
44 su - $ODB_USER -c "$ODB_HOME/bin/dbstart $ODB_HOME"
45 RET_DB=$?
46 # oracle bi publisher
47 echo "Starting BI Publisher..."
48 su - $OBIP_USER -c "nohup $OBIP_HOME/oc4j_bi/bin/oc4j -start
>>$OBIP_HOME/startbip.log &"

49 RET_BIP=$?
50 echo "Sleeping 60 sec..."
51 sleep 60
52 # oracle em
53 su - $ODB_USER -c "$ODB_HOME/bin/emctl start dbconsole"
54 RET_EM=$?
55 # oracle http server
56 su - $OHS_USER -c "$OHS_HOME/opmn/bin/opmnctl startall"
57 RET_HS=$?
58 echo "Sleeping 60 sec..."
59 sleep 60
60 # touch lock file
61 touch /var/lock/subsys/dbora
62 RET_TOUCH=$?
63 echo "`date` Start Returns: RET_DB=$RET_DB
RET_BIP=$RET_BIP RET_HS=$RET_HS RET_EM=$RET_EM
RET_TOUCH=$RET_TOUCH" | tee -a $DBORALOG

64 echo "End of Oracle Start Block"
65 ;;
66 stop)
67 echo "`date` Begin of Oracle Stop Block..." | tee -a $DBORALOG
68 # oracle http server
69 su - $OHS_USER -c "$OHS_HOME/opmn/bin/opmnctl stopall"
70 RET_HS=$?
71 # oracle bi publisher
72 echo "Stopping BI Publisher..."
73 su - $OBIP_USER -c "$OBIP_HOME/jdk/bin/java
-jar $OBIP_HOME/oc4j_bi/j2ee/home/admin.jar ormi://localhost:20002
oc4jadmin qwertz1 -shutdown force >>$OBIP_HOME/stopbip.log"

74 RET_BIP=$?
75 # oracle database and listener
76 su - $ODB_USER -c "$ODB_HOME/bin/dbshut $ODB_HOME"
77 RET_DB=$?
78 # oracle em
79 su - $ODB_USER -c "$ODB_HOME/bin/emctl stop dbconsole"
80 RET_EM=$?
81 # remove lock file
82 rm -f /var/lock/subsys/dbora
83 RET_RM=$?
84 echo "`date` Stop Returns: RET_DB=$RET_DB
RET_BIP=$RET_BIP RET_HS=$RET_HS
RET_EM=$RET_EM RET_RM=$RET_RM" | tee -a $DBORALOG

85 echo "End of Oracle Stop Block"
86 ;;
87 restart)
88 echo "`date` Begin of Oracle Restart Block.." | tee -a $DBORALOG
89 $0 stop
90 RET_STOP=$?
91 $0 start
92 RET_START=$?
93 echo "`date` Restart Returns `date`: RET_STOP=$RET_STOP
RET_START=$RET_START" | tee -a $DBORALOG

94 echo "End of Oracle Restart Block"
95 ;;
96 *)
97 echo "Usage: $0 {start|stop|restart}"
98 exit 1
99 ;;
100 esac
101
102 exit $?
Here is standard output of my "start" test:
vl094:/etc/init.d # ./dbora start
Sat Sep 29 21:51:01 CEST 2007 Begin of Oracle Start Block...
Processing Database instance "DB094": log file /appl/oracle/product/10.2.0/db_1/startup.log
Starting BI Publisher...
Sleeping 60 sec...
TZ set to Europe/Vienna
Oracle Enterprise Manager 10g Database Control Release 10.2.0.3.0
Copyright (c) 1996, 2006 Oracle Corporation. All rights reserved.
http://vl094.fla.net:1158/em/console/aboutApplication
Starting Oracle Enterprise Manager 10g Database Control ........................ started.
------------------------------------------------------------------
Logs are generated in directory /appl/oracle/product/10.2.0/db_1/vl094.fla.net_DB094/sysman/log
opmnctl: starting opmn and all managed processes...
Sleeping 60 sec...
Sat Sep 29 21:54:57 CEST 2007 Start Returns: RET_DB=0 RET_BIP=0 RET_HS=0 RET_EM=0 RET_TOUCH=0
End of Oracle Start Block

Here is standard output of my "stop" test:
vl094:/etc/init.d # ./dbora stop
Sat Sep 29 21:55:13 CEST 2007 Begin of Oracle Stop Block...
opmnctl: stopping opmn and all managed processes...
Stopping BI Publisher...
Processing Database instance "DB094": log file /appl/oracle/product/10.2.0/db_1/shutdown.log
TZ set to Europe/Vienna
Oracle Enterprise Manager 10g Database Control Release 10.2.0.3.0
Copyright (c) 1996, 2006 Oracle Corporation. All rights reserved.
http://vl094.fla.net:1158/em/console/aboutApplication
Stopping Oracle Enterprise Manager 10g Database Control ...
... Stopped.
Sat Sep 29 21:59:09 CEST 2007 Stop Returns: RET_DB=0 RET_BIP=0 RET_HS=0 RET_EM=0 RET_RM=0
End of Oracle Stop Block


Regards,
Flavio




25 September 2007

Installing Oracle BI Publisher on SLES 10.0

Previous Posts:
Oracle 10g Rel 2 on SLES 10.0
Installation Prepation
Hardware and Software check
Software Installation
Patch Oracle Database Software
Create Database
Install Oracle HTTP Server
Install APEX
Next Posts:
Automate Startup/Shutdown
Install Oracle Workflow

For the Installation of Oracle BI Publisher I have created one more Linux user: orabip.
This User will be the owner of BI Publisher Software.

NOTE: Before You start this Installation please stop the Oracle Enterprise Manager with the command "emctl stop dbconsole"
and stop the Oracle HTTP Server using the command "$ORACLE_HOME/opmn/bin/opmnctl stop"

For the Architecture and background of PDF printing in APEX 3.0 plase consult following document:
http://www.oracle.com/technology/products/database/application_express/html/configure_printing.html
Please ignore the statement: At this time, the standalone BI Publisher download for Linux does not seem to be working ...
It's working now!

Connect to Linux Box as root and execute following commands:
vl094:~ # useradd -u 5003 -g oinstall -G dba -d /appl/home/orabip -s /bin/bash orabip
vl094:~ # mkdir /appl/orabip
vl094:~ # mkdir /appl/home/orabip
vl094:~ # chmod 775 /appl/home/orabip
vl094:~ # chown orabip:oinstall /appl/orabip /appl/home/orabip
vl094:~ # passwd orabip
Changing password for orabip.
New Password:
Bad password: too simple
Reenter New Password:
Password changed.


Download the Oracle BI Publisher installation Files and Installation Documentation:
BI Publisher 10.1.3.3.for Linux x86
The downloaded file is marked with "redhat" - ignore this - it works well under SLES to!

Connect to Linux Box as user orabip:
vl094:~ # ssh -Xl orabip vl094
Password:
/usr/X11R6/bin/xauth: creating new authority file /appl/home/orabip/.Xauthority


Using cpio You can get the Package content:
cpio -idmv < bipublisher_linux_x86_redhat_101330_disk1.cpio

Do not create or add any environment variable in the orapib's .bash_profile file. Change directory to Installation Directory:
orabip@vl094:~> cd RH_Linux/Oracle_Business_Intelligence_Publisher_Standalone/install/

Start Installer:
orabip@vl094:~/RH_Linux/Oracle_Business_Intelligence_Publisher_Standalone/install> ./runInstaller
Starting Oracle Universal Installer...

Checking installer requirements...

Checking operating system version: must be redhat-2.1AS, redhat-3, redhat-4, redhat-5, suse-9, suse-10, SuSE-9 or SuSE-10
Passed


All installer requirements met.

Preparing to launch Oracle Universal Installer from /tmp/OraInstall2007-09-25_09-43-09PM. Please wait ...orabip@vl094:~/RH_Linux/Oracle_Business_Intelligence_Pul> Oracle Universal Installer, Version 10.1.0.6.0 Production
Copyright (C) 1999, 2007, Oracle. All rights reserved.


Form: Welcome.

Press "Next"
--------------------------------------------------------------
Form: File LocationChange Path for BPHome1 to /appl/orabip/OraHome_1.
Press "Next".
--------------------------------------------------------------
Form: Select Installation Type.
Select Option Basic.
Press "Next"
--------------------------------------------------------------
Form. Choose OC4J Administrator Password.

Enter value qwertz1 for Password.
Press "Next".
--------------------------------------------------------------
Form: Summary.
Press "Install".
--------------------------------------------------------------
Form: Install.
Wait ...
--------------------------------------------------------------
Form : End of Installation.Press "Exit".
--------------------------------------------------------------
Form: Exit.
Press "Yes".

BI Publisher is Installed!

Start with command:

/appl/orabip/OraHome_1/oc4j_bi/bin/oc4j -start

Stop with command (Port 23791 will be changed to 20002):
/appl/orabip/OraHome_1/jdk/bin/java -jar /appl/orabip/OraHome_1/oc4j_bi/j2ee/home/admin.jar ormi://localhost:23791 oc4jadmin qwertz1 -shutdown force

NOTE (Port Conflict):
We have installed 3 different Oracle products that use "oc4j". Now we have "port conflict". I solve this problem changing the server port numbers in jms.xml and rmi.xml.The changes is done for "orahs" and "orabip" users. "oracle" users configuration is not modified.
Changes for user "orahs" - Oracle HTTP Server user.
1) Edit $ORACLE_HOME/j2ee/home/config/jms.xml

Change the standard port value 9127 to 21127.
<jms-server port="21127">
2) Edit $ORACLE_HOME/j2ee/home/config/rmi.xml
Change the standard port value 23791 to 20001.

<rmi-server port="20001" >
3) Edit $ORACLE_HOME/j2ee/home/config/internal-settings.xml
Change the default port values (NOTE: old values are changed to comment!):

<!-- sep-property name="port" value="5555" / -->
<sep-property name="port" value="21555" />
<!-- sep-property name="ssl-port" value="5556" / -->
<sep-property name="ssl-port" value="21556" />
<!-- sep-property name="ssl-client-server-auth-port" value="5557" / -->
<sep-property name="ssl-client-server-auth-port" value="21557" />
4) Edit http-web-site-xml.
Change the default port value from 8888 to 28881.

<web-site port="28881" display-name="OC4J 10g (10.0.2) HTTP Web Site">
Changes for user "orabip" - Oracle BI Publisher user.
1) Edit /appl/orabip/OraHome_1/oc4j_bi/j2ee/home/config/jms.xml
Change the standard port value 9127 to 22127.

<jms-server port="22127">
2) Edit /appl/orabip/OraHome_1/oc4j_bi/j2ee/home/config/rmi.xml
Change the standard port value 23791 to 20002.

<rmi-server
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="http://xmlns.oracle.com/oracleas/schema/rmi-server-10_0.xsd"
port="20002"
ssl-port = "23943"
schema-major-version="10"
schema-minor-version="0"
>

Command to stop BI Publisher is changed (new "rmi" port!):
/appl/orabip/OraHome_1/jdk/bin/java -jar /appl/orabip/OraHome_1/oc4j_bi/j2ee/home/admin.jar ormi://localhost:20002 oc4jadmin qwertz1 -shutdown force

NOTE (Oracle Notification Server "netstat spam").
After Oracle HTTP Server Start (using opmnctl startall) I noticed that the system decreased performance. Linux command "netstat -a" show me about 54000 lines of output(!?!) - normaly is about 380, mostly with the content:
tcp 0 0 127.0.0.1:49463 127.0.0.1:6113 TIME_WAIT
tcp 0 0 127.0.0.1:49462 127.0.0.1:6113 TIME_WAIT
tcp 0 0 127.0.0.1:49461 127.0.0.1:6113 TIME_WAIT
tcp 0 0 127.0.0.1:49460 127.0.0.1:6113 TIME_WAIT
tcp 0 0 127.0.0.1:49459 127.0.0.1:6113 TIME_WAIT
etc etc

I added in "listener.ora" one row at end of file:
SUBSCRIBE_FOR_NODE_DOWN_EVENT_LISTENER=OFF
This works! The "line count" from netstat -a is about 380 now.


Don't forget to startup the stopped processes using
"emctl start dbconsole;" and
"$ORACLE_HOME/opmn/bin/opmnctl start"

Now we can configure Application Express to use BI Publisher for PDF Printing:
  • Connect to APEX Administration Page on http://vl094.fla.net:7780/pls/apex/apex_admin.
  • Select option"Manage Service".
  • Under "Mnage Environment Settings" select "Instance setings".
  • On "Instance Settings" Form select option "Report Printing".
You are now on "Report Printing" Form.

Select BI Publisher "Advanced Support".
Enter following values:
Print Server Host address: vl094.fla.net
Print server Port: 9704
Print server Script: /xmlpserver/convert.
Press "Apply Changes".

Congratulation: You are ready to use PDF Printig with APEX!

Here You can see a simple "PDF Printing in APEX" video demonstration.








Regards,
Flavio