I am proud of our technical management team at Viscosity North America. We spent some time at Oracle OpenWorld providing our input on Oracle Linux. Surprisingly, each of us provided a different perspective and ended up being a rather comprehensive review. Please listen to our reviews of Oracle Linux and why it is the differentiator in the industry:

https://vimeo.com/user5833792/review/240041498/c4d1192768 (Rich)

https://vimeo.com/user5833792/review/240041428/2700323569 (Nitin)

https://vimeo.com/user5833792/review/240040559/d7cc713829 (Charles)

https://vimeo.com/user5833792/review/240041244/442d5b06f1 (Jerry – Docker Containers)

Posted by Charles Kim, Oracle ACE Director



Here’s an example to create a user account for Charles:

/usr/sbin/groupadd -K GID_MIN=500 -K GID_MAX=10000 ckim
/usr/sbin/useradd -g ckim -K UID_MIN=500 -K UID_MAX=10000 -c "Charles Kim" -d /home/ckim -m -s /bin/bash ckim

Then here is another example of creating a user for David:

# set -o vi
# for i in dknight; do groupadd -K GID_MIN=500 -K GID_MAX=10000 $i; /usr/sbin/useradd -g $i -K UID_MIN=500 -K UID_MAX=10000 -d /home/$i -m -s /bin/bash $i ; chage -d0 $i;echo "newpassword" | passwd --stdin $i;done
Changing password for user dknight

Every DBA should know how to leverage these commands. DBAs need to add this list of commands in their arsenal.

NewImage

Additional commands for your toolkit:
free –g (Memory free in Gigabytes)
free –g –s 1 (Display free in Gigabytes, update every second)

sar -u 2 10 (Report CPU utilization for each 2 seconds. 10 lines are displayed.)


Abstract

Learn the secrets of the trade to rapidly provisioning Oracle DB Infrastructure-As-A-Service. This extreme session will cover topics of delivering Linux-As-S-Service, RAC-As-A-Service, ASM-As-A-Service, Database-As-A-Service, Backup-As-A-Service, and even Data-Guard-As-A-Service . Advanced techniques to deploy enterprise RAC and non-RAC database deployments in an automated fashion will be shared . Save days and even weeks of deploy time by attending this session. There is no reason why you as a DBA or Architect, should not be able to deploy a fully patched RAC environment from bare metal Linux and create a RAC database in less than one hour. Anyone deploying RAC or even non-RAC will learn the secret sauce and knowledge of how to properly deploy mission critical systems that is repeatable and consistent. Learn to deploy a fully patched (11.2.0.3 or 11.2.0.4 with PSU x or 12.1 with PSU x) two node RAC in less than one hour.

Learn how to automate database builds and to leverage golden image database templates.

We can’t forget about multi-tenant deployment of Oracle 12c Pluggable Databases. Learn how to deploy pluggable databases (PDB) and to migrate PDBs and significantly increase your database consolidation density.

The details of adding nodes to an existing clusters and removing nodes from the cluster will also be disseminated.

Collaborate 2014 – Extreme Oracle DB Infrastructure As A Service.pdf


For Oracle Linux 6 or Red Hat Enterprise Linux 6

# cat rhel6.req.txt
binutils-2.20.51.0.2-5.11.el6 (x86_64)
compat-libcap1-1.10-1 (x86_64)
compat-libstdc++-33-3.2.3-69.el6 (x86_64)
compat-libstdc++-33-3.2.3-69.el6 (i686)
gcc-4.4.4-13.el6 (x86_64)
gcc-c++-4.4.4-13.el6 (x86_64)
glibc-2.12-1.7.el6 (i686)
glibc-2.12-1.7.el6 (x86_64)
glibc-devel-2.12-1.7.el6 (x86_64)
glibc-devel-2.12-1.7.el6 (i686)
ksh
libgcc-4.4.4-13.el6 (i686)
libgcc-4.4.4-13.el6 (x86_64)
libstdc++-4.4.4-13.el6 (x86_64)
libstdc++-4.4.4-13.el6 (i686)
libstdc++-devel-4.4.4-13.el6 (x86_64)
libstdc++-devel-4.4.4-13.el6 (i686)
libaio-0.3.107-10.el6 (x86_64)
libaio-0.3.107-10.el6 (i686)
libaio-devel-0.3.107-10.el6 (x86_64)
libaio-devel-0.3.107-10.el6 (i686)
libXext-1.1 (x86_64)
libXext-1.1 (i686)
libXtst-1.0.99.2 (x86_64)
libXtst-1.0.99.2 (i686)
libX11-1.3 (x86_64)
libX11-1.3 (i686)
libXau-1.0.5 (x86_64)
libXau-1.0.5 (i686)
libxcb-1.5 (x86_64)
libxcb-1.5 (i686)
libXi-1.3 (x86_64)
libXi-1.3 (i686)
make-3.81-19.el6
sysstat-9.0.4-11.el6 (x86_64)

