RAC instance affinity
Hi,
I have a Oracle 11gR2 2-node RAC setup. One of the applications that runs on this RAC setup is a DML with large number of INSERT. I would like to restrict this application to only one node, so as to avoid the Cluster waits. With that in mind, I created a Service and assigned Node_1 in the preferred list and Node_2 in the available list -
srvctl add service -d orcl -s orcl_ins -r Node_1 -a Node_2
The jdbc application connect string is setup as -
public static String dburl = "jdbc oracle:thin (DESCRIPTION_LIST=(LOAD_BALANCE=off)(FAILOVER=on)(DESCRIPTION=(CONNECT_TIMEOUT=20)(TRANSPORT_CONNECT_TIMEOUT=10)(RETRY_COUNT=3)(ADDRESS_LIST=(LOAD_BALANCE=off)(ADDRESS=(PROTOCOL=TCP)(HOST=host01-scan)(PORT=1521)))(CONNECT_DATA=(SERVICE_NAME=orcl_ins))))";
But the application when it runs still ends up with connections (equal number) on both nodes. Can you please look at this setting and help me with why the instance affinity with the service_name defined is not working?
Appreciate you help!
Thanks
Lalita
Check the services parameter on all instances you should only have the service parameter set on the preferred instance. If the service parameter is set on all instances it will register with the listener and the connection can connect to any instance. The service parameter will automatically be changed to the available instance during a failover.
Similar Messages
-
Instance Affinity with EBS on RAC
Hi,
Anybody with experience on instance affinity on module-level when running EBS on Real Applications Cluster?
I know about this feature for quite some time, but have never tried it. I was wondering how one can achieve this (isn't it a profile option?).
Regards,
Arnoud RothFound it myself...
It can be accomplished by setting the profile option "Database Instance" (internal name "INSTANCE_PATH") to a certain instance on either Application, Responsibility or User level.
Regards,
Arnoud -
Communication between RAC instances
Hi,
I see different answers for this Communication between RAC instances in google.
1. UDP
2.Distributed Lock Manager (DLM)
which one of is correct?both of them are correct on different layers. The IP protocol used over the interconnect is udp and one of the protocols/mechanism implemented above that is DLM.
-
Communication between RAC instances in google.
Hi,
I see different answers for this Communication between RAC instances in google.
1. UDP
2.Distributed Lock Manager (DLM)
which one of is correct?Pl do not post duplicate threads - Communication between RAC instances
Srini -
We have Oracle Databases 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production running on Linux x86 64-bit
It is a two instance RAC running on servers, let's say - node1 and node2 . We are using ASM
Node 1 has an ASM instance ASM1 and Node 2 has an ASM instance ASM2.
There are 3 11g rdbms databases running on these nodes.
Instances db11,db21,db31 are running on node 1 and corresponding RAC instances db12,db22,db32 are running on node 2
The listeners are configured exactly the same on both nodes.
On Node 2, when I do
[oracle@node2 admin]$ lsnrctl status
LSNRCTL for Linux: Version 11.2.0.1.0 - Production on 19-NOV-2010 14:34:34
Copyright (c) 1991, 2009, Oracle. All rights reserved.
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=LISTENER)))
STATUS of the LISTENER
Alias LISTENER
Version TNSLSNR for Linux: Version 11.2.0.1.0 - Production
Start Date 15-NOV-2010 13:33:49
Uptime 4 days 1 hr. 0 min. 44 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File /opt/oracle/product/11.2.0/grid/network/admin/listener.ora
Listener Log File /opt/app/oracle/diag/tnslsnr/node2/listener/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=LISTENER)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=10.10.7.42)(PORT=1521)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=10.10.7.52)(PORT=1521)))
Services Summary...
Service "+ASM" has 1 instance(s).
Instance "+ASM2", status READY, has 1 handler(s) for this service...
Service "db1" has 2 instance(s).
Instance "db11", status READY, has 1 handler(s) for this service...
Instance "db12", status READY, has 2 handler(s) for this service...
Service "db2" has 2 instance(s).
Instance "db21", status READY, has 1 handler(s) for this service...
Instance "db22", status READY, has 2 handler(s) for this service...
Service "db3" has 2 instance(s).
Instance "db31", status READY, has 1 handler(s) for this service...
Instance "db32", status READY, has 2 handler(s) for this service...
The command completed successfullyThe above looks good which is what should be the case.
Now, if I try doing the same on node 1 (and this is where I am concerned)
[oracle@node1 admin]$ lsnrctl status
LSNRCTL for Linux: Version 11.2.0.1.0 - Production on 19-NOV-2010 14:41:45
Copyright (c) 1991, 2009, Oracle. All rights reserved.
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=LISTENER)))
STATUS of the LISTENER
Alias LISTENER
Version TNSLSNR for Linux: Version 11.2.0.1.0 - Production
Start Date 19-NOV-2010 03:20:44
Uptime 0 days 11 hr. 21 min. 1 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File /opt/oracle/product/11.2.0/grid/network/admin/listener.ora
Listener Log File /opt/app/oracle/diag/tnslsnr/node1/listener/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=LISTENER)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=10.10.7.41)(PORT=1521)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=10.10.7.51)(PORT=1521)))
Services Summary...
Service "+ASM" has 1 instance(s).
Instance "+ASM1", status READY, has 1 handler(s) for this service...
Service "db1" has 1 instance(s).
Instance "db11", status READY, has 2 handler(s) for this service...
Service "db2" has 1 instance(s).
Instance "db21", status READY, has 2 handler(s) for this service...
Service "db3" has 1 instance(s).
Instance "db31", status READY, has 2 handler(s) for this service...
The command completed successfullyThe node 1 does not seem to report the fact that each of these 3 databases have 2 instances and also does not list its other instances besides the ones running on it. Any ideas or suggestions as to where to look?One problem is here
The listeners are configured exactly the same on both nodes.This is incorrect, as the listeners need to have different names.
They need to have different names as listener_node1 is the remote_listener for node 2 and vice versa.
The correct set up is:
The listener name is node dependent.
The listener definition
listener_<node>=(host=)(protocol=)(port=)
is included in tnsnames.ora
the remote_listener parameter is set to the listener of the other node.
Using hardcoded IPs in listener.ora and tnsnames.ora is a bad idea.
Not sure why you don't ask this question in the RAC forum.
Sybrand Bakker
Senior Oracle DBA -
Dear all,
My version is 11.2.0.2.5 one of my rac instance crashes with message ORA-00240: control file enqueue held for more than 120 seconds. Received an instance abort message from instance 1.
here are the contents of alert log file
IPC Send timeout detected. Receiver ospid 27423 [[email protected] (LMON)]
2013-03-22 22:30:05.644000 -07:00
Errors in file /u01/app/oracle/diag/rdbms/lfgoimdb/LFGoimdb2/trace/LFGoimdb2_lmon_27423.trc:
2013-03-22 22:31:08.734000 -07:00
Errors in file /u01/app/oracle/diag/rdbms/lfgoimdb/LFGoimdb2/trace/LFGoimdb2_arc2_27691.trc (incident=15905):
ORA-00240: control file enqueue held for more than 120 seconds
Incident details in: /u01/app/oracle/diag/rdbms/lfgoimdb/LFGoimdb2/incident/incdir_15905/LFGoimdb2_arc2_27691_i15905.trc
2013-03-22 22:31:13.409000 -07:00
Received an instance abort message from instance 1
Please check instance 1 alert and LMON trace files for detail.
LMS0 (ospid: 27427): terminating the instance due to error 481
System state dump requested by (instance=2, osid=27427 (LMS0)), summary=[abnormal instance termination].
System State dumped to trace file /u01/app/oracle/diag/rdbms/lfgoimdb/LFGoimdb2/trace/LFGoimdb2_diag_27413.trc
2013-03-22 22:31:18.376000 -07:00
Dumping diagnostic data in directory=[cdmp_20130322223113], requested by (instance=2, osid=27427 (LMS0)), summary=[abnormal instance termination].
ORA-1092 : opitsk aborting process
Instance terminated by LMS0, pid = 27427Thanks for reply,
My redo logs size is default 50mb.There is currently no load on the system since we are not using this environment for time being.The log switches are averaged to be 8 per day.I think Increasing the size of redo will further cause the problems since the archiver may again hold lock for more time.
Since there is no dedicated connection between the nodes and storage ,So increasing the hardware and network configuration is only solution to this? Or I am still missing something...
As far as configuration is considered i cannot add more resources to this environment.How can I solve this issue? -
RAC instance name - Can i choose my OWN?
Can i choose RAC instance name rather than defined by DBCA?
for example, i want to name my instance as <DBNAME>_1yes you can
Cheers -
How many 11gR2 RAC instance servers would be needed?
On the shared SAN drive - there will be as many as 6 11gR2 databases. For 2 node RAC instance servers - how many instance servers would work fine - are two separate servers needed for each database?
user7107816 wrote:
On the shared SAN drive - there will be as many as 6 11gR2 databases. For 2 node RAC instance servers - how many instance servers would work fine - are two separate servers needed for each database???? That depends. Does each database require high availability? Your question seems to indicate a lack of understanding of what RAC provides and how it achieves that goal... High Availability.
RAC can also be used to provide additional horsepower - on the fly. I have added a new node - start to finish in < 2hrs. (new hardware+install/configure OS+addnode to RAC and have it online and operational.) No other database solution offers this flexability. -
How to determine which RAC-instance the appl. is logged onto?
Dear all,
I need to have my application server determine which RAC-
instance is currently active (logged onto). I have a
tnsnames.ora file with a primary-, and secondary RAC-
instance configured, and Failover/Failback between the
instances work fine. However, I would be interested in
determining which instance I am curently using.
Does the Oracle Net Protocol have support for letting me
"read" this out, or...?
Thanks.
Regards, Eldor R.Thank you for the prompt reply.
Is there, in the Oracle Net Protocol, available
function(s) for reading out this information
directly without "parsing" the trace file?
I would like to read out this information from my
application run-time.
Thanks. -
RAC instance, trying to recover UNDO datafile, RMAN gives RMAN-06054
Hello all,
This has been a troublesome instance..a quick bit of background. This was created awhile back by someone else, I inherited this 3 mode RAC clusterof instance1.
I'm exporting out of one database (10G) into this instance1 (11G). When I was about to start the import..I found this instance wouldn't start. Turned out no backup had been going on of this empty instance. I backed up the archive logs to tape to free up the FRA..and things fired up.
I began the import, and found a bunch of errors...basically tellling me that I couldn't access one of the undo tablespaces...datafile problems.
I went to look and saw:
SQL> select a.file_name, a.file_id, b.status, a.tablespace_name
2 from dba_data_files a, v$datafile b
3 where a.file_id = b.file#
4 order by a.file_name;
FILE_NAME FILE_ID STATUS TABLESPACE_NAME
+DATADG/instance1/datafile/sysaux.270.696702269 2 ONLINE SYSAUX
+DATADG/instance1/datafile/system.263.696702253 1 SYSTEM SYSTEM
+DATADG/instance1/datafile/undotbs1.257.696702279 3 ONLINE UNDOTBS1
+DATADG/instance1/datafile/undotbs2.266.696702305 4 ONLINE UNDOTBS2
+DATADG/instance1/datafile/undotbs3.269.696702313 5 RECOVER UNDOTBS3
+DATADG/instance1/datafile/users.268.696702321 6 ONLINE USERS
+DATADG/instance1/l_data_01_01 11 ONLINE L_DATA_01
+DATADG/instance1/s_data_01_01 7 ONLINE S_DATA_01
+DATADG/instance1/s_data_01_02 8 ONLINE S_DATA_01
+INDEXDG/instance1/l_index_01_01 12 ONLINE L_INDEX_01
+INDEXDG/instance1/s_index_01_01 9 ONLINE S_INDEX_01
FILE_NAME FILE_ID STATUS TABLESPACE_NAME
+INDEXDG/instance1/s_index_01_02 10 ONLINE S_INDEX_01
There is is, file #5.
So, I went into RMAN to try to restore/recover:
RMAN> restore datafile 5;
Starting restore at 06-APR-10
allocated channel: ORA_SBT_TAPE_1
channel ORA_SBT_TAPE_1: SID=222 instance=instance1 device type=SBT_TAPE
channel ORA_SBT_TAPE_1: NMO v4.5.0.0
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=222 instance=instance1 device type=DISK
creating datafile file number=5 name=+DATADG/instance1/datafile/undotbs3.269.696702313
restore not done; all files read only, offline, or already restored
Finished restore at 06-APR-10
RMAN> recover datafile 5;
Starting recover at 06-APR-10
using channel ORA_SBT_TAPE_1
using channel ORA_DISK_1
starting media recovery
RMAN-06560: WARNING: backup set with key 343546 will be read 2 times
available space of 8315779 kb needed to avoid reading the backup set multiple times
unable to find archived log
archived log thread=1 sequence=1
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of recover command at 04/06/2010 14:33:07
RMAN-06054: media recovery requesting unknown archived log for thread 1 with sequence 1 and starting SCN of 16016
This is all on ASM, and am a bit of a newb with that. I bascially have no data I'm worried about losing, I just need to get everything 'on the air' so I can import successfully, and let users on this instance. I've set up the backups in GRID now....so, it will be backed up on the future, but what is the quickest, most efficient way to get this UNDO tablespace datafile recovered?
Thank you,
cayenneHemant K Chitale wrote:
SET UNTIL SEQUENCE 27wouldn't work if the Recovery requires Sequence 1 and it is missing.
Hemant K ChitaleOops...meant to have start and set until both to "1"
However, I see what you mean. It seems I cannot find the file on tape.
Since the RAC instance hasn't yet had any data put into it, I'm thinking it might be best to just blow it away, and recreate everything.
Trouble is, I'm a bit new at RAC and ASM. I was thinking the best route might be to use DBCA to remove the database...? Would this not take care of removing all the datafiles from all the ASM instances on the RAC..as well as all the other directories, etc on all 3x nodes?
I've already used the dbca to create templates of this instance, so recreation shouldn't be too difficult (although it will be my first RAC creation)...
Thank you in advance for the advice so far,
cayenne -
Getting error while starting the RAC instance through SRVCTL utility
Hi DBA's,
We are getting the below error while starting the Orcale 10g RAC instance on one of the node thru SRVCTL:
oracle:/home/oracle]>srvctl start instance -d SQLTSTM2 -i SQLTSTM21
PRKP-1001 : Error starting instance SQLTSTM21 on node r1racd
CRS-1028: Dependency analysis failed because of:
CRS-0223: Resource 'ora.SQLTSTM2.SQLTSTM21.inst' has placement error.
:oracle:/home/oracle]>
srvctl status database -d SQLTSTM2
PRKO-2015 : Error in checking condition of instance on node: r1racd
Instance SQLTSTM22 is running on node r2racd
oracle:/opt/oracle/product/10.2.0/db]>
NOTE: but i am able to start the instance thru SQLPLUS.
After starting the instance thru SQLPLUS i checked the CRS_STAT -t . It shows the status offline... Please find the details below:
Name Type Target State Host
ora....21.inst application OFFLINE OFFLINE
ora....22.inst application ONLINE ONLINE r2racd
ora....VLM2.db application ONLINE ONLINE r2racd
ora....21.inst application ONLINE ONLINE r1racd
ora....22.inst application ONLINE ONLINE r2racd
ora....STM2.db application ONLINE ONLINE r2racd
ora....SM1.asm application ONLINE ONLINE r1racd
ora....CD.lsnr application ONLINE ONLINE r1racd
ora.r1racd.gsd application ONLINE ONLINE r1racd
ora.r1racd.ons application ONLINE ONLINE r1racd
ora.r1racd.vip application ONLINE ONLINE r1racd
ora....SM2.asm application ONLINE ONLINE r2racd
ora....CD.lsnr application ONLINE ONLINE r2racd
ora.r2racd.gsd application ONLINE ONLINE r2racd
ora.r2racd.ons application ONLINE ONLINE r2racd
ora.r2racd.vip application ONLINE ONLINE r2racd
Thanks in advance...
AnilUse the 'srvctl config database -d ' command to check if the instance has been configured in the Oracle Cluster Registry; make sure that the GSDs are running on each node in the cluster.
Also refere to Metalink note 295328.1 -
Max Connections to Oracle 10g RAC Instance
Hi,
We have IBM Websphere Application Server on one unix server which is connecting to a Oracle 10g RAC Instance which is on a different unix server through JDBC connection. They(Application Team) are doing stress tests, please tell me how many connections can a Oracle Database Allow simultaneously. They tested for 2000 connections simultaneously. It failed...This is urgent, they are on call please reply ASAP
Thanks,Use Oracle Shared Server (the default is Dedicated Server),
I've shown JBOSS app developers how a little Dell desktop (256MB RAM, 1.7Ghz P4) can accept a 1000 app server connections (using Shared Server). While a big HP-UX server failed to accept 200 connections (using Dedicated Server).
Oracle RAC should easily be able to handle 100+ concurrent client OLTP connections per RAC node using Shared Server - assuming that each of the concurrent sessions are actually doing stuff and not just sitting there idle. (if 99.99% of the connections are idle, then even a little desktop Oracle database can handle well over a 1000)
Bottomline - you must have your primary focus and expertise on Oracle. On the the data tier. Not the app tier. The data tier is what scales the app tier. Not vice versa. Adding an extra app tier server does not enable the data tier platform to suddenly be able to run more SQLs, The app tier does not scale the data tier.
If you want performance and scalability, you must get the data tier right. App tier be damned as that is neither here nor there ito performance and scalability. This means Oracle expertise is required first and foremost. -
Standby Database from a RAC instance
Good Day,
I have two 10gR2 Enterprise Edition RAC Instances. Is it possible to make two standby database using 10gR2 Standard Edition?
Thanks in advance
AlessandroYou could post your query in the
Database - General : General Database Discussions
and/or
RAC : Real Application Clusters
forums. -
One of RAC instance doesnt generate awr snapshot
Hi,
I have a problem about awr snapshots. One of RAC instance doesn t generate awr snapshot.
When I look over alert.log. I couldn t see any error message
is there anybody to have idea about this issue?
OS Level HP-UX ITANIUM 11.23
DB version Oracle RAC 10.2.0.4
Regards,hi JohnWatson
thanks for your reply
I have run dbms_workload_respository.create_snapshot on both of two nodes.it has finished succesfully and I saw this record in the dba_hist_snapshot view
I haven t seen any error record in alert log and there isn t any trace file occured.
In other words, when I run this create snapshot command in working node, the snapshot of other node doesn t generate in the dba_hist_snapshot view
but when I run this command broken node (so it doesn t generate awr snapshot) manually , other node isn t triggered to generate awr snapshot,
SQL> exec dbms_workload_repository.create_snapshot ;
PL/SQL procedure successfully completed.
select instance_number,begin_interval_time,end_interval_time from dba_hist_snapshot where snap_id in(40274);
INSTANCE_NUMBER BEGIN_INTERVAL_TIME END_INTERVAL_TIME
1 16-JAN-13 01.00.54.450 AM 18-JAN-13 03.51.19.951 PM
2 18-JAN-13 03.43.02.430 PM 18-JAN-13 03.51.20.103 PM
regards,
Edited by: dataseven on 18.Oca.2013 06:19 -
New RAC Instance 10.2.0.2 - won't start
Hi There,
I am not a DBA, though have a good understanding of UNIX. For a work project I need to create a RAC instance on Solaris 10 x86 u6... I have installed the software, created the instance using DBCA, but unfortunatley it will not start.
I am recieving the following errors when i run the command below to start the instance:
bash-3.00$ srvctl start instance -d orcldb -i orcldb1
PRKP-1001 : Error starting instance orcldb1 on node sol002
CRS-0215: Could not start resource 'ora.orcldb.orcldb1.inst'.
===== alert log ======
Fri Jul 17 10:24:05 2009
WARNING: EINVAL creating segment of size 0x000000001a402000
fix shm parameters in /etc/system or equivalent
I have the following projects defined for oracle on both nodes in the cluster.
sol002:
bash-3.00$ prctl -n project.max-shm-memory -i project oracle
project: 100: oracle
NAME PRIVILEGE VALUE FLAG ACTION RECIPIENT
project.max-shm-memory
privileged 700MB - deny -
system 16.0EB max deny -
bash-3.00$ cat /etc/project
system:0::::
user.root:1::::
noproject:2::::
default:3::::
group.staff:10::::
oracle:100::::project.max-shm-memory=(priv,734003200,deny)
sol003:
# prctl -n project.max-shm-memory -i project oracle
project: 100: oracle
NAME PRIVILEGE VALUE FLAG ACTION RECIPIENT
project.max-shm-memory
privileged 700MB - deny -
system 16.0EB max deny -
# cat /etc/project
system:0::::
user.root:1::::
noproject:2::::
default:3::::
group.staff:10::::
oracle:100::::project.max-shm-memory=(priv,734003200,deny)
After trying to tweak these values between 700mb and 4gb (i only have 1500mb of RAM) i added some values into the /etc/system (which i understand to be depricated on solaris 10) as reccomended in the post below due to bug 5340239 on Metalink, but still did not resolve the problem.
http://posulliv.com/?cat=12
When using DBCA to create the database, I specified to use 40% of available system memory. I am not sure where those values get defined and if that may also be playing a part in this issue.
Any help wuld be greatly appreciated.bash-3.00$ srvctl start instance -d orcldb -i orcldb1
PRKP-1001 : Error starting instance orcldb1 on node sol002
CRS-0215: Could not start resource 'ora.orcldb.orcldb1.inst'.Please check imon* file at $ORACLE_HOME/log/<nodename>/racg/
Or check by debug
$ export SRVM_TRACE=TRUE
$ srvctl start instance -d orcldb -i orcldb1
Show us about your error....
if you have the problem about project
Can you make project for the "system" ?*
by memory for "system" > "oracle" ("system" can more physical memory)*
and try start instance again ;)
Maybe you are looking for
-
How can I open an app from an e-mail link that is associated with link.
I get e-mails with links in them all the time (from forms, online shopping, etc). Some of those links are for websites that have an iphone app associated with them (especially forums). When I click on the link it tells me as much, and if I click "o
-
Global Temp Table Not found - SSIS
I am facing below error while using global temp table in SSIS. [OLE DB Destination [78]] Error: SSIS Error Code DTS_E_OLEDBERROR. An OLE DB error has occurred. Error code: 0x80040E37. An OLE DB record is available. Source: "Microsoft SQL Server Nat
-
Can I possibly get Premiere to work for this project?
Hi. I am working on a time lapse scanner photography project. I scan flowers a few times an hour and then make videos of them drying out. I'm currently making a movie of it all. The thing is, the scans can be thousands of pixels high/wide. The proble
-
Automatically Renaming and Sorting Files
When I first installed iTunes, I remember it asking me something about automatically sorting and finding file information for the existing music on my computer (Windows Based). I didn't want to do that at the time, but I would like to if that is inde
-
AirPort turns off by itself and won't turn on without restart
Hi I noticed that for a week or so, just few days prior to upgrade to Snow Leopard my (fully updated) MacBook Pro's wireless turns off for no apparent reason. When that happenes I cannot turn it on unless I restart the computer. I tried several solut