Restoring RMAN Oracle 10g Backup in Oracle 11g - oracle

I have the RMAN full database backup of oracle 10g (10.2.0.3) on Sun Solaris OS which I want to restore on oracle 11g (11.2.0.3) on Linux OS. The backup pieces were transferred to the oracle 11g server manually in binary mode. The Oracle 11g is installed on Linux OS. I have only the RMAN backup and no access to the primary database from where the backup has been taken.
-rwxrwxr-x 1 mepc dba 36356096 Jul 16 14:49 snapcf_MEPC.f
-rwxrwxr-x 1 mepc dba 166028800 Jul 16 15:29 MEPC_full_backup_MEPC_nnnbkn9f_1_1
-rwxrwxr-x 1 mepc dba 169567744 Jul 16 15:29 MEPC_full_backup_MEPC_nmnbkn9f_1_1
-rwxrwxr-x 1 mepc dba 164813824 Jul 16 15:39 MEPC_full_backup_MEPC_nonbkn9f_1_1
-rwxrwxr-x 1 mepc dba 144025600 Jul 16 16:06 MEPC_full_backup_MEPC_nqnbkn9f_1_1
-rwxrwxr-x 1 mepc dba 168576512 Jul 16 16:09 MEPC_full_backup_MEPC_npnbkn9f_1_1
-rwxrwxr-x 1 mepc dba 168649216 Jul 16 17:33 MEPC_full_backup_MEPC_o5nbkpvv_1_1
-rwxrwxr-x 1 mepc dba 162847232 Jul 16 17:34 MEPC_full_backup_MEPC_o6nbkpvv_1_1
-rwxrwxr-x 1 mepc dba 167351808 Jul 16 17:35 MEPC_full_backup_MEPC_o7nbkpvv_1_1
-rwxrwxr-x 1 mepc dba 166838272 Jul 16 17:36 MEPC_full_backup_MEPC_o8nbkpvv_1_1
-rwxrwxr-x 1 mepc dba 166876160 Jul 16 17:37 MEPC_full_backup_MEPC_o9nbkpvv_1_1
-rwxrwxr-x 1 mepc dba 327606272 Jul 16 17:54 MEPC_full_backup_MEPC_o4nbknav_1_1
-rwxrwxr-x 1 mepc dba 549658624 Jul 16 18:26 MEPC_full_backup_MEPC_o2nbknav_1_1
-rwxrwxr-x 1 mepc dba 162984448 Jul 16 18:28 MEPC_full_backup_MEPC_oanbkpvv_1_1
-rwxrwxr-x 1 mepc dba 163567616 Jul 16 18:29 MEPC_full_backup_MEPC_obnbkpvv_1_1
-rwxrwxr-x 1 mepc dba 161380352 Jul 16 18:29 MEPC_full_backup_MEPC_ocnbkpvv_1_1
-rwxrwxr-x 1 mepc dba 1072275456 Jul 18 13:52 MEPC_full_backup_MEPC_o3nbknav_1_1
-rwxrwxr-x 1 mepc dba 1813348352 Jul 18 17:00 MEPC_full_backup_MEPC_o1nbknav_1_1
-rwxrwxr-x 1 mepc dba 36438016 Jul 25 15:45 controlfile_bkup_MEPC_c-1469445140-20120522-09
the backup is taken in the above format. I know the ORACLE_SID and did of the database from which the backup has been taken.
whenever I tried the following command
mepc#tcstctmatson:/mepc_backup/May22fullbkp$ rman target /
Recovery Manager: Release 11.2.0.3.0 - Production on Tue Jul 31 12:14:54 2012
Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.
connected to target database: MEPC (DBID=1595278680)
RMAN> shutdown;
using target database control file instead of recovery catalog
database closed
database dismounted
Oracle instance shut down
RMAN> startup nomount;
connected to target database (not started)
Oracle instance started
Total System Global Area 1071333376 bytes
Fixed Size 1349732 bytes
Variable Size 620758940 bytes
Database Buffers 444596224 bytes
Redo Buffers 4628480 bytes
RMAN> restore spfile to '$ORACLE_HOME/dbs/initMEPC.ora' from autobackup db_recovery_file_dest='/mepc_backup/May22fullbkp' db_name='MEPC';
the following error was notified
Starting restore at 31-JUL-12
using channel ORA_DISK_1
recovery area destination: /mepc_backup/May22fullbkp
database name (or database unique name) used for search: MEPC
channel ORA_DISK_1: no AUTOBACKUPS found in the recovery area
channel ORA_DISK_1: looking for AUTOBACKUP on day: 20120731
channel ORA_DISK_1: looking for AUTOBACKUP on day: 20120730
channel ORA_DISK_1: looking for AUTOBACKUP on day: 20120729
channel ORA_DISK_1: looking for AUTOBACKUP on day: 20120728
channel ORA_DISK_1: looking for AUTOBACKUP on day: 20120727
channel ORA_DISK_1: looking for AUTOBACKUP on day: 20120726
channel ORA_DISK_1: looking for AUTOBACKUP on day: 20120725
channel ORA_DISK_1: no AUTOBACKUP in 7 days found
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of restore command at 07/31/2012 12:22:06
RMAN-06172: no AUTOBACKUP found or specified handle is not a valid copy or piece
i tried recovering the rman backup through catalog also and the following error was notified
List of Files Which Where Not Cataloged
=======================================
File Name: /mepc_backup/May22fullbkp/MEPC_full_backup_MEPC_nonbkn9f_1_1
RMAN-07517: Reason: The file header is corrupted
File Name: /mepc_backup/May22fullbkp/MEPC_full_backup_MEPC_obnbkpvv_1_1
RMAN-07517: Reason: The file header is corrupted
File Name: /mepc_backup/May22fullbkp/MEPC_full_backup_MEPC_ocnbkpvv_1_1
RMAN-07517: Reason: The file header is corrupted
File Name: /mepc_backup/May22fullbkp/MEPC_full_backup_MEPC_o7nbkpvv_1_1
RMAN-07517: Reason: The file header is corrupted
File Name: /mepc_backup/May22fullbkp/MEPC_full_backup_MEPC_o9nbkpvv_1_1
RMAN-07517: Reason: The file header is corrupted
File Name: /mepc_backup/May22fullbkp/MEPC_full_backup_MEPC_nmnbkn9f_1_1
RMAN-07517: Reason: The file header is corrupted
File Name: /mepc_backup/May22fullbkp/MEPC_full_backup_MEPC_nnnbkn9f_1_1
RMAN-07517: Reason: The file header is corrupted
File Name: /mepc_backup/May22fullbkp/MEPC_full_backup_MEPC_o3nbknav_1_1
RMAN-07517: Reason: The file header is corrupted
File Name: /mepc_backup/May22fullbkp/MEPC_full_backup_MEPC_o6nbkpvv_1_1
RMAN-07517: Reason: The file header is corrupted
File Name: /mepc_backup/May22fullbkp/controlfile_bkup_MEPC_c-1469445140-20120522-09
RMAN-07517: Reason: The file header is corrupted
File Name: /mepc_backup/May22fullbkp/MEPC_full_backup_MEPC_npnbkn9f_1_1
RMAN-07517: Reason: The file header is corrupted
File Name: /mepc_backup/May22fullbkp/MEPC_full_backup_MEPC_oanbkpvv_1_1
RMAN-07517: Reason: The file header is corrupted
File Name: /mepc_backup/May22fullbkp/MEPC_full_backup_MEPC_nqnbkn9f_1_1
RMAN-07517: Reason: The file header is corrupted
File Name: /mepc_backup/May22fullbkp/MEPC_full_backup_MEPC_o1nbknav_1_1
RMAN-07517: Reason: The file header is corrupted
File Name: /mepc_backup/May22fullbkp/MEPC_full_backup_MEPC_o5nbkpvv_1_1
RMAN-07517: Reason: The file header is corrupted
File Name: /mepc_backup/May22fullbkp/snapcf_MEPC.f
RMAN-07517: Reason: The file header is corrupted
File Name: /mepc_backup/May22fullbkp/MEPC_full_backup_MEPC_o2nbknav_1_1
RMAN-07517: Reason: The file header is corrupted
File Name: /mepc_backup/May22fullbkp/MEPC_full_backup_MEPC_o4nbknav_1_1
RMAN-07517: Reason: The file header is corrupted
File Name: /mepc_backup/May22fullbkp/MEPC_full_backup_MEPC_o8nbkpvv_1_1
RMAN-07517: Reason: The file header is corrupted
the file is not corrupted as I checked the checksum on both the servers and it is the same.
Please help me how can I restore the RMAN oracle 10g backup in Oracle 11g and let me know where I am going wrong.
Thanks in advance.