For Oracle Linux 7 or Red Hat Enterprise Linux 7

# cat  rhel7.req.txt
binutils-2.23.52.0.1-12.el7.x86_64 
compat-libcap1-1.10-3.el7.x86_64 
gcc-4.8.2-3.el7.x86_64 
gcc-c++-4.8.2-3.el7.x86_64 
glibc-2.17-36.el7.i686 
glibc-2.17-36.el7.x86_64 
glibc-devel-2.17-36.el7.i686 
glibc-devel-2.17-36.el7.x86_64 
ksh
libaio-0.3.109-9.el7.i686 
libaio-0.3.109-9.el7.x86_64 
libaio-devel-0.3.109-9.el7.i686 
libaio-devel-0.3.109-9.el7.x86_64 
libgcc-4.8.2-3.el7.i686 
libgcc-4.8.2-3.el7.x86_64 
libstdc++-4.8.2-3.el7.i686 
libstdc++-4.8.2-3.el7.x86_64 
libstdc++-devel-4.8.2-3.el7.i686 
libstdc++-devel-4.8.2-3.el7.x86_64 
libXi-1.7.2-1.el7.i686 
libXi-1.7.2-1.el7.x86_64 
libXtst-1.2.2-1.el7.i686 
libXtst-1.2.2-1.el7.x86_64 
make-3.82-19.el7.x86_64 
sysstat-10.1.5-1.el7.x86_64

Oracle PreInstall RPM for Oracle Linux is one the biggest benefits of adopting Oracle Linux. With a single command, you can pre-configure the Oracle Linux environment for OEM 12c Agent, EBS R12, and Oracle Database 11gR2/12c installations. Not only does Oracle configure the Linux environment, but many of the best practices are incorporated in the process.

Oracle provides the PreInstall RPMs for the database on different channels from the EBS R12 or OEM 12c Agent PreInstall RPMs. For EBS and OEM 12c Agent PreInstall RPMs, you can download the PreInstall RPMs from the addons channel from the public-yum repository. Oracle provides a separate RPM for each release of OEM 12c.

http://public-yum.oracle.com/repo/OracleLinux/OL6/addons/x86_64/

2014 10 12 11 41 25

For Oracle Database PreInstall RPMs for Oracle Database 11g Release 2 and Oracle Database 12c Release 1, you can download them from the RPM from the latest channel from the public-yum repository. You will have to scroll down quite a bit; the RPMs that start with capital letters are listed above RPMs that have lower case letters.

http://public-yum.oracle.com/repo/OracleLinux/OL6/latest/x86_64/

2014 10 12 11 46 06

The location of the source RPM (.src.rpm) can be especially important for Red Hat customers who want to leverage all the hard work that Oracle has put in. Red Hat customers can download the source RPM and build their own RPM package that will work on Red Hat with the rpmbuild command.


Oracle Database 12c Release 1 Patchset 1 is the terminal release for Oracle 12.1. As of Oracle OpenWorld 2014, the announcement was made that 12.1.0.2 will be the terminal release for Oracle Database 12c Release 1. Oracle also notified customers that the 12c Release 2 (12.2) will not be available until the first quarter of 2016. With that in mind, customers are encouraged to jump on the terminal release of Oracle Database 12 release 1.

In this blog post, I will focus on installing and configuring Oracle Database 12c Release 1 Patchset 1.

2014 10 04 14 44 26

Select the option that you want to install and click on Next. In my example, I am selecting to install and configure Oracle Grid Infrastructure for a standalone server.

2014 10 04 14 49 16

Select the languages that you want to install and click on the Next button

2014 10 04 14 51 29

In the Create ASM Disk Group screen, we will create a disk group called DATA. We will also:
* Click on the External Redundancy option
* Change the Allocation Unit size from 1MB to 4MB
* Select all the disks that make up the DATA Disk Group. ORCL:DATA1 to ORCL:DATA4

When we customized all the options, we will click on the Next button

2014 10 04 16 20 49

Enter the password for the SYS and ASMSNMP accounts. In our example, we will choose to enter the same password for both of the accounts. Click on the Next button to continue.

