Description
- What versions are you using?
python-oracledb 1.0.3
Oracle Database 19c Enterprise Edition Release 19.0.0.0.0
platform.platform: Linux-3.10.0-1160.71.1.el7.x86_64-x86_64-with-glibc2.17
platform.python_version: 3.9.6
sys.maxsize > 2**32: True
- Is it an error or a hang or a crash?
Connection fails to Exadata RAC with the thin client.
connection = oracledb.connect(user=admin, password=args.adminpwd,
dsn=args.service_name, config_dir = tnsdir)
- What error(s) or behavior you are seeing?
With thin client connection to a single instance non RAC db seems to work fine.
But I cannot connect to Exadata RAC instance with thin client, it causes the exception:
oracledb.exceptions.OperationalError: DPY-6000: cannot connect to database. Listener refused connection. (Similar to ORA-12660)
Problem tns entry is like:
x01 =
(DESCRIPTION =
(ADDRESS_LIST =
(FAILOVER = ON)
(LOAD_BALANCE = ON)
(ADDRESS = (PROTOCOL = TCP)(HOST = xt01dev-scan.home.net)(PORT = 1521))
(ADDRESS = (PROTOCOL = TCP)(HOST = xt02dev-scan.home.net)(PORT = 1521))
)
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = dbox_svc.tst.tns)
)
)
if I call init_oracle_client() it starts working.
- Does your application call init_oracle_client()?
No.
But if I call init_oracle_client(), it starts working.
- Include a runnable Python script that shows the problem.
# Uncomment below line and the problem goes away
# oracledb.init_oracle_client()
connection = oracledb.connect(user=admin, password=args.adminpwd,
dsn=args.service_name, config_dir = tnsdir)