QuestionHow to set an Oracle connection to use TNSNames.ora or LDAP.ora. Environment. Tableau Desktop. Tableau Server. Oracle AnswerBefore performing the below steps, ensure that Oracle Net Service has been installed on the machine hosting Tableau Desktop or Tableau Server. To install Oracle Net Services, you run Oracle Database Client software installer, and choose the component 'Oracle Net Services' to be installed. Oracle Database Client software is available on installation media or you can download it from the Oracle Technology Network website.
To learn more about Oracle Net Services, see. Step 1:. Close Tableau Desktop if it is open. Ensure that you have downloaded and installed the Oracle drivers for Mac from Tableau's page. Copy an existing LDAP.ora or TNSNames.ora file containing connection information to /etc:. In Finder, select Go Go To Folder, and then type /etc.
Peggle Download Mac. Download Mac Os Sierra To Usb. The software is available as a media or FTP request for those customers who own a valid Oracle Database product license for any edition.
Copy the.ora file to /etc. Step 2: Configure the TNSADMIN environment variable. Start Terminal and type the following command: sudo nano /etc/launchd.conf Note: Nano is a text-based editor that is always available on Mac computers.
Type your password when prompted. Type the following: launch setenv TNSADMIN /etc. Press Ctrl-X, then Y, then Enter to save changes and exit nano. Restart your Mac. Step 3: Verify that the TNSADMIN variable was set:. Start Terminal and type the following command: export. You will see a list of all system variables.
Look for: declare -x TNSADMIN='/etc'. Confirm that DNS resolution is working for the host name listed in the.ora file by pinging the host name in Terminal or Network Utility. Use a fully-qualified domain name, such as servername.domain.com, instead of a simple server name. You should now be able to start Tableau Desktop on your Mac and connect to the Oracle database, providing only the server name from the TNSNames.ora or LDAP.ora file. Step 1: Verify whether a tnsnames.ora file exists on the computer running Tableau Server. By default, if the Oracle client is installed on this computer, the tnsnames.ora file will be located in the following directory: $ORACLEHOME/network/admin.
The command echo $ORACLEHOME will print the file path. The command find $ORACLEHOME -name tnsnames.ora will print the location of the tnsnames.ora file in that directory. It is not necessary to have the Oracle client installed to use tnsnames.ora with Tableau Server. If no tnsnames.ora file is present on this computer, create one using a text editor. The tnsnames.ora file name is case sensitive, and must be in all lower-case letters. The file should not use tab-spacing. Below is a potential template for an entry.
Elements in brackets must be replaced by values obtained from your database administrator. Note: Although a TNSNames.ora file on a Windows or Mac computer may not require the ADDRESSLIST entry, the tnsnames.ora file on a Linux computer requires this variable. netservicename= (DESCRIPTION= (ADDRESSLIST= (ADDRESS=protocoladdressinformation) ) (CONNECTDATA= (SERVICENAME=servicename) ) ) For example: Production = (DESCRIPTION = (ADDRESSLIST = (ADDRESS = (PROTOCOL = TCP)(HOST = prod.corp.com)(PORT = 1521) ) (CONNECTDATA = (SERVICENAME = orcl) ) ) Step 2: Set the TNSADMIN environment variable. In a text editor, open the file /etc/systemd/system/tabsvc0.service. Note: Starting from version 2018.1, the file 'tabsvc0.service' is located at: /var/opt/tableau/tableauserver/.local/share/systemd/user/tabsvc0.service. Add the following line: Environment=TNSADMIN=/path/to/file-folder.
Save the changes to the file. It may be necessary to restart your computer for the environment changes to take effect. Note: The environment path should not have a trailing slash; if the format of the path is incorrect, users may encounter an ORA-12154 error. Step 3: Set permissions for the tnsnames.ora file. Navigate to the file path where the tnsnames.ora file is located.
Grant permissions to the file by running the command: chmod 666 tnsnames.ora. Verify file permissions with the following command: ls -l Additional InformationThe following common Oracle errors can be corrected or avoided by setting up your data connection to use TNSNames.ora or LDAP.ora. ORA-12154: TNS: could not resolve the connect identifier specified. ORA-12514: TNS listener does not currently know of service requested in connect descriptor.
ORA-12541: TNS: no listener. ORA-12170: TNS:Connect timeout occurred. ORA-12504: TNS listener was not given the SERVICENAME in CONNECTDATA Did this article resolve the issue?