2014 10 04 16 22 09
The password that was entered did not conform to the Oracle recommended standards. We will choose to continue by clicking on the Yes button.

2014 10 04 16 23 53

We do not have an OEM 12c Cloud Control environment setup yet so we will continue by clicking on the Next button.
2014 10 04 16 27 29

Choose the OS Groups for the ASM administrator, ASM DBA, and ASM Operator. In our example, we chose to stick with one standard group since we do not have a separation of roles and responsibilities between the DBA and Cluster administrator.

2014 10 04 16 29 50
Click on Yes to continue

2014 10 04 16 33 04

If this is a fresh install, you will want to create the directories for $ORACLE_BASE on the /u01 file system and change the permissions to oracle:dba:

[root@vna01 u01]# mkdir -p /u01/app/oracle
[root@vna01 u01]# chown -R oracle:dba /u01/app

Click on Next to continue

2014 10 04 16 35 44

Set the path for the oraInventory location. The default location is good for most customers. Click on Next to continue.

2014 10 04 16 38 45

The default location for sudo is in /usr/bin directory. For this screen, you will want to change the location of sudo to be /usr/bin/sudo instead of /usr/local/bin/sudo.

If you are new to the world of sudo, you can make a simple change in the /etc/sudoers file and add the following line:

oracle	ALL=(ALL) 	ALL

This example is not encouraged. Most companies with strict sudoers control will list just the commands that the oracle user can execute on behalf of root.
Click on the next button to continue.

2014 10 04 16 42 34

We seem to have an issue with a kernel parameter called panic_on_oops. This parameter is not set in the /etc/sysctl.conf parameter file. For now, we will choose to ignore this warning and continue with the installation. Let’s continue by clicking on the Ignore All checkbox on the top right corner of the window; then click on the Next button to continue.

2014 10 04 16 45 23

We will see an warning message indicating that we’ve chosen to ignore one or more of the prerequisites. Click on the Yes button to continue.

2014 10 04 16 46 20

Finally, we arrive at the Summary screen. Before we click on the Installation button, we will choose the option to save the response file by clicking on the Save Response File button. Carefully review the options that you have chosen and click on the Install button.

2014 10 04 16 49 03

We can watch the installation progress. You can click on the Details button if you want to see some of the detailed logs of what is happening.

2014 10 04 16 54 20

Once the installation is complete, you will be prompted to auto execute the configuration script. Click on Yes to continue to execute orainstRoot.sh and root.sh as the root user or as the sudo privileged user.

2014 10 04 17 04 09

Congrats! We have successfully installed Oracle 12c Release 1 Patchset 1 Grid Infrastructure. Next, we will proceed with installing and configuring the Oracle 12c Release 1 Patchset 1 Database software.

Install Oracle Database Software

[oracle@vna01 database]$ ./runInstaller
Starting Oracle Universal Installer...

Checking Temp space: must be greater than 500 MB.   Actual 29712 MB    Passed
Checking swap space: must be greater than 150 MB.   Actual 31992 MB    Passed
Checking monitor: must be configured to display at least 256 colors.    Actual 16777216    Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2014-10-05_03-07-31AM. Please wait ...[oracle@vna01 database]$ 

2014 10 05 03 10 11

Uncheck the option for receiving security updates via Oracle Support
Click on the Next button to continue

2014 10 05 03 12 56
Click on the Yes button and confirm that you have chosen to remain uninformed of critical security updates

2014 10 05 03 14 56
Click on the Install database software only option and click on the Next button to continue. We will create a database later with the Database Configuration Assistant (dbca).

2014 10 05 03 16 27
Click on the Single instance database installation option and click on Next button to continue

2014 10 05 03 17 43
Select the languages that you want to install and click on the Next button to continue

2014 10 05 03 20 46
At the initial release of Oracle Database 12c Release 1 Patchset 1, only the Enterprise Edition was available. Standard Edition or Standard Edition One is not available as an option yet.

2014 10 05 03 24 09
Accept the default location for $ORACLE_BASE and $ORACLE_HOME since we have already installed the Grid Infrastructure and click on the Next button to continue.

2014 10 05 03 26 47
Select the OS groups for OSDBA, OSOPER, OSBACKUPDBA, OSDGDBA and OSKMDBA and click on the Next button to continue.

2014 10 05 03 31 39
We are at the Summary screen. Before we click on the Install button, we will choose the option to save the response file by clicking on the Save Response File button. Carefully review the options that you have chosen and click on the Install button.

