MacLochlainns Weblog

Michael McLaughlin's Technical Blog

Site Admin

Oracle 12c on Windows 7

with 47 comments

Here are step-by-step instructions for installing Oracle Database 12c Release 1 on Windows 7. This is more or less to install a Desktop version of Oracle 12c. I posted other versions for Oracle Database 11gR1 and 11gR2. While some report that they installation doesn’t work for them, its typically because they didn’t configured their Windows 7 environment.

Here are some Windows 7 configuration caveats before you perform this installation, and they are:

Windows 7 Configuration Steps

  1. Make sure you have at least 3 GB of memory on your Windows PC, or that you can allocate 4 GB of memory to your virtual machine for Windows.
  2. Install Oracle’s JDK 7 for 64-bit OS with NetBeans and 32-bit OS when running on a 64-bit machine. The installer is smart enough to only install NetBeans once. The JDK 7 32-bit installation supports SQL Developer.
  3. Disable Microsoft’s User Access Controls (UAC). I blogged about a set of Windows 7 gripes, and the second point shows you the screen shots that let you disable UAC on Windows 7.
  4. Configure your C:\Windows\System32\drivers\etc\hosts file. Use lines 1 through 3 when you’re using a DHCP IP address, and lines 1 through 4 when you’re using a static IP address. If you want to set a static IP address, check this old post on how to set a static IP address. Please note that the hostname needs to be lowercase.
1
2
3
127.0.0.1      localhost
::1            localhost
127.0.0.1      oracle12c oracle12c.techtinker.com

Line 4, only use for a static IP address, would look like this on the 192.168.* subdomain:

4
192.168.0.5      oracle12c oracle12c.techtinker.com
  1. Create a user account name that doesn’t have a white space, like McLaughlinM in the screen shots, and assign it Administrator privileges. During the install, you’ll be prompted to create a non-administrator account to start Oracle.

Oracle Database 12c Release 1 Installation Steps

Oracle12cInstall01

  1. The first thing you need to do is unzip the two zip files into a common directory. I’ve chosen to create an OracleInstall folder. Oracle creates a database folder inside it. Within the database folder, click the Setup file to launch the Oracle Installer.

Oracle12cInstall02

  1. After launching the Oracle Installer, the Configure Security Updates screen is your first stop. You may provide your email (attached to your Oracle Support Contract) and Oracle Support password, or uncheck the box and you can simply install a Desktop test environment. Click the Next button to proceed.

Oracle12cInstall03

  1. The Software Updates is the next screen. If you want to check for updates, click and enter your Oracle Support credentials. If you want to install the base release, click the Skip software updates radio button. After making a choice about what you want to do with updates, click the Next button to proceed with the install.

Oracle12cInstall04

  1. The Installation Option screen lets you chose whether you want to Create and configure a database (sample database), Intall database software only, or Upgrade an existing database. Check the appropriate radio button and then click the Next button to proceed with the install.

Oracle12cInstall05

  1. The System Class screen lets you chose whether you want to install a Desktop class (ideal for develoers to play around in) or a Server class. Check the appropriate radio button and then click the Next button to proceed with the install.

Oracle12cInstall06

  1. The Oracle Home User Selection screen lets you chose whether you want to Use Existing Windows User (that’s fine if you created one previously), Create New Windows User (what I’ll do next), or Use Windows Built-in Account. Check the appropriate radio button and then click the Next button to proceed with the install.

Oracle12cInstall07

  1. The Oracle Home User Selection screen lets you Create New Windows User, and that’s what I’ve done with the oracle user (it could be whatever you like). Click the Next button to proceed with the install.

Oracle12cInstall08

  1. The Typical Install Configuration screen lets you customize your installation. I’ve only opted to provide an Oracle compliant password while accepting the defaults. Click the Next button to proceed with the install.

Oracle12cInstall09

  1. The Perform Prerequisite Checks screen initially displays a task bar. You need some patience, it’ll show you the next screen if everything is fine.

Oracle12cInstall10

  1. The Summary screen tells you what you’re going to install. Read it over, save a copy for later, and when everything is right then click the Next button to install.

Oracle12cInstall11

  1. The Install Product screen tells you what you’re installing and it can take some time. Don’t walk away too quickly because you’re most likely going to have to allow access for the installation to complete successfully.

