Loading

Error "IO Error: The Network Adapter could not establish the connection" Occurs When Connecting to Oracle Using Net Service Name(TNSNames.ora)

Дата публикации: Jul 14, 2025
Описание

When connecting to Oracle from Tableau Desktop or Tableau Prep, the error below occurs and is unable to connect to Oracle.

"IO Error: The Network Adapter could not establish the connection

Unable to connect to the Oracle server "<server>". Check that the server is running and that you have access privileges to the requested database."
 

When the issue occurs, the below error was found in jprotocolserver.log.
”Caused by: java.net.UnknownHostException: Unknown Host Name (XXXX)

Cause

The environment variable for TNS_ADMIN is not set in the machine's environment.
Решение
Please set the TNS_Admin environment variable when using Net Service Name(TNSNames.ora)

For Windows:
1. Select Start > Control Panel > System 
2. Select Advanced System Settings
3. In the System Properties dialog box, on the Advanced tab, select Environment Variables. 
4. Under System Variables, click New. 
5. In the New System Variable dialog box, enter the following, then click OK: 
  • Variable name: TNS_ADMIN 
  • Variable value: the directory containing the TNSNames.ora file.
6. Click OK in the Environment Variables dialog box and the System Properties dialog box. 
7. Restart Tableau Desktop or Tableau Prep to ensure that the new variable is recognized. 

For Mac:
1. Start Terminal and type the following command:
sudo nano /etc/launchd.conf
2. Type your password when prompted.
3. Type the following:
launch setenv TNS_ADMIN /etc
4. Press Ctrl-X, then Y, then Enter to save changes and exit nano.
5. Restart your Mac.
Дополнительные ресурсы
This is an error when TNSNames.ora is used. Tableau Desktop or Tableau Prep could connect to Oracle by inputting Host Name, Port, and Service Name.

Please also refer to the below article for setting TNSNames.ora
Setting an Oracle Connection to Use TNSNames.ora or LDAP.ora

Error "IO Error: The Network Adapter could not establish the connection" When Connecting to Oracle

Номер статьи базы знаний

001474905

 
Загрузка
Salesforce Help | Article