You can not do this.
AFAIK, Solaris - assuming sparc - and Linux - assuming Intel - have different endian formats and this is your problem. You could use the migrate cross platform tablespace scenario.
see Oracle® Database Backup and Recovery Reference
If your endian format does appear to be the same, you should convert the database using rman convert database. In that case you could restore cross platform and cross version.

Not applicable for 10g/11g, but this is different in 12c:
In 12c, rman offers the option following options with the backup command:
FOR TRANSPORT: This options creates a backupset which can be transported to any destination. If the destination database uses a different endian format than the source, the endian format conversion is performed on the destination database.
TO PLATFORM: This option results in the endian format conversion to be performed on the source database and must be used by that supported platform only.
DATAPUMP: This specifies that a data pump export dump file is created while performing a cross-platform backup. The dump file is created in s separate backup set.

Use below command to restore from autobackup, RMAN knows the path and it will restore.
restore controlfile from autobackup;
You need to know first Solaris to Linux are part of same endian or not. I see that Solaris 64 but and Linux 64 bit are same endian.
Even it has same endian you will see this error when " The source Production database, has a 32KB tablespace and an initialisation parameter defined for db_32k_cache_size, but the target pfile didn't have the parameter db_32k_cache_size defined"
Set in the pfile/spfile of the target db_32k_cache_size