2014 10 05 03 34 06

We can watch the installation progress. You can click on the Details button if you want to see some of the detailed logs of what is happening.

2014 10 05 03 36 50
As the root account, execute root.sh from the Database Oracle Home.

[oracle@vna01 dbhome_1]$ sudo ./root.sh
[sudo] password for oracle: 
Performing root user operation.

The following environment variables are set as:
    ORACLE_OWNER= oracle
    ORACLE_HOME=  /u01/app/oracle/product/12.1.0/dbhome_1

Enter the full pathname of the local bin directory: [/usr/local/bin]: 
The contents of "dbhome" have not changed. No need to overwrite.
The contents of "oraenv" have not changed. No need to overwrite.
The contents of "coraenv" have not changed. No need to overwrite.

Entries will be added to the /etc/oratab file as needed by
Database Configuration Assistant when a database is created
Finished running generic part of root script.
Now product-specific root actions will be performed.

After root.sh is successfully executed, go back to the Execute Configuration Script window and click on the OK button.

2014 10 05 03 43 37
Click on the Close button to complete the database software installation

Create the Fast Recovery Area (FRA)

Launch the ASM Configuration Assistant (asmca). Before we launch asmca, we need to source the oraenv file and setup the Linux environment for ASM.

[oracle@vna01 Desktop]$ . oraenv
ORACLE_SID = [oracle] ? +ASM
The Oracle base has been set to /u01/app/oracle
[oracle@vna01 Desktop]$ asmca

2014 10 05 03 53 42
Click on the Create button to create the FRA disk group.

2014 10 05 03 56 01

From the Create Disk Group screen, enter FRA for the Disk Group Name and select the option for the External redundancy. Click on the Show Advanced Options and change the Allocation Unit Size (MB) from 1MB to 4MB.

2014 10 05 04 01 08
If we know for a fact that only 12.1 databases will ever go on this ASM instance, we can advance the Database Compatibility and ADVM Compatibility to 12.1.0.0.0 also. We will click on the OK button to complete the FRA disk group creation.

2014 10 05 04 02 36
While the disk group is being created, you will see the above progress window.

2014 10 05 04 03 02
We successfully created the FRA disk group. Click on the Close button to exit the screen and click on the Exit button to cleanly exit asmca.

Create a Database with dbca (using an existing Oracle seeded database template)

We need to launch the Database Configuration Assistant (dbca). Before we launch dbca, we need to source the oraenv file and setup the Oracle environment.

[oracle@vna01 dbhome_1]$ pwd
/u01/app/oracle/product/12.1.0/dbhome_1
[oracle@vna01 dbhome_1]$ . oraenv
ORACLE_SID = [oracle] ? db
ORACLE_HOME = [/home/oracle] ? /u01/app/oracle/product/12.1.0/dbhome_1
The Oracle base has been set to /u01/app/oracle
[oracle@vna01 dbhome_1]$ 
[oracle@vna01 dbhome_1]$ dbca

2014 10 05 03 47 39

Select the Create Database option and click on the Next button to continue

2014 10 05 04 13 42
Enter the database name and select the disk group location for the database files and fast recovery area. Choose the database character set for the database and enter the administrator password. You can choose the create the database as a Container Database (default). You can enter the name for the pluggable database name. Click on the Next button to continue.

2014 10 05 04 15 12
We receive a warning message because the administrative password does not conform to the recommended Oracle standards. Click on the Yes button to continue.

2014 10 05 04 17 57
From the Summary screen, review the options that were chosen and click on the Finish button.

2014 10 05 04 19 28
We can review the database creation progress. In the meanwhile, we can also view the Activity Log or the Alert Log.

Create a Customized Database with dbca Advanced Mode

Coming soon


vncserver is a wrapper script for Xvnc, the free X server for VNC (Virtual Network Computing). It provides all capabilities of a standard X server, but does not connect to a display for itself. Instead, Xvnc creates a virtual desktop you can view or control remotely using a VNC viewer.

I was recently asked by a DBA colleague about leveraging VNC Server for installations/upgrades, and if they should incorporate it as part of their infrastructure. Even though VNC Server as a whole is not considered to be secure, DBAs prefer to leverage this technology for Oracle installation and upgrades. DBAs prefer VNC Server technology over the traditional X Windows on the local desktop/laptop, as the Oracle installation/upgrade will proceed significantly faster. DBAs also prefer VNC as network glitches does not cause the install/upgrade to fail. If the network fails during the installation/upgrades, we can simply re-connect to the VNC Server and continue where we left off. If the network fails during the file copies, all we lose is the display and can continue to see the progress. You can install the VNC Server with the yum install command. In the example shown below, we are installing the tightvnc-server RPM on Oracle Linux 6.5:

