Installing 12c R1 database on oracle linux

31
First, log in to Oracle Software Delivery Cloud , and search for the 12cR1 database software. Since I am running a 64-bit OS, I chose Linux x86-64 as the platform for the search. Click on the link titled "Oracle Database 12c Release 1 (12.1.0.1.0) Media

Transcript of Installing 12c R1 database on oracle linux

Page 1: Installing 12c R1 database on oracle linux

First, log in to Oracle Software Delivery Cloud, and search for the 12cR1 database software. Since I am running a 64-bit OS, I chose Linux x86-64 as the platform for the search.

Click on the link titled "Oracle Database 12c Release 1 (12.1.0.1.0) Media Pack for Linux x86-64"

Page 2: Installing 12c R1 database on oracle linux

and download the two zip files titled "Oracle Database 12c Release 1 (12.1.0.1.0) for Linux x86-64 (Part 1 of 2)" and "Oracle Database 12c Release 1 (12.1.0.1.0) for Linux x86-64 (Part 2 of 2)" - depending on your download speed, this may take a few hours.

Copy the two zip files from the host Windows machine into the guest Linux VM using the shared folders defined in this previous post. As the oracle unix user, unzip the two zip files using the unzip command, and a folder named "database" will be created. (If the unzip command reports errors, this typically implies that the downloaded zip files are corrupt - you may have to download the zip files again). On my machine, after unzipping the two files, I renamed the "database" folder to "database_12c" for clarity.

Review the 12cR1 Linux Install Guide before proceeding with the installation. If you have a previous/older Oracle install on the VM server, ensure that you backup the oraInventory directory before proceeding. The location of this directory is documented in file /etc/oraInst.loc.

Start the install by executing the "runInstaller" script.

Page 3: Installing 12c R1 database on oracle linux

On the first install screen, provide your My Oracle Support credentials if you have them. For the purposes of this install, I chose not to use this feature. Click Next button.

Page 5: Installing 12c R1 database on oracle linux

Again, for the purposes of this blog post, I chose to skip software updates.

Page 6: Installing 12c R1 database on oracle linux

Choose the default option to create and configure a database, then click Next. (Alternatively, you can choose to install the software only, then create a database later using the DBCA utility)

Page 7: Installing 12c R1 database on oracle linux

Choose Desktop Class, then click Next. (Desktop Class is defined in the Install Guide)

Page 8: Installing 12c R1 database on oracle linux

Enter the paths for "Oracle base", "Software location" and "Database file location" as appropriate. Choose "Enterprise Edition" for the edition and AL32UTF8 for the characterset. Choose and appropriate "Global database name" and strong passwords. Check the box to create container and pluggable database. Understand the multitenant conceptbefore proceeding. Click Next.

Page 9: Installing 12c R1 database on oracle linux

Ensure that you provide a strong admin password. For this blog post, I chose a simple password - click Yes to continue.

Page 10: Installing 12c R1 database on oracle linux

Review the Summary screen, and if everything is as expected, click the Install button.

Page 11: Installing 12c R1 database on oracle linux

The Installer will then proceed with the installation process.

Page 16: Installing 12c R1 database on oracle linux

You will be prompted to execute the root.sh script as root.

Page 17: Installing 12c R1 database on oracle linux

Run the root.sh script in a separate terminal window as instructed - use the default prompt for the "local bin directory" variable, then choose to overwrite the 3 environment files (this will happen only if these files are present from a previous install).

Page 18: Installing 12c R1 database on oracle linux

Close the root terminal window, then click OK on the Installer screen. The database configuration process will start. This process may take a while depending on your VM configuration.

Page 24: Installing 12c R1 database on oracle linux

 When the 12cR1 database creation process is complete, you will see

Page 25: Installing 12c R1 database on oracle linux

Note that all seeded database accounts except for SYS and SYSTEM are locked. You can choose to unlock them at this point (click on Password Management button), or accounts can be unlcoked later manually. Click OK, then click Close to exit the installer.

Page 26: Installing 12c R1 database on oracle linux

Set these environment variables

# export ORACLE_BASE=/u01/app/oracle# export ORACLE_HOME=/u01/app/oracle/product/12.1.0/dbhome_1# export ORACLE_SID=orcl12c1# export PATH=$ORACLE_HOME/bin:$PATH# export TNS_ADMIN=$ORACLE_HOME/network/admin

and then connect to the container database by issuing command

# sqlplus / as sysdba

and query the database name

select database_name from v$database;

Page 27: Installing 12c R1 database on oracle linux

We have successfully connected to the container database (CDB). Next, we need to open the pluggable database (PDB) "pdborcl" created as part of this install. Note that PDBs are not opened automatically after a CDB is started.

Issue command "alter pluggable database pdborcl open read write" to open the PDB database.

Page 28: Installing 12c R1 database on oracle linux

Edit the tnsnames.ora file (found in $TNS_ADMIN directory) and add a TNS entry for the PDB pdborcl. The service name in the entry should point to the PDB (pdborcl.localdomain in this case).

Page 29: Installing 12c R1 database on oracle linux

Exit out of the CDB connection and connect to the PDB using the syntax

# sqlplus <username>/<password>@<pdb_tns_alias>

Verify that you have connected to the PDB by issuing command

show con_name