Oracle12cInstall11

  1. You should see two Windows Security Alerts with the installation. Click the Allow access button to continue successfully.

Oracle12cInstall12

  1. The Database Configuration Assistant screen tells you that you’ve been successful to this point. Although, this is where several errors can occur when you failed to correctly configure Windows 7 before installation. This takes some time to run, here’s where you can take a break.

Oracle12cInstall13

  1. The second Database Configuration Assistant screen lets you configure passwords for the database accounts. I’m skipping that by accepting the defaults and clicking the OK button to proceed.

Oracle12cInstall14

  1. The Install Product screen reappears while most of the database cloning operation has finished. At this point, it starts configuring the Oracle Enterprise Manager (OEM). It can take a couple minutes to complete. Simply monitor it.

Oracle12cInstall15

  1. The Finish screen appears after everything has worked. Click the Close button to finish the install.

Oracle12cInstall16

  1. Now, you can open a Windows command shell and call the sqlplus executable with a /nolog option (denies login credentials form OS history files). Then, you can connect using the TNS orcl alias, which verifies your networking listener.ora and tnsnames.ora files are setup correctly. You should see the following in the command shell when the installation was successful.

C:\Users\mclaughlinm>sqlplus /nolog
SQL*Plus: Release 12.1.0.1.0 Production on Fri Jul 26 02:00:19 2013
 
Copyright (c) 1982, 2013, Oracle.  All rights reserved.
 
Connected to:
Oracle Database 12c Enterprise Edition Release 12.1.0.1.0 - 64bit Production
With the Partitioning, OLAP, Advanced Analytics and Real Application Testing options
SQL> connect system@orcl
Enter password:
Connected.

Oracle 12c changes the dynamics on users. You now have two types of databases. One is a Container Database (CDB) and the other is a Pluggable Database (PDB). While Oracle’s default container users, like SYS, SYSTEM, and so forth, remain unchanged, you create new CDB users with a C##<user_name> preface. PDB users are a different matter, and they can retain the same format used previously for user-defined users. You set PDB users as the ADMIN user for a pluggable database when you provision it.

Subsequent to this post, I’ve posted how you can provision an Oracle 12c Pluggable Database (PDB), and you can find it in this post. AS always, I hope that this helps those trying to find a quick shortcut on reading the instructions. 😉

Written by maclochlainn

July 26th, 2013 at 2:15 pm

47 Responses to 'Oracle 12c on Windows 7'