[oracle@vna01 ~]$ yum install tigervnc-server

Loaded plugins: security
You need to be root to perform this command.
[oracle@vna01 ~]$ su - 
Password: 
[root@vna01 ~]# yum install tigervnc-server
Loaded plugins: security
ol6_UEK_latest                                                                                                    | 1.2 kB     00:00     
ol6_latest                                                                                                        | 1.4 kB     00:00     
ol6_latest/primary                                                                                                |  41 MB     00:35     
ol6_latest                                                                                                                   26208/26208
ol6_u4_base                                                                                                       | 1.4 kB     00:00     
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package tigervnc-server.x86_64 0:1.1.0-8.el6_5 will be installed
--> Processing Dependency: xorg-x11-xkb-utils for package: tigervnc-server-1.1.0-8.el6_5.x86_64
--> Processing Dependency: xkeyboard-config for package: tigervnc-server-1.1.0-8.el6_5.x86_64
--> Processing Dependency: xorg-x11-fonts-misc for package: tigervnc-server-1.1.0-8.el6_5.x86_64
--> Processing Dependency: libXdmcp.so.6()(64bit) for package: tigervnc-server-1.1.0-8.el6_5.x86_64
--> Running transaction check
---> Package libXdmcp.x86_64 0:1.1.1-3.el6 will be installed
---> Package xkeyboard-config.noarch 0:2.6-6.0.1.el6 will be installed
---> Package xorg-x11-fonts-misc.noarch 0:7.2-9.1.el6 will be installed
---> Package xorg-x11-xkb-utils.x86_64 0:7.7-4.el6 will be installed
--> Processing Dependency: libxkbfile.so.1()(64bit) for package: xorg-x11-xkb-utils-7.7-4.el6.x86_64
--> Running transaction check
---> Package libxkbfile.x86_64 0:1.0.6-1.1.el6 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

=========================================================================================================================================
 Package                                Arch                      Version                            Repository                     Size
=========================================================================================================================================
Installing:
 tigervnc-server                        x86_64                    1.1.0-8.el6_5                      ol6_latest                    1.1 M
Installing for dependencies:
 libXdmcp                               x86_64                    1.1.1-3.el6                        ol6_latest                     30 k
 libxkbfile                             x86_64                    1.0.6-1.1.el6                      ol6_latest                     74 k
 xkeyboard-config                       noarch                    2.6-6.0.1.el6                      ol6_latest                    710 k
 xorg-x11-fonts-misc                    noarch                    7.2-9.1.el6                        ol6_latest                    5.8 M
 xorg-x11-xkb-utils                     x86_64                    7.7-4.el6                          ol6_latest                     86 k

Transaction Summary
=========================================================================================================================================
Install       6 Package(s)

Total download size: 7.8 M
Installed size: 15 M
Is this ok [y/N]: y
Downloading Packages:
(1/6): libXdmcp-1.1.1-3.el6.x86_64.rpm                                                                            |  30 kB     00:00     
(2/6): libxkbfile-1.0.6-1.1.el6.x86_64.rpm                                                                        |  74 kB     00:00     
(3/6): tigervnc-server-1.1.0-8.el6_5.x86_64.rpm                                                                   | 1.1 MB     00:00     
(4/6): xkeyboard-config-2.6-6.0.1.el6.noarch.rpm                                                                  | 710 kB     00:00     
(5/6): xorg-x11-fonts-misc-7.2-9.1.el6.noarch.rpm                                                                 | 5.8 MB     00:05     
(6/6): xorg-x11-xkb-utils-7.7-4.el6.x86_64.rpm                                                                    |  86 kB     00:00     
-----------------------------------------------------------------------------------------------------------------------------------------
Total                                                                                                    956 kB/s | 7.8 MB     00:08     
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
  Installing : xorg-x11-fonts-misc-7.2-9.1.el6.noarch                                                                                1/6 
  Installing : xkeyboard-config-2.6-6.0.1.el6.noarch                                                                                 2/6 
  Installing : libxkbfile-1.0.6-1.1.el6.x86_64                                                                                       3/6 
  Installing : xorg-x11-xkb-utils-7.7-4.el6.x86_64                                                                                   4/6 
  Installing : libXdmcp-1.1.1-3.el6.x86_64                                                                                           5/6 
  Installing : tigervnc-server-1.1.0-8.el6_5.x86_64                                                                                  6/6 
  Verifying  : libXdmcp-1.1.1-3.el6.x86_64                                                                                           1/6 
  Verifying  : xorg-x11-xkb-utils-7.7-4.el6.x86_64                                                                                   2/6 
  Verifying  : libxkbfile-1.0.6-1.1.el6.x86_64                                                                                       3/6 
  Verifying  : xkeyboard-config-2.6-6.0.1.el6.noarch                                                                                 4/6 
  Verifying  : xorg-x11-fonts-misc-7.2-9.1.el6.noarch                                                                                5/6 
  Verifying  : tigervnc-server-1.1.0-8.el6_5.x86_64                                                                                  6/6 

