Return to site

Installing Sql Developer On Parallels For Mac

broken image
Parallels

One part of setting up my new laptop was also setting up SQL Developer WITH Oracle Driver, because a year or two ago I rolled out radius authentication for all users who need to access the production databases directly and radius (and other non-default-password authentication schemes) do not work with thin JDBC driver. Being new to Macworld and not finding any guides for this task online, it was quite a struggle in the beginning. Here I’m trying to share my experiences if anybody else find themselves in the similar situation. If you find any mistakes here, please let me know – I’m new to the world of MacOS 🙂

Jan Karremans just today published a similar article about Mac and Instant client, but the goal of my blog post is to get SQL Developer connected through Instant Client.

Developer

JDK

Installing sql developer on parallels for mac free

First you need Java installed, I installed 64-bit JDK8, but it would be better to install 64-bit JDK7, since SQL Developer 4.0 is not supported on JDK8.

SQL Developer

When I’m writing this, SQL Developer 4.1 is in Early Adopter release and 4.0 is in production. I installed SQL Developer 4.0.3.

Installing Sql Developer On Parallels For Mac Os

Oracle Instant Client

There is another reason to choose SQL Developer 4.0 over 4.1 – 4.1 requires version 12.1 of the Oracle Client and that is not yet released for MacOS. SQL Developer 4.0 requires Oracle Client 11.2.0.3 and that is available for MacOS. I downloaded Instant Client 11.2.0.3 (64-bit – since I installed 64-bit JDK): instantclient-basic-macos.x64-11.2.0.3.0.zip and instantclient-sqlplus-macos.x64-11.2.0.3.0.zip to be precise. I unzipped both these files under /opt so my Instant Client installation directory is /opt/instantclient_11_2. After unzipping, Instant Client installation instructions require creating the following symlinks:

Configuring SQL Developer

Open SQL Developer, open Preferences and go to Database > Advanced. Configure Oracle Client paths and check Use Oracle Client and Use OCI/Thick driver boxes. Here is the sample screenshot from my settings.
When you press the Configure button to set the Oracle client path, there is also a button to Test if the Client was loaded correctly. Currently this test should fail.

Setting the environment variables

We need to set two environment variables: DYLD_LIBRARY_PATH to make sure applications can find and load the instant client libraries and TNS_ADMIN so instant client could find sqlnet.ora and tnsnames.ora files. In my case sqlnet.ora is essential, since I need to use Radius authentication.

First I added these environment variables to ~/.profile:

After restarting terminal and verifying that these environment variables are indeed set, execute SQL Developer app directly from terminal by executing open /Applications/SQLDeveloper.app/.

Installing Sql Developer On Parallels For Mac

Open preferences and press the Oracle Client Test button again, now the test should succeed and SQL Developer is connected through Instant Client.
All good! Great success! Guess again… Close SQL Developer and launch it from Docker/Launchpad and you will see the Oracle Client test failing again. This is because the environment variables under ~/.profile or ~/.bash_profile are loaded only inside Terminal.

Installing sql developer on parallels for mac free

One part of setting up my new laptop was also setting up SQL Developer WITH Oracle Driver, because a year or two ago I rolled out radius authentication for all users who need to access the production databases directly and radius (and other non-default-password authentication schemes) do not work with thin JDBC driver. Being new to Macworld and not finding any guides for this task online, it was quite a struggle in the beginning. Here I’m trying to share my experiences if anybody else find themselves in the similar situation. If you find any mistakes here, please let me know – I’m new to the world of MacOS 🙂

Jan Karremans just today published a similar article about Mac and Instant client, but the goal of my blog post is to get SQL Developer connected through Instant Client.

JDK

First you need Java installed, I installed 64-bit JDK8, but it would be better to install 64-bit JDK7, since SQL Developer 4.0 is not supported on JDK8.

SQL Developer

When I’m writing this, SQL Developer 4.1 is in Early Adopter release and 4.0 is in production. I installed SQL Developer 4.0.3.

Installing Sql Developer On Parallels For Mac Os

Oracle Instant Client

There is another reason to choose SQL Developer 4.0 over 4.1 – 4.1 requires version 12.1 of the Oracle Client and that is not yet released for MacOS. SQL Developer 4.0 requires Oracle Client 11.2.0.3 and that is available for MacOS. I downloaded Instant Client 11.2.0.3 (64-bit – since I installed 64-bit JDK): instantclient-basic-macos.x64-11.2.0.3.0.zip and instantclient-sqlplus-macos.x64-11.2.0.3.0.zip to be precise. I unzipped both these files under /opt so my Instant Client installation directory is /opt/instantclient_11_2. After unzipping, Instant Client installation instructions require creating the following symlinks:

