This is an old post here, but since I was in the same situation, and this forum is approaching the start of a Google search, I decided to post my solution.
I tried to send an XML request to the Oracle server and got one instance: ORA-12504: TNS: SERVICE_NAME in CONNECT_DATA was not provided to the listener
The problem was the FQDN service name. He tried to solve this problem through EZCONNECT, but in Oracle 11g EZCONNECT does not send the service name at all.
Solution: 1. In "$ ORACLE_HOME \ database \ network \ admin \ sqlnet.ora" use only TNSNAMES in NAMES.DIRECTORY_PATH, for example:
NAMES.DIRECTORY_PATH= (TNSNAMES)
In "$ ORACLE_HOME \ database \ network \ admin \ tnsnames.ora" create an additional section with the fully qualified domain name. How:
EXAMPLE = (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP) (HOST = example.domain.com) (PORT = 1521))) (CONNECT_DATA = (SERVICE_NAME = x99.domain.com) (SID = X)) )
EXAMPLE.DOMAIN.COM = (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP) (HOST = example.domain.com) (PORT = 1521))) (CONNECT_DATA = (SERVICE_NAME = x99.domain.com) (SID = X)))
Use tnsping to use both names for ping: 1) tnsping example; 2) tnsping example.domain.com - both names should respond.
NB! Use your own HOST, SERVICE_NAME and SID cource;)
I hope this helps someone.
BR
Raul
source share