Installed:
  tigervnc-server.x86_64 0:1.1.0-8.el6_5                                                                                                 

Dependency Installed:
  libXdmcp.x86_64 0:1.1.1-3.el6                 libxkbfile.x86_64 0:1.0.6-1.1.el6          xkeyboard-config.noarch 0:2.6-6.0.1.el6     
  xorg-x11-fonts-misc.noarch 0:7.2-9.1.el6      xorg-x11-xkb-utils.x86_64 0:7.7-4.el6     

Complete!

Now that the VNC Server is installed, let’s configure the VNC Server to auto start a reboot. It is very important for me to note that we do NOT want to do this for the production database servers. We configure the VNC Server to auto-start by modifying the /etc/sysconfig/vncservers file and add the following 2 lines for oracle:

VNCSERVERS="3:oracle"
VNCSERVERARGS[3]="-geometry 1280x1024"

To enable the vncserver service to autostart, we have to execute the chkconfig command:
chkconfig vncserver on

Before we start the vncserver, we need to establish a VNC password for the oracle account. Switch user to oracle and execute the vncpasswd command:

# su - oracle
$ vncpasswd oracle
Password:
Verify:

Log back in as the root account and start the vncserver with the “service vncserver start” command.

[root@vna01 ~]# service vncserver start
Starting VNC server: 3:oracle xauth:  creating new authority file /home/oracle/.Xauthority

New 'vna01:3 (oracle)' desktop is vna01:3

Creating default startup script /home/oracle/.vnc/xstartup
Starting applications specified in /home/oracle/.vnc/xstartup
Log file is /home/oracle/.vnc/vna01:3.log

                                                           [  OK  ]

With any VNC Viewer, you should be able to access the VNC Server. Since I am on a Mac, I am using a freeware/shareware called Chicken of the VNC. Notice that I am leveraging :3 as my display port since I setup the “VNCSERVERS=”3:oracle” in my /etc/sysconfig/vncservers file.

2014 10 04 11 09 02

To demonstrate how we can maintain the vncserver as the oracle user, we are going to kill the currently running vncserver process and re-start it. To kill the vncserver, we pass the -kill parameter to the vncserver executable. We also provide the display number to kill parameter as shown in the example below:

[oracle@vna01 ~]$ ps -ef |grep vnc
oracle    5954     1  0 11:06 ?        00:00:00 /usr/bin/Xvnc :3 -desktop vna01:3 (oracle) -auth /home/oracle/.Xauthority -geometry 1280x1024 -rfbwait 30000 -rfbauth /home/oracle/.vnc/passwd -rfbport 5903 -fp catalogue:/etc/X11/fontpath.d -pn
oracle    5960     1  0 11:06 ?        00:00:00 vncconfig -iconic
oracle    5999  5972  0 11:10 pts/0    00:00:00 grep vnc
[oracle@vna01 ~]$ vncserver ^C
[oracle@vna01 ~]$ man vncserver
[oracle@vna01 ~]$ vncserver -kill :3
Killing Xvnc process ID 5954

We can also start a vncserver manually as the oracle user account. To start a vncserver process on display port 3, we pass the :3 parameter:

[oracle@vna01 ~]$ vncserver :3

New 'vna01:3 (oracle)' desktop is vna01:3

Starting applications specified in /home/oracle/.vnc/xstartup
Log file is /home/oracle/.vnc/vna01:3.log

When we executed the vncpasswd command, a subdirectory was created under the $HOME directory called .vnc. In this subdirectory, there are several files. The passwd file is the encrypted password for the VNC Server.

