Oracle Cloud – Creating an Instance

In this post I’m going to walk through creating a new DBaaS instance with your Oracle Cloud account. As a reminder you can sign up for a free Trial account (without any credit card details having to be entered – so I encourage you to head over to and sign up for a free trial).

As you can see, I already have one instance created and running in my account:


Since this is a trial account, I’ve been testing out the Enterprise Edition – High Performance option.

However let’s go ahead and create a new Instance, by hitting the ‘Create Service’ button (logically enough!).


DBaaS Create Service – Step 1

I need to decide if I want an instance based on the Oracle Database Cloud Service, i.e. one where the database is pre-installed and I also get some cloud tooling (command-line tools etc) to help manage the instance, or do I want a Virtual Image where I have responsibility for installing everything.

Also I get to choose the billing frequency – since this is a Trial account I’ll go ahead and choose Oracle Database Cloud Service and Monthly Billing (although hopefully I won’t be billed anything!).



DBaaS Create Service – Step 2

This step is pretty self-explanatory, do you want to use 11gR2 or 12cR1?

In the next step, we choose the Edition


DBaaS Create Service – Step 3

since this is a Trial account, let’s go all-in and choose Enterprise Edition – Extreme Performance (which gives us the In-Memory option).

Depending which option you select, the options on the next screen will vary slightly, however you should see something similar to:



DBaaS Create Service – Step 4

Lots of options here, most of them self-explanatory, but let’s go through some of the key ones.


shape.pnghere you are essentially selecting the number of OCPU’s and the memory you want.

the key thing to bear in mind is that it’s relatively easy to scale up later on, but not so easy to scale down (at least using the built in tooling). So choose wisely!


SSH Public Key

ssh-public-key.pngIn order to connect to your instance later on you’ll need to generate a public key (or use an existing one).

This key will then be used to authenticate to your instance via SSH without requiring you to enter a password .


So how do you generate an ssh key? Well on my Mac, I went to a terminal and typed the following commands:

[jes@mac oracle-cloud]$ ssh-keygen -t rsa
Generating public/private rsa key pair
Enter file in which to save the key (/Users/jes/.ssh/id_rsa): ./oracle_cloud_rsa
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in ./oracle_cloud_rsa.
Your public key has been saved in ./
The key fingerprint is:
SHA256:l0ISI/J6AFTt/n5n2mbhAPguUYGOK9mm0+afBxAHIa4 jes@mac
The key's randomart image is:
+---[RSA 2048]----+
|o.+.*oo |
| o =.+.o |
| =o+oo . |
| o+=++ o . |
|E+o+=.. S o |
|o..o.o.. + |
|. o..oo . |
| . .o.o* . |
| . .+=.o |
[jes@AEMBP oracle-cloud]$ ls -al
total 16
drwxr-xr-x 4 jes staff 136 12 May 00:25 .
drwxr-xr-x 102 jes staff 3468 12 May 00:24 ..
-rw------- 1 jes staff 1679 12 May 00:25 oracle_cloud_rsa
-rw-r--r-- 1 jes staff 397 12 May 00:25

(FYI don’t try and use the above information – it was just a test and not used for a real key!)

The important bit here is making sure you enter a different path to generate the file (otherwise you risk overwriting any default keys you have). Once I’ve generated my private key (the one without the .pub suffix) and my public key (the one with the .pub suffix) I can upload the public key to be used by my Oracle instance.

Database Configuration


There are some obvious and not so-obvious things in this section.

For example, admin password, DB SID, PDB name are all quite obvious.

But what about Usable Database Storage and Total Data File Storage?



One thing I don’t like in this section is that it’s possible to enter values in the Storage fields that will be accepted, but will (later on) make you exceed your allowed quota.

More than a few times, I entered what I thought were sensible values to be alerted a day or so later that I’d exceeded my storage quota and my instance had been suspended (in reality it didn’t seem to be suspended at all and I could still access it). But still – I feel there should be better validation on these items. After all, why would I NOT want to allocate the maximum amount of space (but not exceed it). It’s not immediately obvious what the optimal value is to enter in these fields.

Backup and Recovery

backup_1.pngThis looks like a fairly innocuous section, but this is where I became most confused.




For my backup strategy I’m allowed to select:

  • None
  • Cloud Storage Only
  • Both Cloud Storage and Local Storage

note that previously there was an option for Local Storage only, but that seems to have been removed (or maybe it’s dependent on the Edition you select)

Ok, I want to backup – so I need to enter my Cloud Storage Container details, but what are those and where can I get them from?

At this point I swopped a lot of emails with the extremely helpful Brian Spendolini who helped me to understand that I needed to have created my Cloud Storage manually first using REST Requests (I used CuRL commands). This is definitely an area that is screaming out for a UI to be added to the Cloud Console to allow me to do it from there. I don’t like that I’ve filled out a load of information in the Create Service wizard already and now I need to bail out of the UI and run some command line commands to create the necessary Cloud Storage account and containers before I can continue. Anyway, I’ll stay tuned and hopefully this is an area they’ll improve on soon.

For the purposes of this example, I’ll chose No Backups (PLEASE don’t do this yourself unless you really want to!). Which allows me to progress and create my instance.

Clicking the final ‘Create’ button in the wizard should return you to the Dashboard page where you’ll see your new instance listed amongst any existing ones you have.


Note in my case I already had another instance running so the figures for OCPU’s, memory and storage is the aggregate of both my instances.

The instance will sit in the ‘In Progress’ status for some time – my experience varied anywhere from 30 minutes to a few hours (although this seemed to be early on in the trial and it seems faster now).

Clicking on the name of the Instance will take you to the details page where you get a bit more information, including ‘In-Progress Provisioning Messages’ telling you at what stage in the provisioning process it is (e.g. starting the machine, installing the DB etc). Once the machine is up and running you should be able to ssh into it while the rest of the installation is progressing.



and that’s it! You now have a DBaaS instance created and (almost) up-and-running. In the next post I’ll show how to connect to the instance and poke around what has been installed by default.


One thought on “Oracle Cloud – Creating an Instance

  1. Ganesh Arelly


    Have you tried to use the database backups stored in cloud storage backup?
    I want to instantiate a new database instance from an existing backup of another database instance which is in cloud storage. Have you tried this?



Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s