Related

Analysis of Redis error logs "LOADING Redis is loading the dataset in memory" and more

I am frequently seeing these messages in the redis logs
1#
602854:M 23 Dec 2022 09:48:54.028 * 10 changes in 300 seconds. Saving...
602854:M 23 Dec 2022 09:48:54.035 * Background saving started by pid 3266364
3266364:C 23 Dec 2022 09:48:55.844 * DB saved on disk
3266364:C 23 Dec 2022 09:48:55.852 * RDB: 12 MB of memory used by copy-on-write
602854:M 23 Dec 2022 09:48:55.938 * Background saving terminated with success
2#
LOADING Redis is loading the dataset in memory
3#
7678:signal-handler (1671738516) Received SIGTERM scheduling shutdown...
7678:M 22 Dec 2022 23:48:36.300 # User requested shutdown...
7678:M 22 Dec 2022 23:48:36.300 # systemd supervision requested, but NOTIFY_SOCKET not found
7678:M 22 Dec 2022 23:48:36.300 * Saving the final RDB snapshot before exiting.
7678:M 22 Dec 2022 23:48:36.300 # systemd supervision requested, but NOTIFY_SOCKET not found
7678:M 22 Dec 2022 23:48:36.720 * DB saved on disk
7678:M 22 Dec 2022 23:48:36.720 * Removing the pid file.
7678:M 22 Dec 2022 23:48:36.720 # Redis is now ready to exit, bye bye...
7901:C 22 Dec 2022 23:48:37.071 # WARNING supervised by systemd - you MUST set appropriate values for TimeoutStartSec and TimeoutStopSec in your service unit.
7901:C 22 Dec 2022 23:48:37.071 # systemd supervision requested, but NOTIFY_SOCKET not found
7914:C 22 Dec 2022 23:48:37.071 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
7914:C 22 Dec 2022 23:48:37.071 # Redis version=6.0.9, bits=64, commit=00000000, modified=0, pid=7914, just started
7914:C 22 Dec 2022 23:48:37.071 # Configuration loaded
Are these messages concerning?
Let me know if there's any optimization to be carried out in terms of settings.
The first set of informational messages is related to Redis persistence: it appears your Redis node is configured to save the database to disk if 300 seconds elapsed and it surpassed 10 write operations against it. You can change that according to your needs through the Redis configuration file.
The message LOADING Redis is loading the dataset in memory, on the other side, is an error message received while attempting to connect to a Redis instance which is loading its dataset in memory: that occurs during the startup for standalone servers and master nodes or when replicas reconnect and fully resynchronize with master. If you are seeing this error too often and not right after a system restart, I would suggest to check your system log files and learn why your Redis instance is restarting or resynchronizing (depending on your topology).