[oracle@vna01 .vnc]$ ls -ltr
total 16
-rw------- 1 oracle oinstall    8 Oct  4 11:06 passwd
-rwxr-xr-x 1 oracle oinstall  654 Oct  4 11:06 xstartup
-rw-r--r-- 1 oracle oinstall    5 Oct  4 11:13 vna01:3.pid
-rw-r--r-- 1 oracle oinstall 1531 Oct  4 11:13 vna01:3.log

The xstartup file contains all the parameters for the vncserver process.

When to leverage VNC Server

We strongly discourage installing VNC Server on any production servers. Nonetheless, for Oracle installations and upgrades, we often need access to a X Server to set our GUI display to. We can leverage a remote VNC Server on a needed basis. As a temporary solution, we can start a vncserverprocess on another server when we need it and kill the processes when we are done with the install/upgrade. To set the display from the production database server to the remote VNC server, we simply set the DISPLAY parameter to the hostname:DISPLAY port. In our example, the name of our VNC Server was on vna01 and we are listening on DISPLAY port 3 so we will setup our DISPLAY parameter to be:


export DISPLAY=vna01.viscosityna.com:3


This blog article focuses on configuring VirtualBox to create a new VM for Oracle Linux 7 and installing Oracle Linux 7 from the ISO image as a guest operating system. The Oracle Linux 7 ISO image can be downloaded from edelivery.oracle.com – Oracle Software Delivery Cloud. You must have a valid Oracle Account (free) to download the Linux ISO.

Look in the near future for a VMware Fusion and RedHat 7 version of this post. For some reason when this post went out, the latest version of VMware Fusion did not recognize the virtual disk or the network interface assigned to the VM with RedHat 7 (Oracle Linux 7 worked fine). Stay tuned as that problem will probably be resolved soon.

As far as this blog post is concerned, the follow-up for this post will be on setting up docker for Oracle Linux 6 and Oracle Linux 7.

Configuring VirtualBox


To create a VM, click on the New button on the top left corner and provide a descriptive name for the VM, location of the VM and select the type of OS. The name that is specified will be used to identify the VM configuration:

2014 09 01 01 51 04

On a side note, here’s the list of flavors of Linux supported by VirtualBox. We will choose Oracle (64Bit) for this VM.
2014 09 01 10 31 57

Once the required information is provided, click on the Continue button

2014 09 01 01 51 18

Next configure the amount of memory allocated for this VM. We will allocate 4GB for this VM and click on the Continue button.

2014 09 01 01 51 35
We can modify the virtual disk in another screen later in the configuration process. Take the default and click on the Continue button go to the “Hard drive file type” screen.

2014 09 01 01 51 50
Unless you are planning for this virtual disk to be compatible with VMware or other virtualization technology, select the VDI (VirtualBox disk format) and click on the Continue button.

2014 09 01 01 52 01
Leave the Dynamically allocated option to choose a thinly provisioned virtual disk. If you want better performance for RAC ASM disks, you can choose the option for Fixed size. For the Fixed size disk, VirtualBox will pre-allocate all the space up front. Click on the Continue button to proceed with the configuration.

2014 09 01 01 52 14
For this installation, we will allocate 64GB for the root and /u01 file systems. You may opt to create multiple virtual disks, one for the root file system and another one for the /u01 file system. Click on Create. If you chose earlier for Fixed size, when you click on the Create button, you will be waiting here for a while.

2014 09 01 01 52 27
Once the VDI disk is created with the specified size (thin for dynamically allocated or thick for fixed size provisioned), you will be re-directed back to the main screen.

2014 09 01 01 53 38
Now, let’s configure our VM, in particular, the CD/DVD Drive. Click on the Settings button on the top left corner next to the New button.

2014 09 01 01 53 53
Click on the Storage button on the top (in the middle). On the left side of the screen, choose the IDE controller and Click on the Empty CD icon. Then on the right of the screen, click on the CD image icon for the CD/DVD drive and click on the “Choose a virtual CD/DVD disk file …”. Find your ISO image for Oracle Linux 7 from the file previewer and select the ISO. From the Storage screen, click on the OK button to go back to the main Oracle VM VirtualBox Manager screen.

Installing Oracle Linux 7


From the Oralce VM VirtualBox Manager screen, select your VM that you just created and click on the green Start icon on the top of the screen.
2014 09 01 01 54 51
Hit the arrow key up once and choose the option to Install Oracle Linux 7 and hit the Enter key

2014 09 01 01 55 29
Keep the default English language for United States and click on Continue

2014 09 01 01 56 01
As you can see, the installation process looks significantly different from Oracle Linux 6. Click on the INSTALLATION DESTINATION button.

