Dizwell Informatics

News from Nowhere

Atlas – Installing Oracle on Elementary OS

1.0 Introduction

I am not entirely sure what to make of Elementary OS. With a name like that, it kind of makes you think you need to be a bit of a simpleton to use it, no? Indeed, when you finally get this mere Ubuntu-derived spin booted, you are thrown into a simplistic interface that doesn’t even manage graphical aplomb (it’s default desktop wallpaper is ghastly… and it has a DOCK! Take me back to the nineties…)

Apparently, one of this distro’s main goals is to minimise the use of the terminal (a bit like minimising the use of breathing, it seems to me: a possibly worthy goal, but fundamentally missing the point!). Atlas and Oracle on Elementary would therefore seem to be a bit of a contradiction in terms and I -rather defensively, I realise- plead that I only decided to make Atlas work with Elementary because it happens to be in (extraordinarily!) 6th place on the DistroWatch popularity rankings at the time of writing. Quite how that happens, I have no idea: in my view, it’s an awful distro with nothing to commend it. But a thousand visitors a week to the Distrowatch website can’t be wrong, I assume…

I’m not going to pretend I like Elementary OS. I don’t. It’s simplistic, patronising and ugly in equal measure. But it’s based on Ubuntu, so Atlas (and Oracle) work on it as they do on base-Ubuntu. Good luck with it if it happens to be your O/S of choice.

As is the case with all Atlas/Oracle installs, of course, your Elementary server needs to be built with at least 5GB RAM and at least a 40GB hard disk.

Please watch the generic Atlas videos here, here and here to get an idea of how Atlas works in general. The generic documentation (including those videos) are available from this page. Below are Elementary-specific notes.

2.0 What’s been tested?

  • Elementary OS 0.4

3.0 Operating System media

Get your Elementary downloads from here. The site asks you for money: it is legitimate (though perhaps not entirely moral -or sensible) to type in “0” for the number of dollars you are willing to pay. The site will switch to letting you download the relevant ‘elementary-stable.iso’ regardless.

4.0 Operating System installation issues

There are no surprises with the OS installation. You can accept all the defaults and just click your way through to completion.

For disk partitioning:

The default option here is simply to ‘erase the disk’. That can safely be accepted: you will get a simple ‘everything in one root volume’ partitioning scheme which Atlas will find entirely acceptable. If you decide to go the ‘something else’ path and cook up your own partitioning scheme, remember that Atlas wants a ‘big root’ to work with (at least 25GB of free space on the ‘/’ mount point, basically).

Other than that, the installation proceeds to completion without drama or need to alter any of the defaults.

No wmctrl or xdotool utilities are installed by default, so once your OS has come back from its post-install reboot, you need to add that to Peppermint before you try running Atlas:

sudo apt install wmctrl

…will do the job:

I will, however, at this point mention that I had to sit tight for about 40 minutes before this command would work as the operating system seemed to busy updating itself in the background, thereby locking the apt-get application from any other attempt to update or install anything. Another thing I disliked about this distro! Be patient in your efforts to install the wmctrl or xdotool packages, therefore!!

I found I was able to scale the display on my Peppermint VirtualBox VMs without needing to install any Guest Additions.

5.0 Running Atlas

Assuming you’ve installed wmctrl (or xdotool) and have a big enough screen resolution, therefore, acquiring and running Atlas is straightfoward:

wget http://bit.do/dizatlas -O atlas.sh
chmod +x atlas.sh

When you first launch Atlas like this, you may well find the end result a bit unreadable:

Most of what you’re supposed to see is legible, I suppose -but it’s not meant to be that compact! If you see something like this, I suggest you press Ctrl+C to quit Atlas, manually maximise the terminal window and then relaunch Atlas. You ought to be seeing something more like this:

Once you can read the thing properly, just follow the prompts. There are no surprises.

6.0 Installing Oracle 12c

Oracle installation on Elementary OS starts by warning you that your system is not adequate for the task:

The warning is a red herring, however, and it is perfectly OK to click [Yes] at this point to continue the installation regardless. You mostly just keep clicking [Next] after that!

Sadly, however, it remains the case that Elementary OS, reflecting its Ubuntu heritage, is one of the few distros these days to throw errors during the installer’s ‘linking phase’:

As you can see, you get a pop-up at around the 59% mark, claiming that there’s a problem with compiling the ins_rdbms.mk makefile. As you can also see, however: your response to this error should be to open a new terminal window and change directory to the oracle user’s Documents directory. There, you’ll find an ‘atlas-fixup.sh’ shell script, previously created by Atlas:

Note that the file is already executable: Atlas created it that way. You can therefore run that script now, as yourself, using the following command:


The script takes practically no time at all to run, but indicates it has completed by putting a big pop-up dialog box in the middle of your screen:

So now you do what the pop-up tells you to do: click [OK] to dismiss this new pop-up itself, switch back to the error message dialog generated by the original Oracle installer …and there click the [Retry] button.

Do all of that, and you’ll see that the linking phase resumes… and completes without further incident:

After that, the Oracle installation follows its usual path: you are asked to run two scripts as root, as you can see, so you can just prefix the script path/names the Oracle dialog gives you with “sudo” to achieve that.

Note that if you elected to create a new, dedicated oracle user when first running Atlas (instead of using the default option of making yourself the oracle user), using sudo in this way will not be possible, because Atlas doesn’t make new users members of the sudo-capable group by default.

If that happens to you, the trick is to use “su – <username>” to become the original non-root user (the user account specified when you first installed the operating system), and only then to prefix the path/filenames with the sudo command. That is, make the oracle user become someone who can sudo things, and run the root scripts as that other user with sudo prefixes.

You could alternatively just make the oracle user a sudo-capable user (by issuing the sudo adduser <username> sudo command), but that would not be a particularly secure way to do things: I don’t like my oracle users having more powers than they need strictly to run a database!

Once the database has been created for you, you should be able to immediately log on to the database and see visually-pleasing results:

The key point here is that, since there were linking errors that required you to run a fixup script, there is no Atlas-created post-install script to be run, as there would be with many other distros. Therefore, SQL*Plus is already configured to display line lengths and page sizes sensibly.

Incidentally: the command you see me typing in that last screenshot (“sql“) is the alias of the full command (“sqlplus / as sysdba“). It is aliased with a reference to the rlwrap utility, so that if you get into SQL*Plus using it, you can press the up and down cursor keys to retrieve and scroll through any previous SQL commands you’ve typed. If you ever need the vanilla, un-rlwrapped version of SQL*Plus, however, then just type the full-blown sqlplus  command and you’ll be running the exact same program as before but without a command line history.