appimage-builder: AppImage successfully created but does not run on other machines

I've run through the tutorial here: https://appimage-builder.readthedocs.io/en/latest/intro/tutorial.html#
Which resulted in a runable Qt AppImage Template-latest-x86_64.AppImage file (no docker tests were run).
Initially, the AppImage works as expected. Double-clicking the AppImage from the GUI or running it via the console results in the tutorial application running.
However, two scenarios will result in the AppImage file no longer working:
If the machine which built the AppImage is rebooted, the same AppImage will no longer run.
If the AppImage is transferred to a different machine it will no longer run. The machine has the same version of the OS that the AppImage was built on.
Both scenarios have the same behavior. The application will appear as if it contains no executable code and immediately exit. Normally the application has a GUI interface. No error message is displayed.
Running from console:
tb#dt:~/appimage_tutorial/qt-appimage-template$ ll
total 176860
drwxr-xr-x 8 tb tb 4096 Nov 23 14:25 ./
drwxr-xr-x 3 tb tb 4096 Nov 23 14:18 ../
drwxr-xr-x 6 tb tb 4096 Nov 23 14:25 AppDir/
drwxr-xr-x 4 tb tb 4096 Nov 23 14:25 appimage-builder-cache/
-rw-r--r-- 1 tb tb 3430 Nov 22 22:35 AppImageBuilder.yml
-rw-r--r-- 1 tb tb 13981 Nov 23 14:18 CMakeCache.txt
drwxr-xr-x 4 tb tb 4096 Nov 23 14:18 CMakeFiles/
-rw-r--r-- 1 tb tb 1808 Nov 23 14:18 cmake_install.cmake
-rw-r--r-- 1 tb tb 439 Nov 23 14:18 CMakeLists.txt
-rw-r--r-- 1 tb tb 498 Nov 23 14:18 conanfile.txt
drwxr-xr-x 8 tb tb 4096 Nov 23 14:18 .git/
-rw-r--r-- 1 tb tb 19 Nov 23 14:18 .gitignore
-rw-r--r-- 1 tb tb 450 Nov 23 14:18 .gitlab-ci.yml
-rw-r--r-- 1 tb tb 159 Nov 23 14:18 install_manifest.txt
-rw-r--r-- 1 tb tb 6948 Nov 23 14:18 Makefile
-rwxr-xr-x 1 tb tb 181010472 Nov 23 14:25 'Qt AppImage Template-latest-x86_64.AppImage'*
-rw-r--r-- 1 tb tb 67 Nov 23 14:18 README.md
drwxr-xr-x 3 tb tb 4096 Nov 23 14:18 res/
drwxr-xr-x 4 tb tb 4096 Nov 23 14:18 src/
tb#dt:~/appimage_tutorial/qt-appimage-template$ ./'Qt AppImage Template-latest-x86_64.AppImage'
tb#dt:~/appimage_tutorial/qt-appimage-template$
(nothing happens)
gdb:
(gdb) run
Starting program: /home/tb/appimage_tutorial/qt-appimage-template/Qt AppImage Template-latest-x86_64.AppImage
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
process 2651 is executing new program: /tmp/.mount_Qt AppVj8Ud9/AppRun
[Inferior 1 (process 2651) exited with code 01]
(gdb)
The AppImage was built from the ~/appimage_tutorial/qt-appimage-template directory using: appimage-builder --skip-test
Here is the last part of the output from when the AppImage was being built:
INFO:root:Writing bundle info to: .bundle.yml
INFO:root:Downloading runtime: https://github.com/AppImage/AppImageKit/releases/download/continuous/runtime-x86_64
INFO:root:Generating AppImage from ./AppDir
INFO:appimagetool:appimagetool --runtime-file appimage-builder-cache/runtime-x86_64 ./AppDir /home/tb/appimage_tutorial/qt-appimage-template/Qt AppImage Template-latest-x86_64.AppImage
INFO:appimagetool:Parallel mksquashfs: Using 4 processors
INFO:appimagetool:Creating 4.0 filesystem on /home/tb/appimage_tutorial/qt-appimage-template/Qt AppImage Template-latest-x86_64.AppImage, block size 131072.
INFO:appimagetool:[============- ][===========================================================\] 11826/11826 100%
INFO:appimagetool:
INFO:appimagetool:Exportable Squashfs 4.0 filesystem, gzip compressed, data block size 131072
INFO:appimagetool:compressed data, compressed metadata, compressed fragments,
INFO:appimagetool:compressed xattrs, compressed ids
INFO:appimagetool:duplicates are removed
INFO:appimagetool:Filesystem size 176580.52 Kbytes (172.44 Mbytes)
INFO:appimagetool:35.82% of uncompressed filesystem size (492966.84 Kbytes)
INFO:appimagetool:Inode table size 142021 bytes (138.69 Kbytes)
INFO:appimagetool:23.51% of uncompressed inode table size (604061 bytes)
INFO:appimagetool:Directory table size 152721 bytes (149.14 Kbytes)
INFO:appimagetool:33.80% of uncompressed directory table size (451834 bytes)
INFO:appimagetool:Number of duplicate files found 1031
INFO:appimagetool:Number of inodes 15794
INFO:appimagetool:Number of files 8380
INFO:appimagetool:Number of fragments 355
INFO:appimagetool:Number of symbolic links 6432
INFO:appimagetool:Number of device nodes 0
INFO:appimagetool:Number of fifo nodes 0
INFO:appimagetool:Number of socket nodes 0
INFO:appimagetool:Number of directories 982
INFO:appimagetool:Number of ids (unique uids + gids) 1
INFO:appimagetool:Number of uids 1
INFO:appimagetool:root (0)
INFO:appimagetool:Number of gids 1
INFO:appimagetool:root (0)
INFO:appimagetool:/home/tb/appimage_tutorial/qt-appimage-template/AppDir should be packaged as /home/tb/appimage_tutorial/qt-appimage-template/Qt AppImage Template-latest-x86_64.AppImage
WARNING:appimagetool:appimagetool, continuous build (commit aaef827), build 2143 built on 2020-11-22 12:53:26 UTC
WARNING:appimagetool:Using architecture x86_64
WARNING:appimagetool:Deleting pre-existing .DirIcon
WARNING:appimagetool:Creating .DirIcon symlink based on information from desktop file
WARNING:appimagetool:WARNING: AppStream upstream metadata is missing, please consider creating it
WARNING:appimagetool:in usr/share/metainfo/QtQuickControls2Application.appdata.xml
WARNING:appimagetool:Please see https://www.freedesktop.org/software/appstream/docs/chap-Quickstart.html#sect-Quickstart-DesktopApps
WARNING:appimagetool:for more information or use the generator at http://output.jsbin.com/qoqukof.
WARNING:appimagetool:Generating squashfs...
WARNING:appimagetool:Embedding ELF...
WARNING:appimagetool:Marking the AppImage as executable...
WARNING:appimagetool:Embedding MD5 digest
WARNING:appimagetool:Success
WARNING:appimagetool:
WARNING:appimagetool:Please consider submitting your AppImage to AppImageHub, the crowd-sourced
WARNING:appimagetool:central directory of available AppImages, by opening a pull request
WARNING:appimagetool:at https://github.com/AppImage/appimage.github.io
INFO:root:AppImage created successfully
I suspect you did not install an appropriate AppRun in the AppDir directory.
But the process fails without error message.
I suggest you run the AppImage with strace to see more.