2014 09 01 12 23 03
Select the “I will configure partitioning.” radio button and click on the Done button on the top left hand corner.

2014 09 01 12 23 54
In the MANUAL PARTITIONING screen, click on the “Click here to create them automatically” URL.

2014 09 01 12 19 22
In our example, we will remove the /home file system and just let the root file system house all the file systems, /home and /u01. To remove the /home file system, click on the /home file system and click on the – sign on the bottom corner of the screen.

CAVEAT: You do NOT want to do this outside your lab. Even in your DEV or non-PROD environment, you will want to carve out a separate file system for the /home file system. You ALWAYS want to carve out a separate /u01 file system for all your Oracle binaries. Click on the Done button on the top left corner.

* Notice that the default file system is XFS (not EXT4 in Oracle or RedHat Linux 6)

2014 09 01 02 07 41
You will be presented with a warning screen just to confirm and Accept the Changes that we made to remove the /home file system. Click on the Accept Changes button.

2014 09 01 02 08 02
You will be routed back to the main Installation Summary screen. By default, the minimal installation option is the installation method of choice for Oracle and Red Hat Linux. If you want a GUI installation, you will want to select the SOFTWARE SELECTION button and choose the KDE desktop. For security purposes, we only recommend the minimal installation option.

To configure the network and hostname, you should click on the NETWORK & HOSTNAME button. The first thing that you need to do is the specify a new Hostname on the bottom left corner.

2014 09 01 12 30 16
Turn on the Network interface by sliding the switch to the on position.

In our case, we will want to assign a static IP address and DNS Servers. Click on the Configure button on the bottom right corner.

2014 09 01 12 32 54
Add all the specifics for your IP address, gateway, subnet and DNS servers. Click on the Save button to save the network settings. You will be re-directed to the NETWORK & HOSTNAME screen. Click on the Done button to go back to the INSTALLATION SUMMARY screen.

Optionally, you may want to choose to install a GUI desktop. This is never recommended for a production environment. For ease of maintenance, you can click on the SOFTWARE SELECTION button and choose to install a “Server with GUI” option and choose the KDE desktop. Click on the Done button after you select all the options that you want installed.

2014 09 01 12 41 08
Once all the configuration is complete, you can click on the Begin Installation button.

2014 09 01 02 08 47
As the installation is progressing, you will see 2 red warnings indicating that the root password is not set and no users are created. At a minimum, click on the Root Password icon to supply a password for the root account to administer the system. Provide the secure password and click on the Done button on the top left corner.

Note: If the root password is insecure, you will be prompted to click on the Done button again to proceed with the insecure password.

2014 09 01 02 10 59

From the Configuration screen, click on the Reboot button.

2014 09 01 02 11 35
Once the VM reboots, you will be directed to the login prompt. Since we did a bare minimal installation, we will not enter into a GUI mode.

2014 09 01 02 11 59

Once we login, we can check /etc/oracle-release file and confirm that we are running an Oracle Linux Server 7 distribution of Linux.

Chose KDE GUI DESKTOP


If you chose the GUI Desktop option earlier, when the system reboots, you will be directed to perform the initial setup.

2014 09 01 13 12 22
Click on the LICENSE INFORMATION icon

2014 09 01 13 12 38
Click on the checkbox to accept the license agreement and click on the Done button on the top left corner. You will be re-directed to the INITIAL SETUP screen. Click on the FINISH CONFIGURATION button to proceed.

2014 09 01 13 17 11
For a production environment, you will always want to enable KDUMP for system crash debugging. Click on the Forward button on the bottom right to continue.

2014 09 01 13 18 51
You can configure your system for software updates by providing credentials to Oracle’s Unbreakable Linux Network. We do not want to setup our system for software updates at this time. Click on the Forward button on the bottom right to continue.

2014 09 01 13 20 55
Click on the button “No thanks, I’ll connect later.”

2014 09 01 13 21 54
Click on the Forward button again

2014 09 01 13 23 03
Select English (United States) and Click on Next

2014 09 01 13 23 58
Click on English (US) and Click on Next

2014 09 01 13 25 25
You will need to create a local account and click on Next

2014 09 01 13 26 50
Choose your location from the big list of cities and click on Next

2014 09 01 13 27 35
For Oracle installations, we do not care for online accounts. You can skip this step and click on the Next button to proceed.

2014 09 01 13 33 40
Click on the “Start using Oracle Linux Server” button and enjoy the GUI desktop.

Posted by Charles Kim, Oracle ACE Director