Wednesday 30 November 2016

Run Docker on Oracle Cloud Compute Service and OL 7.2

DEPRECATED - with the availability of the Unbreakable Enterprise Kernel Release 4 (4.1.12) image, the update steps are no longer necessary. Just yum install docker.

---8<-------------------------------------------------------------------------------------------------------

Installing Docker on Oracle Linux 7.x is easy, just to follow the official documentation. According to the documentation "Docker requires the use of the Unbreakable Enterprise Kernel Release 4 (4.1.12)". To get that running on the Oracle Public Cloud Compute Service, a few steps are neccesary.


Start with creating a new instance


Go with the latest OL 7.2. Notice, that some of the 6.x images are already running Unbreakable Enterprise Kernel (UEK) R4, but OL 7.2 is still running UEK R3, which is Linux Kernel 3.x.


Upload your SSH private key and create the image, then open the SSH port and and ssh to your machine. uname -r shows, that it is still on Kernel 3.8.13-something. Yum offers only a slight update for the kernel.


Anyways do a full yum update for the installation and afterwards reboot your instance.


The kernel is still UEK R3, but yum check-update now offers a UEKR4 kernel version 4.1.12, which is exact the minimum requirement for Docker 1.12. Pew! Do the yum update and reboot thing again.


After reboot just double check that the kernel is now 4.1.12. Now we are ready to go.


The rest is straight forward. The fastest way is not to follow Docker's guide for Oracle Linux, but use their guide for Red Hat Linux instead and use the script.

curl -fsSL https://get.docker.com/ | sh

That does the trick. And it nicely reminds you of adding your user to the docker group, so better do so.


Then just follow Docker's documentation and run

sudo systemctl enable docker.service

sudo systemctl start docker

sudo docker run hello-world

The last step should give you "Hello from Docker!", that's it.

Tuesday 15 November 2016

Fix: Oracle Linux 7 (or Red Hat) hangs on boot after installing new VirtualBox Guest Additions


After updating the Guest Addtions of a Oracle Linux 7 (or Red Hat) VM in Virtual Box, sometimes Linux hangs at the boot screen after reboot. I already posted a fix for this problem under OL 6.4 on my German Blog. It was just to Ctrl-Alt-F2 to get to another virtual display and run

/etc/init.d/vboxadd-x11 setup

Unfortunately that does not work anymore under OL 7.x, as there is no /etc/init.d/vboxadd-x11. The solution is just to run it from its new location, eg.

/opt/VBoxGuestAdditions-5.1.8/lib/VBoxGuestAdditions/vboxadd-x11 setup

and reboot.

Friday 4 November 2016

Using PaaS Service Manager (PSM) for Oracle Cloud under Windows

With the PaaS Service Manager (PSM), Oracle delivers a command line interface (CLI) for the Oracle Cloud PaaS services. It requires cURL and Phython, which needs to be set up in advance. On Linux systems, this can easily done by using the package manager of your distribution. Under Windows, a few manual steps are required. Unfortunately the official documentation is missing a point. This tutorial will show how it works.
For the installation of cURL and Python for Windows, start with the URL's from the Oracle Documentation 'Performing Prerequisite Tasks for the Command Line Interface' to download and install both tools. The Python installer gives you the option to add Python to the PATH variable, for cURL this has to be done manually in the Windows System Settings.


A quick test with python --version and curl --version should be successful as shown above


Now we need the PSM binaries. Log into your Oracle Cloud services and open the service console of any PaaS service.


Click on your username, then help|Download Center.


Download the PSM from here, which should give you a psmcli.zip. Now here is the point, that is missing in the official documentation. To install psmcli.zip you need pip.exe or pip3.exe, but that is not part of the standard installation. Here is how to get it:


Go to https://pip.pypa.io/en/stable/installing/ and click on get-pip.py. Choose Open with Python.


Wait until the installer windos closes, now you have pip.


It is located in python/Scripts, so unfortunately no in your path. For easy access, you could change your PATH again, or create a shortcut ...


... and move that into your python directory (which should be in the PATH).


Starting pip from anywhere should now return some instructions


Now you can continue with the official documentation, so install psm by running


pip install -U psmcli.zip

from the directory, where you downloaded psm.


Then enter your credentials.


And try psm help, to see if it works.


If psm works, try to query your cloud services, eg.


psm jcs services

As shown above, if anything is set up correctly, the information should be returned, Thats is, psm is ready to use.

Thursday 28 July 2016

Create a DB connection for SOA Suite with Fusion Middleware Control 12c

For using a database from a SOA composite, a database connection is required. The configuration has remained the same through the 11g lifetime, but the configuration tools have changed with Fusion Middleware Control 12c in SOA Suite 12.2. This tutorial guides through the creation of a database connection in 12.2.


This is, for example, how your Database Adapter configuration might look like. In the top half is the connection information for the JDeveloper IDE. But after deployment, the Composite will not connect directly via the JDBC connect string, but via the database connection identified by the JNDI name below (here: eis/DB/soadb). That connection needs to be created on the server, or the composite will not deploy.


To create it, we need a JDBC Data Source first. To create it, in FMW Control browse to JDBC Data Sources


Choose Create|Generic Data Source


On the first page of the Wizard, click Select... and chose the Thin XA driver for Service connections.


Give it a name (SOAe2e Data Source) and a JNDI Name (jdbc/soae2eds), then click Next.


Click on 'Generate URL and Properties' and enter your database connection information


Click Test Database Connection. If that fails, check your parameters


In the list of JDBC Data Sources, click on the newly created DS.


On the targets tab, check your SOA server and save.


Now that we have a JDBC connection, we need a DB connection. Click on WebLogic Domain|Deployments


Check Show All and click on the DbAdapter.


In Modules and Components, click on DbAdapter.rar.


Here you will learn, that the DB-Adapter configuration hasn't been ported to FMW Control yet. So click on the link to get directed to good old WLS Console.


Navigate to Deployments|Configuration|Outbound Connection Pools and click on New.


Choose java.resource.cci.ConnectionFactory and click Next.


 Accept the Deployment Plan and click OK.


Give it a name. This must exactly be the same as in JDeveloper, or it will not be found at deployment time.


Back in the list, click on the new Connection Pool to configure it.


For the XADataSourceName enter the JNDI name of the JDBC connection created above. Press RETURN before clicking on Save.


 You should get the confirmation shown above.


Back in FMW Control, the new DB adapter should be visible in the JNDI Browser. If it is not, try restarting the DB Adapter or the domain.


Having the DB connection set up properly, the deployment should work.


Thursday 21 July 2016

Create an instance in the Oracle Database Cloud Service (DBCS)

For the installation of the SOA Cloud Service (SOACS), a database is needed for the repository. This tutorial shows the required steps to create a database instance with the DBCS.


Starting in the My Services Dashboard, choose 'Oracle Database Cloud Service'.


Continue via Open Service Console


 A new service can be created via (surprise) Create Service.


The normal Oracle Database Cloud Service is required for the SOACS.


Choose release 12.1


For this tutorial, the Enterprise Edition will be sufficient. For production systems, the High- or Extreme-Performance editions should be taken into consideration.


Now give the service the necessary settings such as sizes and passwords. It is important to set up a Backup Destination, as that is a requirement for a SOACS repository. Use the Cloud Storage Container which has been created in the last chapter of this tutorial (format: Storage-IdentitiyDomain/Name).


A last summary, click on Create.


After a few Minutes, the new database is available. The creation is noted in the history below.
This newly created database can now be used as a repository for the SOACS.