Not able to configure databricks with external hive metastore

I am following this document https://docs.databricks.com/data/metastores/external-hive-metastore.html#spark-configuration-options
to connect to my external hive metastore. My metastore version is 3.1.0 and followed the document.
docs.databricks.comdocs.databricks.com
External Apache Hive metastore — Databricks Documentation
Learn how to connect to external Apache Hive metastores in Databricks.
10:51
I have getting this error when trying to connect to external hive metastore
org/apache/hadoop/hive/conf/HiveConf when creating Hive client using classpath:
Please make sure that jars for your version of hive and hadoop are included in the paths passed to spark.sql.hive.metastore.jars
spark.sql.hive.metastore.jars=/databricks/hive_metastore_jars/*
When I do an ls on /databricks/hive_metastore_jars/, I can see all copied files
10:52
Do I need to copy any hive specific files and upload it in this folder?
I did exactly what was mentioned in the site
These are the contents of my hive_metastore_jars
total 56K
drwxr-xr-x 3 root root 4.0K Mar 24 05:06 1585025573715-0
drwxr-xr-x 2 root root 4.0K Mar 24 05:06 d596a6ec-e105-4a6e-af95-df3feffc263d_resources
drwxr-xr-x 3 root root 4.0K Mar 24 05:06 repl
drwxr-xr-x 2 root root 4.0K Mar 24 05:06 spark-2959157d-2018-441a-a7d3-d7cecb8a645f
drwxr-xr-x 4 root root 4.0K Mar 24 05:06 root
drwxr-xr-x 2 root root 4.0K Mar 24 05:06 spark-30a72ee5-304c-432b-9c13-0439511fb0cd
drwxr-xr-x 2 root root 4.0K Mar 24 05:06 spark-a19d167b-d571-4e58-a961-d7f6ced3d52f
-rwxr-xr-x 1 root root 5.5K Mar 24 05:06 _CleanRShell.r3763856699176668909resource.r
-rwxr-xr-x 1 root root 9.7K Mar 24 05:06 _dbutils.r9057087446822479911resource.r
-rwxr-xr-x 1 root root 301 Mar 24 05:06 _rServeScript.r1949348184439973964resource.r
-rwxr-xr-x 1 root root 1.5K Mar 24 05:06 _startR.sh5660449951005543051resource.r
Am I missing anything?
Strangely If I look into the cluster boot logs here is what I get
20/03/24 07:29:05 INFO Persistence: Property spark.hadoop.javax.jdo.option.ConnectionDriverName unknown - will be ignored
20/03/24 07:29:05 INFO Persistence: Property spark.hadoop.javax.jdo.option.ConnectionURL unknown - will be ignored
20/03/24 07:29:05 INFO Persistence: Property spark.hadoop.javax.jdo.option.ConnectionUserName unknown - will be ignored
20/03/24 07:29:05 INFO Persistence: Property hive.metastore.integral.jdo.pushdown unknown - will be ignored
20/03/24 07:29:05 INFO Persistence: Property spark.hadoop.javax.jdo.option.ConnectionPassword unknown - will be ignored
20/03/24 07:29:05 INFO Persistence: Property datanucleus.cache.level2 unknown - will be ignored
20/03/24 07:29:05 INFO Persistence: Property datanucleus.schema.autoCreateAll unknown - will be ignored
20/03/24 07:29:09 WARN ObjectStore: Version information not found in metastore. hive.metastore.schema.verification is not enabled so recording the schema version 1.2.0
20/03/24 07:29:09 WARN ObjectStore: Failed to get database default, returning NoSuchObjectException
I have already set the above configurations and it shows in the logs as well
20/03/24 07:28:59 INFO SparkContext: Spark configuration:
spark.hadoop.javax.jdo.option.ConnectionDriverName=org.mariadb.jdbc.Driver
spark.hadoop.javax.jdo.option.ConnectionPassword=*********(redacted)
spark.hadoop.javax.jdo.option.ConnectionURL=*********(redacted)
spark.hadoop.javax.jdo.option.ConnectionUserName=*********(redacted)
Also version information is available in my hive metastore, I can connect to mysql and see it it shows
SCHEMA_VERSION : 3.1.0
VER_ID = 1
From the output, it looks like the jars are not copied to the "/databricks/hive_metastore_jars/" location. As mentioned in the documentation link you shared:
Set spark.sql.hive.metastore.jars set to maven
Restart the cluster with the above configuration and then check in the Spark driver logs for the message :
17/11/18 22:41:19 INFO IsolatedClientLoader: Downloaded metastore jars to <path>
From this location copy the jars to DBFS from the same cluster and then use an init script to copy the jars from DBFS to "/databricks/hive_metastore_jars/"
As I am using azure mysql there is one more step I need to perform
https://learn.microsoft.com/en-us/azure/databricks/data/metastores/external-hive-metastore

Error using DBD::Oracle with instantclient 11.2

I Want to use perl module DBD::Oracle on Mac OS X 10.8.
I installed DBI through CPAN.
Downloaded the Oracle instant client 11.2 (basic, sqlplus and jdk).
Extracted it to /usr/local/oracle.
$ ls /usr/local/oracle/instantclient_11_2/
BASIC_README libnnz11.dylib ojdbc6.jar
SQLPLUS_README libocci.dylib.11.1 sdk
adrci libociei.dylib sqlplus
genezi libocijdbc11.dylib uidrvci
glogin.sql libsqlplus.dylib xstreams.jar
libclntsh.dylib libsqlplusic.dylib
libclntsh.dylib.11.1 ojdbc5.jar
Then installed DBD::Oracle.
Now when I want to use DBD::Oracle it gives an error.
install_driver(Oracle) failed: Can't load '/Library/Perl/5.12/darwin-thread-multi-
2level/auto/DBD/Oracle/Oracle.bundle' for module DBD::Oracle:
dlopen(/Library/Perl/5.12/darwin-thread-multi-2level/auto/DBD/Oracle/Oracle.bundle, 1):
Library not loaded: /ade/b/2649109290/oracle/rdbms/lib/libclntsh.dylib.11.1
Referenced from: /Library/Perl/5.12/darwin-thread-multi-
2level/auto/DBD/Oracle/Oracle.bundle
Reason: image not found at /System/Library/Perl/5.12/darwin-thread-multi-
2level/DynaLoader.pm line 204.
I have DYLD_LIBRARY_PATH=/usr/local/oracle/instaclient_11_2
I have not a clue what I am doing wrong.
SOLVED:
I got the same error when trying to run sqlplus. I added my oracle client directory to my global PATH variable and it is working now.
Saw they did the same in this tutorial: http://www.janhellevik.no/?p=521
Check this one out: perl DBD::Oracle Module installtion
Above information is about Linux Environment. But you might get some clues on how to go about configuring DBD::Oracle on MAC OSX.
On linux, you need "Basic, SQLPLUS and Devel" binaries of the oracle instant client. Here is the directory listing on my Linux box:
# pwd
/usr/lib/oracle/11.2/client64/lib
# ls -l
total 185232
-rw-r--r-- 1 root root 368 Sep 17 2011 glogin.sql
lrwxrwxrwx 1 root root 17 Jul 9 2012 libclntsh.so -> libclntsh.so.11.1
-rw-r--r-- 1 root root 52761218 Sep 17 2011 libclntsh.so.11.1
-rw-r--r-- 1 root root 7955322 Sep 17 2011 libnnz11.so
lrwxrwxrwx 1 root root 15 Jul 9 2012 libocci.so -> libocci.so.11.1
-rw-r--r-- 1 root root 1971762 Sep 17 2011 libocci.so.11.1
-rw-r--r-- 1 root root 118408281 Sep 17 2011 libociei.so
-rw-r--r-- 1 root root 164836 Sep 17 2011 libocijdbc11.so
-rw-r--r-- 1 root root 1503303 Sep 17 2011 libsqlplusic.so
-rw-r--r-- 1 root root 1477446 Sep 17 2011 libsqlplus.so
-rw-r--r-- 1 root root 2095661 Sep 17 2011 ojdbc5.jar
-rw-r--r-- 1 root root 2714016 Sep 17 2011 ojdbc6.jar
-rw-r--r-- 1 root root 300666 Sep 17 2011 ottclasses.zip
-rw-r--r-- 1 root root 66779 Sep 17 2011 xstreams.jar
and here is the list of oracle instant client RPMs that I installed:
# rpm -qa | grep -i oracle
oracle-instantclient11.2-basic-11.2.0.3.0-1
oracle-instantclient11.2-devel-11.2.0.3.0-1
oracle-instantclient11.2-sqlplus-11.2.0.3.0-1
Hope this helps.

Primary Secondary server in Weblogic

I have apache proxy web server ahead of 6 weblogic instances which are part of a single cluster.
For a client that hits my application the Apache's access logs shows the below loggin
/Replica/AddServlet;jsessionid=PvqTQtYfKLrzBHtT1dpcJX5WhryRgpTGBvMJ8pLbpJnSDR5p0K65!1647512983!-1661904304!1357731903334 HTTP/1.1" 200 284
How can I determine which out the six is the primary and which is the secondary weblogic server for this client request ?
You have to switch on the Apache DEBUG log, which notes the individual server HASH and maps it to the Managed server.
Turn on proxy debug by setting Debug=”ALL” in the proxy configuration file.
Example configuration for Apache plug-in (httpd.conf):
<Location /mywebapp>
SetHandlerweblogic-handler
WebLogicCluster sol1:8001,sol2:8001,sol3:8003
Debug ALL
DebugConfigInfo ON
WLLogFile /tmp/wlproxy.log
</Location>
You can then see the exact host:port for your primary and secondary for the request.
Example from http://www.bea-weblogic.com/weblogic-server-support-pattern-common-diagnostic-process-for-proxy-plug-in-problems.html
Or try this link
http://www.findsol.com/blog/weblogic-server-support-pattern-common-diagnostic-process-for-proxy-plug-in-problems/
Mon May 10 13:14:40 2004 getpreferredServersFromCookie: -2032354160!-457294087
Mon May 10 13:14:40 2004 GET Primary JVMID1: -2032354160
Mon May 10 13:14:40 2004 GET Secondary JVMID2: -457294087
Mon May 10 13:14:40 2004 [Found Primary]: 172.18.137.50:38625:65535
Mon May 10 13:14:40 2004 list[0].jvmid: -2032354160
Mon May 10 13:14:40 2004 secondary str: -457294087
Mon May 10 13:14:40 2004 list[1].jvmid: -457294087
Mon May 10 13:14:40 2004 secondary str: -457294087
Mon May 10 13:14:40 2004 [Found Secondary]: 172.18.137.54:38625:65535
Mon May 10 13:14:40 2004 Found 2 servers
Remember each time you restart the weblogic servers, new HASHes are used.

Resources