Skip to main content

11.5.10.2 Cloning/Migration from Linux 4 to Linux 5

Lately i wanted to try out an upgrade from 11.5.10.2 to R12.1.1. For this i needed to clone APPS from Linux 4 to Linux 5. I tried to search for some document on metalink but nothing concrete. All i got was 287453.1 Oracle Applications 11.5.10 - Installation Update Notes for Linux x86, Solaris SPARC, MS Windows, HP-UX PA-RISC, HP-Tru64, IBM AIX - B13590-01

Apart from this they do not even have a document on metalink/support portal certification matrix. So here it is.

OS Version:

Source:
Red Hat Enterprise Linux AS release 4 (Nahant)
2.6.9-5.ELsmp #1 SMP Wed Jan 5 19:30:39 EST 2005 i686 i686 i386 GNU/Linux

Destination:

Red Hat Enterprise Linux Server release 5.3 (Tikanga)
2.6.18-128.el5 #1 SMP Wed Dec 17 11:42:39 EST 2008 i686 i686 i386 GNU/Linux



DB Cloning:
--------------------------

Copy all the files from source to destination. Set the following env variables.
FILES: ORACLE_HOME, ALL DB FILES, CONTROL FILES, REDO FILES


Now set the env to start the database, As an example following was my case.

export ORACLE_HOME=/APPS/proddb/9.2.0
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib:/usr/local/lib
export ORACLE_SID=PROD

1. sqlplus '/as sysdba'
2. startup nomount
3. Create control file
4. alter database open
5. Modify listener.ora and tnsnames.ora if there is a change in the path/sid from source to destination and start the listener

Try logging in as apps and guest to make sure the database is intact.

Issues with DB Cloning
-------------------------


ISSUE1:


sqlplus: error while loading shared libraries: libdl.so.2: cannot open shared object file: No such file or directory

PATH=/APPS/proddb/9.2.0/bin:/usr/bin:/usr/sbin:/APPS/proddb/9.2.0/jre/1.4.2/bin:/usr/ccs/bin:/bin:/usr/bin/X11:/usr/local/bin:$PATH

Solution:
export LD_ASSUME_KERNEL=''

This should be set for RHEL 5 and it is a recommended parameter for R12 or 11.5.10.2 installation.



Apps Cloning:
-----------------------------



A. Run preclone on source.
B. Copy all the files APPL_TOP(prodappl), COMMON_TOP(prodcomn), 806HOME and iASHOME(prodora) to destination.
C. Run adcfgclone

Issues starting from running adcfgclone

1. cc not available.
cp /usr/bin/gcc323 /usr/bin/gcc

2. Problem with KSH
Checking for ar... found - /usr/bin/ar
Checking for ksh...
Unable to find 'kshell' in path
Unable to locate all utilities with system path.
PATH = /usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin:/home/applmgr/bin

Solution:
export KSH_VERSION='@(#)PD KSH v5.2.14 99/07/13.2'

3. Problem with lib files

/APPS/prodcomn/clone/jre/bin/i386/native_threads/java: error while loading shared libraries: libstdc++-libc6.1-1.so.2: cannot open shared object file: No such file or directory

Solution:

[root@onlinedba-acs2 lib]# ls -ltr libstdc++-3*
-rwxr-xr-x 1 root root 259532 Aug 21 2006 libstdc++-3-libc6.2-2-2.10.0.so
[root@onlinedba-acs2 lib]# ln -s libstdc++-3-libc6.2-2-2.10.0.so libstdc++-libc6.1-1.so.2

4.
/APPS/prodcomn/clone/jre/bin/i386/native_threads/java: error while loading shared libraries: libstdc++-libc6.1-1.so.2: cannot open shared object file: No such file or directory

sqlplus: error while loading shared libraries: libclntsh.so.9.0: cannot open shared object file: No such file or directory

SET LD_ASSUME_KERNEL='';

5. Error

ERROR: InDbCtxFile.uploadCtx() : Exception : Error executng BEGIN fnd_gsm_util.append_ctx_fragment(?,?,?); END;: 1; Oracle error -25153: ORA-25153: Temporary Tablespace is Empty has been detected in FND_GSM_UTIL.APPEND_CTX_FRAGMENT.
oracle.apps.ad.autoconfig.oam.InDbCtxFileException: Error executng BEGIN fnd_gsm_util.append_ctx_fragment(?,?,?); END;: 1; Oracle error -25153: ORA-25153: Temporary Tablespace is Empty has been detected in FND_GSM_UTIL.APPEND_CTX_FRAGMENT.



ORA-25153: Temporary Tablespace is Empty has been detected in FND_GSM_UTIL.APPEND_CTX_FRAGMENT.


SQL> ALTER DATABASE DEFAULT TEMPORARY TABLESPACE temp;

Database altered.

SQL> SELECT * FROM DATABASE_PROPERTIES where PROPERTY_NAME='DEFAULT_TEMP_TABLESPACE';

PROPERTY_NAME
------------------------------
PROPERTY_VALUE
--------------------------------------------------------------------------------
DESCRIPTION
--------------------------------------------------------------------------------
DEFAULT_TEMP_TABLESPACE
TEMP
ID of default temporary tablespace


SQL>
SQL> select TABLESPACE_NAME, BYTES_USED, BYTES_FREE from V$TEMP_SPACE_HEADER;

no rows selected

SQL>
SQL> select * from V$TEMPFILE ;

no rows selected

