[ZBXNEXT-2380] Zabbix-Server should support oracle failover connection strings Created: 2014 Jul 10  Updated: 2014 Jul 18

Status: Open
Project: ZABBIX FEATURE REQUESTS
Component/s: Server (S)
Affects Version/s: 2.2.3, 2.2.4
Fix Version/s: None

Type: Change Request Priority: Major
Reporter: Christian Meissner Assignee: Unassigned
Resolution: Unresolved Votes: 1
Labels: fallback, oracle
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

zabbix_server self compiled against oci api.


Attachments: File tnsnames.ora    

 Description   

we currently testing Zabbix with an oracle database backend. Here we have an oracle 11g cluster (rac-1.domain.tld) with an oracle 11g standby cluster (rac-2.domain.tld.
So we use in other application (servers) a failoverstring like this:

(description_list=(load_balance=off)(failover=on)( description=(connect_timeout=3)(retry_count=2)(add ress_list=(load_balance=on)(address=(protocol=tcp) (host=rac-1.domain.tld)(port=1540)))(connect_data=(service_n ame= zbxserv)))(description=(connect_timeout=3)(retry_c ount=2)(address_list=(load_balance=on)(address=(pr otocol=tcp)(host=rac-2.domain.tld)(port=1540)))(connect_data=(service_n ame= zbxserv))))

How i can connect this way to an oracle system. An automatic connect after a database failover will be great.



 Comments   
Comment by Oleksii Zagorskyi [ 2014 Jul 17 ]

Zabbix server reconnects to database if required (for a list of errors returned by db backend library).
Not sure your case "included" to the list.

Comment by richlv [ 2014 Jul 17 ]

when the failover happens, don't you have a virtual ip pointing at the current db ?
is your zabbix configured against that ip address ?

Comment by Christian Meissner [ 2014 Jul 18 ]

No, there is no virtual ip. In the above connection string you can find two host parameters, which are the both clusters. Each cluster has two nodes. In Cluster the connections will managed transparently to the application. But failover from active to standby database will lead to a hostname switch.
An alternative to connection string in configuration will be tnsnames.ora file there is the connection string mapped to an virtual name. I will attach such a file.

Comment by Christian Meissner [ 2014 Jul 18 ]

example tnsnames.ora

Comment by Christian Meissner [ 2014 Jul 18 ]

Ok, i got more information from my dba

1) Our two clusters hava a scan-name (rac-1 and rac-2)
1.1) each scan-name is mapped to three ip addresses (A-Records)
1.2) this three addresses will assigned to the nodes at cluster start.
2) Data guard manage replication and switchover from one cluster to another. The Switchover is done by hand by our dba
3) Application takes first host parameter an tries "retry_connect" times to connect to this scan-name. If connection is not possible the app tries the next host entry.
3.3) failover=on means that the application retry regulary reconnect to hosts in "address_list". So it's guaranteed that reconnect worked after cluster switchover

Generated at Sat Apr 05 08:18:50 EEST 2025 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.