Subscribe to comments with RSS or TrackBack to 'Oracle 12c on Windows 7'.

  1. […] step-by-step for Oracle 11gR2 […]

  2. pls we’re can I download the software ?

    fredrick

    30 Jul 13 at 3:06 pm

  3. Fredrick, You can get the software here.

    maclochlainn

    1 Aug 13 at 11:24 pm

  4. […] Installing Oracle 12c on Windows 7 […]

  5. One of the bizare things when I tried to install oracle 12c on windows 7 is that is stopped at 59%.

    Do you know why?

    Thanks

    Mohamed

    24 Aug 13 at 2:56 am

  6. Mohamed, Try installing on the database files, and after that run DBCA to create the sample database. My hunch is that it’s failing while trying to clone the database.

    maclochlainn

    25 Aug 13 at 4:14 pm

  7. Great tuto!
    I have found that for simplicity in Windows 7 if you do not want to switch to oracleuser user to create a DB you need to add a couple of roles to an admin user:

    ORA_INSTALL
    ORA_OraDB12Home1_DBA

    In my case my Oracle 12 Home is called OraDB12Home1, yours might differ.

    Otherwise you will receive the dreaded error when creating a DB:

    ORA-03113: end-of-file ON communication channel

    Of course this is practical for developing environments (and perhaps lazy people like me :)), but for security of course is best to do it from the oracleuser environment.

    Renaud Montes

    29 Aug 13 at 8:03 am

  8. Renaud, When you reference “Admin” user, do you mean the ADMIN user for a plug gable database?

    maclochlainn

    29 Aug 13 at 11:47 am

  9. Maclochlainn,

    Windows 7 on my computer is a 32-bit version. Can I follow the steps you mentioned to install Oracle 12c which is 64 bit on a 32-bit Windows 7.

    Thanks.

    Kamal

    26 Sep 13 at 1:56 pm

  10. After installation i am able to connect from the SQL PLUS but when i tried connecting from SQL developer it is throwing error message Could not establish connection…
    Please help me….

    Hari

    30 Sep 13 at 4:51 am

  11. Hari, Open a command-line console and type the following to verify the listener resolves:

    tnsping orcl

    maclochlainn

    30 Sep 13 at 11:02 pm

  12. Kamal, You can’t install a 64-bit version of Oracle on a 32-bit OS. Unfortunately, there’s no 32-bit version of Oracle 12c to download.

    maclochlainn

    30 Sep 13 at 11:07 pm

  13. hello,

    oracle 12c installation is stopping during the 59% of the installation.

    please can any one tell me this installation will complete successfully or not ??

    how much time it takes?

    Srikanth

    5 Oct 13 at 8:28 am

  14. Srikanth, That’s generally a network problem. Try installing only the program files first. Then, use DBCA (Database Configuration Assistant) to create your database instance.

    maclochlainn

    12 Oct 13 at 9:18 pm

  15. Hi,

    I have done all the installation as you mentioned above, but when i try to create a new connection, i get the error 12505 “TNS:listener does not currently know of SID given in connect descriptor”.

    Have you already seen this error?
    I have been trying to fix it by searching on the internet, but nothing good.

    can you help me ?

    will

    15 Oct 13 at 5:16 pm

  16. Will, Are you connecting to a container or pluggable database? Did you assign a hostname in your hosts file?

    maclochlainn

    11 Nov 13 at 2:09 am

  17. Hi,

    I got the 59% problem too.
    It’s caused by unzipping the two downloaded files into separate directories. Unzip the first one into a directory and then unzip the 2nd one into the SAME directory. Then run setup.

    Chris

    Chris Phillips

    22 Dec 13 at 11:03 am

  18. Hi,

    This tutorial help me. Step by Step whitout complications and simple instrucctions. Very good.

    Pedro

    15 Jan 14 at 11:50 am

  19. While creating a database using Database Configuration Assistant I am getting erorr that it cannot add new member to local users group becuase this member does not exits. Anyone has a solution for this issue?

    stryjxx

    31 Mar 14 at 3:53 pm

  20. ORA-12154: TNS:could not resolve the connect identifier specified

    Getting this error when trying to do the last step here.Can any one please help?

    Arnie

    7 Apr 14 at 2:08 pm

  21. Hi, while I was installing db 12c , it was installing correctly but at the time when it was almost 70-80% already installed and database configuration assistant was installing and creating the database it showed an error i.e failed to create database… something like that. So, what was wrong ? and how do I clean the failed installation files? pls help me quickly…
    Thanks

    Subham Raoniar

    17 Apr 14 at 10:48 am

  22. Subham, Did you make a Registry copy before the installation? If not, the bad news is the only way you can guarantee removal is to re-install the Windows OS.

    maclochlainn

    18 Apr 14 at 3:08 am

  23. Hello, thanks for this tut.. Found a great deal of information here.

    I do have some questions about Oracle 12C.
    System: 64bit
    OS: Windows 7 64bit
    Oracle: 12c 64bit

    Installation went smooth and completed installing everything.

    One question really is, how do I connect to it from MS Excel 2010?

    TNS_ADMIN Environment Variables configured:
    H:\app\XXXXXXX\product\12.1.0\dbhome_1\NETWORK\ADMIN\

    Anyway to connect to Oracle 12C 64bit using MS Excel 2010?

    Nodols24

    21 Jun 14 at 6:19 am

  24. Nodols24, I think you want these instructions from another post on connecting Microsoft Excel to Oracle 11g.

    maclochlainn

    21 Jun 14 at 10:43 am

  25. Thank u this blog helped me a lot.

    sindhu

    28 Jul 14 at 2:57 am

  26. are the software free for devs?

    john

    22 Jan 15 at 7:19 pm

  27. John, You should check Oracle’s licensing for that.

    maclochlainn

    1 Feb 15 at 11:37 pm

  28. How do I get past the ORA-12514: TNS Listerner does not currently know of service?
    When the database is started from the Service then connect SYS as SYSDBA works. But I want to drop APEX and the user can only be dropped if the database is in upgrade mode.

    Oracle 12.1.0.1

    Amin Adatia

    27 Mar 15 at 2:55 pm

  29. by the way tnsping works (10ms)

    Amin Adatia

    27 Mar 15 at 7:57 pm

  30. Perhaps the following might shed some light .. I am out of my wits

    Microsoft Windows [Version 6.1.7601]
    Copyright (c) 2009 Microsoft Corporation.  All rights reserved.
     
    D:\KTScase\Dba>ping localhost
     
    Pinging KTS64 [::1] with 32 bytes of data:
    Reply from ::1: time>1ms
    Reply from ::1: time>1ms
    Reply from ::1: time>1ms
    Reply from ::1: timeping kts64
     
    Pinging kts64 [10.10.0.101] with 32 bytes of data:
    Reply from 10.10.0.101: bytes=32 time>1ms TTL=128
    Reply from 10.10.0.101: bytes=32 time>1ms TTL=128
    Reply from 10.10.0.101: bytes=32 time>1ms TTL=128
    Reply from 10.10.0.101: bytes=32 timetnsping k12c

    Use the tnsping utility:

    D:\KTScase\Dba>tnsping kts64
    TNS Ping Utility for 64-bit Windows: Version 12.1.0.1.0 - Production on 27-MAR-2015 21:59:21
     
    Copyright (c) 1997, 2013, Oracle.  All rights reserved.
     
    Used parameter files:
    C:\Oracle\Ora12c\NETWORK\ADMIN\sqlnet.ora
     
    Used TNSNAMES adapter to resolve the alias
    Attempting to contact (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = kts64)(PORT = 1521)) (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521)) (ADDRESS = (PROTOCOL = TCP)(HOST = 10.10.0.101)(PORT = 1521))) (CONNECT_DATA = (SERVICE_NAME = K12C)))
    OK (10 msec)

    I can connect like this:

    D:\KTScase\Dba>sqlplus /nolog
     
    SQL*Plus: Release 12.1.0.1.0 Production on Fri Mar 27 21:59:53 2015
     
    Copyright (c) 1982, 2013, Oracle.  All rights reserved.
     
    SQL> connect SYS@k12c as SYSDBA
    Enter password:
    Connected.
    kts64~k12c~K12C~CDB$ROOT-SYS> shutdown immediate
    Database closed.
    Database dismounted.
    ORACLE instance shut down.
    kts64~k12c~K12C~CDB$ROOT-SYS> exit
    Disconnected from Oracle Database 12c Enterprise Edition Release 12.1.0.1.0 - 64bit Production
    With the Partitioning, Oracle Label Security, OLAP, Advanced Analytics and Real Application Testing options

    Try tnsping against k12c instance:

    D:\KTScase\Dba>tnsping k12c
     
    TNS Ping Utility for 64-bit Windows: Version 12.1.0.1.0 - Production on 27-MAR-2015 22:01:10
     
    Copyright (c) 1997, 2013, Oracle.  All rights reserved.
     
    Used parameter files:
    C:\Oracle\Ora12c\NETWORK\ADMIN\sqlnet.ora
     
    Used TNSNAMES adapter to resolve the alias
    Attempting to contact (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = kts64)(PORT = 1521)) (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521)) (ADDRESS = (PROTOCOL = TCP)(HOST = 10.10.0.101)(PORT = 1521))) (CONNECT_DATA = (SERVICE_NAME = K12C)))
    OK (10 msec)

    Changing the service name, doesn’t let me connect to the database:

    D:\KTScase\Dba>sqlplus /nolog
     
    SQL*Plus: Release 12.1.0.1.0 Production on Fri Mar 27 22:01:20 2015
     
    Copyright (c) 1982, 2013, Oracle.  All rights reserved.
     
    SQL> connect SYS@k12c as SYSDBA
    Enter password:
    ERROR: ORA-12514: TNS:listener does not currently know of service requested in connect descriptor

    Amin Adatia

    27 Mar 15 at 8:03 pm

  31. Amin,

    I’ve tried to make sense from your message but I’m not sure what you are trying to do. Are you trying to connect to a pluggable database? If so, this older post may help you. If not, please help me understand your trying to accomplish.

    maclochlainn

    27 Mar 15 at 9:56 pm

  32. Amin, You want to remove APEX after the install?

    maclochlainn

    27 Mar 15 at 10:05 pm

  33. I want to just drop APEX that comes with v12.1.0.1 and install the new v4.2.6. I do not have the MySupport access to get the upgrade patch and I cannot make head or tail of the scripts that come with 12.1.0.2 to do the upgrade. The pre-upgrade check says I have the version 4.2. However, DBUA hangs at the pre-requisite check waiting for the APEX to get upgraded to 4.2.5+

    in any case, I thought I would install the APEX 4.2.6 from scratch. So I need to drop the existing APEX but to do so needs the database to be in Upgrade mode

    I am connecting to the container database from

    sqlplus /nolog

    but I get the TNS Error.

    So how do I solve the issue of connecting from the “DOS” window?

    Amin Adatia

    28 Mar 15 at 6:43 pm

  34. and when I run the script as suggested to remove APEX

    kts64~k12c~K12C~CDB$ROOT-SYS> @C:\Oracle\Ora12c\apex\apxremov_con.sql
     
    PL/SQL procedure successfully completed.
     
    catconInit: database is not open
    Unexpected error encountered in catconInit; exiting

    Amin Adatia

    28 Mar 15 at 6:53 pm

  35. Amin, I don’t know what’s up on your system, and I’m not in a position to create a test case for you.

    maclochlainn

    31 Mar 15 at 6:45 pm

  36. Yes, I understand but I’m not in a position to build a test case for you.

    maclochlainn

    31 Mar 15 at 6:50 pm

  37. Great !!!

    Installation done Successfully :)

    rakesh soni

    15 Apr 15 at 6:30 am

  38. Is there an uninstall script for 12c on Windows. interrupted an install because it seemed to be taking too long. Thanks.

    TOlowu

    13 May 15 at 6:51 pm

  39. TOlowu, Windows provides the ability to archive your Windows Registry to uninstall a failed application. If you didn’t backup the Windows Registry before attempting the installation of Oracle 12c, you’ll have to manually cleanup the Windows Registry.

    maclochlainn

    14 May 15 at 11:23 pm

  40. I’m using Windows 8.1 Will it be fine if I install using the directions provided?

    Raghav Gupta

    17 Jul 15 at 8:38 am

  41. Folks, there is no alert, but the solution is to run the “setup.exe” as Administrator. Otherwise the attempt to update the Windows registry keeps it hanging.

    I still have a problem with all the missing file but I am trying to bypass them for now.

    Akshay Jain

    19 Jul 15 at 8:14 pm

  42. Raghav, It should be the same.

    maclochlainn

    21 Jul 15 at 7:56 pm

  43. Hi MacLochlainn,

    A very easy to follow and complete set of instructions.

    I have also posted a 12c and Oracle RAC install guide on Solaris and other platforms at http://www.vitalsofttech.com/oracle-12c-database-installation-on-solaris-11/ .

    Hopefully it’s of help to others.

    Natik Ameen

    29 Jul 15 at 2:25 pm

  44. hello,
    i need help with my 12c installation on windows 8.
    i am getting two sets of errors
    1 C:\app\product\12.1.0\dbhome_1\perl\bin\perl.exe
    2[INS-20802] Oracle Database Configuration Assistant failed.
    Details: The plug-in failed in its perform method
    please how do i resolve these issues?
    thank you.

    Tomiwa

    11 Aug 15 at 11:47 pm

  45. Tomiwa, I haven’t done it on Windows 8. I’ll be testing that in September. You can check back then if you haven’t solved it.

    However, that type of error typically occurs due to networking configuration issues.

    maclochlainn

    15 Aug 15 at 11:51 pm

  46. Configure your C:\Windows\System32\drivers\etc\hosts file. Use lines 1 through 3 when you’re using a DHCP IP address, and lines 1 through 4 when you’re using a static IP address.

    127.0.0.1      localhost
    ::1            localhost
    127.0.0.1      oracle12c oracle12c.techtinker.com

    Where is line 4 ? :/

    Bruno

    17 Aug 15 at 3:40 pm

  47. Bruno, I’ve updated an example, using the standard home network subdomain.

    maclochlainn

    19 Aug 15 at 10:54 pm

Leave a Reply