SQL> ALTER DATABASE TEMPFILE '/oradata/temp02.dbf' DROP INCLUDING DATAFILES;
ALTER DATABASE TEMPFILE '/oradata/temp02.dbf' DROP INCLUDING DATAFILES
*
ERROR at line 1:
ORA-01516: nonexistent log file, datafile, or tempfile "/oradata/temp02.dbf"


SQL> ALTER TABLESPACE temp ADD TEMPFILE '/APPS/proddata/temp001.dbf' SIZE 100M;

Tablespace altered.

SQL> select TABLESPACE_NAME, BYTES_USED, BYTES_FREE from V$TEMP_SPACE_HEADER;

TABLESPACE_NAME BYTES_USED BYTES_FREE
------------------------------ ---------- ----------
TEMP 131072 104726528




6. Error

touch: error while loading shared libraries: librt.so.1: cannot open shared object file: No such file or directory

sqlplus: error while loading shared libraries: libdl.so.2: cannot open shared object file: No such file or directory

mkdir: error while loading shared libraries: libc.so.6: cannot open shared object file: No such file or directory

/APPS/prodcomn/util/java/1.4/j2sdk1.4.2_04/bin/java: error while loading shared libraries: libpthread.so.0: cannot open shared object file: No such file or directory




Solution:
---------

cd $AD_TOP/bin

edit file adgetlnxver.sh

Change LD_ASSUME_KERNEL='' in the below section

if [ ${setflag}x = "x" -a $os = "RH" ]; then
LD_ASSUME_KERNEL="2.4.19"
export LD_ASSUME_KERNEL
fi



7. Error while starting apache

Syntax error on line 257 of /APPS/prodora/iAS/Apache/Apache/conf/httpd.conf:
Cannot load /APPS/prodora/iAS/Apache/Apache/libexec/mod_auth_dbm.so into server: /APPS/prodora/iAS/Apache/Apache/libexec/mod_auth_dbm.so: undefined symbol: dbm_fetch
/APPS/prodora/iAS/Apache/Apache/bin/apachectl start: httpd could not be started
Syntax error on line 254 of /APPS/prodora/iAS/Apache/Apache/conf/httpd_pls.conf:
Cannot load /APPS/prodora/iAS/Apache/Apache/libexec/mod_rewrite.so into server: /APPS/prodora/iAS/Apache/Apache/libexec/mod_rewrite.so: undefined symbol: dbm_fetch
/APPS/prodora/iAS/Apache/Apache/bin/apachectl start: httpd could not be started



Run the following command:

nm -D /usr/lib/libdb.so.3 | grep dbm_fetch

If this does not return just dbm_fetch then there is an issue.

Solution:
---------

Download and apply patch 6078836 from metalink
unlink libdb.so.3
ln -s libdb.so.3 libdb.so.2

Comments

Anonymous said…
hi, new to the site, thanks.
Anonymous said…
Hi analyzing this topic was many digestive , reviews like this give motivation who reads this topic!!!

Popular posts from this blog

SQL Interview Questions on Subqueries

SUB Queries:
1. List the employees working in research department 2. List employees who are located in New York and Chicago
3. Display the department name in which ANALYSTS are working
4. Display employees who are reporting to JONES
5. Display all the employees who are reporting to Jones Manager
6. Display all the managers in SALES and ACCOUNTING department
7. Display all the employee names in Research and Sales Department who are having at least 1 person reporting to them
8. Display all employees who do not have any reportees
9. List employees who are having at least 2 reporting
10. List the department names which are having more than 5 employees
11. List department name having at-least 3 salesman
12. List employees from research and accounting having at-least 2 reporting
13. Display second max salary
14. Display 4th max salary
15. Display 5th max salary  -- Answer for nth Max Salary
Co-Related Subqueries:
16. Write a query to get 4th max salary from EMP table
17. Write a query to get 2nd…

Answers for SUB Queries

1. SQL> select empno, ename from emp where deptno=(select deptno from dept where dname='RESEARCH');


2. SQL> select empno, ename from emp where deptno in (select deptno from dept where loc in ('NEW YORK','CHICAGO'));

3. SQL> select dname from dept where deptno in ( select deptno from emp where job ='ANALYST');

4. SQL> select empno, ename, mgr from emp where mgr = (select empno from emp where ename='JONES');

5. SQL> select empno, ename, mgr from emp where mgr = (select mgr from emp where ename='JONES')

6. SQL> select empno, ename, job from emp where deptno in ( select deptno from dept where dname in ('SALES','ACCOUNTING'))

7. SQL> select empno, ename, job from emp where deptno in ( select deptno from dept where dname in ('SALES','RESEARCH')) and empno in (select mgr from emp)

8. SQL> select empno, ename from emp where empno not in ( select mgr from emp where mgr is not null)

9. select…

'Linux-x86_64 Error: 28: No space left on device' While trying to start the database -- Error

SQL> startup mount pfile='/tmp/initdlfasp12.ora'
ORA-27102: out of memory
Linux-x86_64 Error: 28: No space left on device


This as you can see is on Linux x86 with 64 bit processor. We got this error after we changed SGA on 10gR2 database. So was sure that this is something to do with the OS.

Parameters to check for this are shmall.

shmall is the total amount of shared memory, in pages, that the system can use at one time.

$cat /proc/sys/kernel/shmmax
53687091200

$ getconf PAGE_SIZE
4096

As per Oracle SHMALL should be set to the total amount of physical RAM divided by page size.

Our system has 64GB memory, so change kernel.shmall = 1024 * 1024 * 1024 * 64 / 4096 = 16777216


Once this value is calculated you can modify Linux system configuration file directly.

$ su - root
vi /etc/sysctl.conf file:
kernel.shmall=16777216

and

# sysctl -p

Once this is done the database was started without any problem.