Configuring SQL Developer

Open SQL Developer, open Preferences and go to Database > Advanced. Configure Oracle Client paths and check Use Oracle Client and Use OCI/Thick driver boxes. Here is the sample screenshot from my settings.
When you press the Configure button to set the Oracle client path, there is also a button to Test if the Client was loaded correctly. Currently this test should fail.

Setting the environment variables

We need to set two environment variables: DYLD_LIBRARY_PATH to make sure applications can find and load the instant client libraries and TNS_ADMIN so instant client could find sqlnet.ora and tnsnames.ora files. In my case sqlnet.ora is essential, since I need to use Radius authentication.

First I added these environment variables to ~/.profile:

After restarting terminal and verifying that these environment variables are indeed set, execute SQL Developer app directly from terminal by executing open /Applications/SQLDeveloper.app/.

Open preferences and press the Oracle Client Test button again, now the test should succeed and SQL Developer is connected through Instant Client.
All good! Great success! Guess again… Close SQL Developer and launch it from Docker/Launchpad and you will see the Oracle Client test failing again. This is because the environment variables under ~/.profile or ~/.bash_profile are loaded only inside Terminal.

Setting environment variables on login

This seems to be the most complex part of this story since it seems to change with every MacOS release. The method that is working for me under Yosemite (and in no way am I declaring that it is the best method, I am a Mac newbie after all), is this:

Open application Script Editor and paste the following AppleScript there:

Yes, it is also necessary to set TNS_ADMIN, since setting the TNS admin directory path under SQL Developer preferences does not work if you need to use specific settings in sqlnet.ora, for example authentication.

Installing Sql Developer On Parallels For Mac Windows 7

Save the script and in the save dialog set File format: Application. And finally System settings -> Users & Groups -> Login items press + sign and select the application you just saved. Now, log out from MacOS and log back in. Now SQL Developer should work with Instant Client even when you launch it from Launchpad.

I got this method from a Stackoverflow thread.

At Parallels, we love sharing our customers’ success stories! Recently, Tim Goldstein, a leading business intelligence analyst, database architect, and senior developer specializing in the Microsoft SQL server tool set, implemented a more agile development process with Parallels Desktop for Mac. Goldstein’s new process has been a great success and proven Parallels Desktop to be a developer’s “Swiss Army Knife” of productivity! Below are a few quotes from Goldstein himself regarding how Parallels Desktop has helped him stay ahead of the competitive landscape in his personal business:

“Parallels allows me to run a full development environment on Windows, including SQL Server, Analysis Services Server, Visual Studio, and SQL Management console simultaneously with El Capitan. I am running this on an 11-inch MacBook Air with 8 GB of RAM and a two-core i7 processor.”

Not only is the Microsoft SQL Server Management Studio a crucial weapon in a developer’s tool kit but Goldstein leverages success by additionally using Microsoft Visual Studio, CorelDRAW, and Notepad++.

Above: “Windows 10 running Microsoft SQL Server, SQL Management Studio (SSMS), SQL Data Tools (a.k.a. Visual Studio) with an SSIS package, and working on an infographic for my speaking/training topic of “Engaging Technical Workers, Getting Business and Technical Staff Communicating” in CorelDRAW.”

Sql Developer Install Steps

Goldstein has additionally leveraged Parallels Desktop to save money for his business. He’s achieved this by not having to own multiple computers to complete his work as a senior developer. Thanks to his love of technology and the people who have helped him have such a great IT career, Goldstein, a Certified High Performance Coach, is simultaneously speaking, training, and mentoring executives on how to understand the mind of the technical worker. He can help you reach your next level just like Parallels Desktop has helped him reach his! In his own words:

“For my personal business in training executives to understand their technical workforce and training geeks to better handle the soft side of interviews, I work entirely on a Mac. Parallels has been a wonderful solution and a much easier company culture to deal with than competitors.”

Connect with Tim Goldstein via LinkedIn here, or check out his personal website here.

Need Microsoft Windows operating system? Buy Below:

Installing Sql Developer Windows 10

Want to make your life easier with Parallels Desktop? Try it for free for 14 days: Try Now





broken image