Oracle Database File Placement Best Practice & Create Database Demo

This blog post is part of the “RMAN Back to Basics” series, which can be found here.

Introduction

In order for an Oracle Database to be resilient to physical storage failures, i.e. disk failure, it is imperative that the database files are placed according to Best Practice, so to avoid lost of database in case of a storage failure.  For example, not have your database and backups on the same disk, because if (more...)

Find files with errors

My students wanted a quick solution on how to find the log files that contain errors. That’s a simple line of code in Linux if you want any Oracle errors that start with ORA-:

find . -type f | xargs grep -i ora\-

It takes only a moment more to look for errors starting with ORA- or PLS-, like:

find . -type f | xargs grep -i -e ora\- -e pls\-

The latter might return (more...)

Remove Files with Force and Other Bad Ideas

Almost every Linux or Unix person has seen the help forum post from a novice looking for an answer to a frustrating problem and the arrogant fool that responds with “Just type in rm -rf / and it will fix the problem.” For anyone who is part of the “do no harm” technical community, this can make us wish for a way to revoke the arrogant fool’s privileges to the internet— permanently.

Recycling Commands

(more...)

Using the Secure External Password store with sqlcl

Sometimes it is necessary to invoke a SQL script in bash or otherwise in an unattended way. SQLcl has become my tool of choice because it’s really lightweight and can do a lot. If you haven’t worked with it yet, you really should give it a go.

So how does one go about invoking SQL scripts from the command line these days? There’s an age-old problem with unattended execution: how do you authenticate against the (more...)

PASS Summit 2019 Learning Pathways

Hello from Atlanta, where I’m preparing for tomorrow’s SQL Saturday and arrived for the great news announcing this year’s PASS Summit 2019 Learning Pathways.

These sessions are two or more sessions to provide a more complete learning opportunity for the attendee.  I’ll be part of two of these pathways:

Technical Leadership: Becoming a Technical Leader with Denise McInerney

Linux for SQL Server Professionals: Empowering the SQL Professional with Linux Scripting

I’m looking (more...)

Linux Scripting, Part II

In Part I, we started with some scripting basics, as in, how to write a script. This included the concepts of breaking a script into sections, (introduction, body and conclusion)

For Part II, we’ll start with the BASH script “introduction”.

The introduction in a BASH script should begin the same in all scripts.

  1. Set the shell to be used for the script
  2. Set the response to failure on any steps, (exit or ignore)
  3. Add in (more...)

Oracle Instant Client RPM installation where to find things

Last week I blogged about the option to install Oracle’s Instant Client via the public YUM repository. If you go ahead and try this, there is one thing you will undoubtedly notice: file locations are rather unusual if you have worked with Oracle for a while. This is true at least for the 19c Instant Client, it might be similar for older releases although I didn’t check. I’d like to thank @oraclebase for prompting me (more...)

Wireguard: Status information / using the wg command


After the installation of wireguard on two servers i shut down the secondary server and after 4h i did the wg command:
root@zerberus:~# wg
interface: wg0
  public key: XXX=
  private key: (hidden)
  listening port: 46932

peer: YYY=
  endpoint: 192.168.178.54:35891
  allowed ips: 10.0.0.2/32
  latest handshake: 4 hours, 19 minutes, 2 seconds ago
  transfer: 348 B received, 436 B sent
With the "ip addr" (more...)

Installing the Oracle Instant Client RPM via YUM on Oracle Linux 7

Many applications require Oracle’s instant client to enable connectivity with the database. In the past, getting hold of the instant client required you to agree to the license agreement before you could download the software. For a little while now, Oracle offers a YUM repository with the instant client RPMs. There are a couple of announcements to that effect, for example on Oracle’s Linux blog. It’s a great step ahead for usability, and I really (more...)

Learning about Kubernetes: JDBC database connectivity to an Oracle database

In the past few months I have spent some time trying to better understand Kubernetes and how application developers can make use of it in the context of the Oracle database. In this post I’m sharing what I learned along that way. Please be careful: this is very much a moving target, and I wouldn’t call myself an expert in the field. If you find anything in this post that could be done differently/better, please (more...)

Chrome on Fedora 27

Installing Chrome wasn’t as easy just running the yum utility. You need to download it from the following website.

https://www.google.com/chrome/browser/desktop/index.html

When you try to use the rpm utility to run it, you’ll get the following errors:

warning: google-chrome-stable_current_x86_64.rpm: Header V4 DSA/SHA1 Signature, key ID 7fac5991: NOKEY
error: Failed dependencies:
        /usr/bin/lsb_release is needed by google-chrome-stable-74.0.3729.131-1.x86_64
        libappindicator3.so.1()(64bit) is needed by google-chrome-stable-74.0.3729.131-1.x86_64
        liberation-fonts is  (more...)

Wireguard: Installation & configuration

To install wireguard i followed this instruction.
First step is to add the repository to your machine:

root@zerberus:~# add-apt-repository ppa:wireguard/wireguard
 WireGuard is a novel VPN that runs inside the Linux Kernel. This is the Ubuntu packaging for WireGuard. More info may be found at its website, listed below.

More info: https://www.wireguard.com/
Packages: wireguard wireguard-tools wireguard-dkms

Install with: $ apt install wireguard

For help, please contact

Oracle 18c and 19c on Oracle Linux 8 (beta)

Fresh on the back of yesterday’s Fedora 30 post, I noticed a post from Avi Miller about the release of Oracle Linux 8 Beta. I had a day off work, so once I had finished the Fedora 30 builds, I started on the Oracle Linux 8 builds.

It should be obvious, but this is a beta release of the OS, so everything below is just me playing. It will all have to be done (more...)

Wireguard: An easy way to build VPNs

Last week i came across the following tool:

If you want to build up a VPN you can choose one of the following strategies:
  • based on IPSec
  • using TLS
(These two are the options to choose - of course there are some others...)

The nice thing with wireguard (from the linux point of view) is, that the wireguard interfaces are handled like all other  network interfaces on your device.

If you (more...)

Not Just the How of AD with Linux VM/SQL 2019, but the WHY

Azure Directory is available with Linux SQL Server 2019 in Preview and as I was setting it up in my Azure environment on a Linux Red Hat 7.3 VM, I was, as many are, happy that they list the commands for the Azure CLI to set up authentication with Azure Directory, but was concerned, that with so many new to Linux, that they didn’t describe in the steps WHY we were running certain commands (more...)

The Late Spring Speaking Gauntlet

There are busy times for everyone and if you speak at conferences, the busy times are March,May and November. I am recovering from the early spring rush, and now it’s time to prepare for the late spring one.

I’ve been fortunate enough to be accepted to speak at the following regional SQL Saturdays and look forward to speaking and meeting new folks, along with catching up with conference friends:

SQL Saturday Raleigh, April 27th

Ansible tips’n’tricks: provision multiple machines in parallel with Vagrant and Ansible

Vagrant is a great tool that I’m regularly using for building playground environments on my laptop. I recently came across a slight inconvenience with Vagrant’s Virtualbox provider: occasionally I would like to spin up a Data Guard environment and provision both VMs in parallel to save time. Sadly you can’t bring up multiple machines in parallel using the VirtualBox provisioner according to the documentation . This was true as of April 11 2019 and might change (more...)

Ansible tips’n’tricks: testing and debugging Ansible scripts using Vagrant

At last year’s UKOUG I presented about Vagrant and how to use this great piece of software to test and debug Ansible scripts easily. Back then in December I promised a write-up, but for various reasons only now got around to finishing it.

Vagrant’s Ansible Provisioner

Vagrant offers two different Ansible provisioners: “ansible” and “ansible_local”. The “ansible” provisioner depends on a local Ansible installation, on the host. If this isn’t feasible, you can use “ansible_local” (more...)

Microsoft Azure: How to use waagent (Microsoft Azure Linux Agent)

After installation waagent on my ubunu server, i tried to use this tool.
First guess was to read the manpages, but there is no entry for waagent:
root@ubuntuserver:~# man waagent
No manual entry for waagent
See 'man 7 undocumented' for help when manual pages are not available.
So for documentation you have to visit the Microsoft Azure portal:
https://docs.microsoft.com/en-us/azure/virtual-machines/extensions/agent-linux



Here are some commands i tried:
root@ubuntuserver:~# waagent -show-configuration
AutoUpdate.Enabled = True
AutoUpdate. (more...)

dbca now makes it easy to configure OMF on file systems

Up until – and including – Oracle 12.1 I always found it not-quite-so-straight-forward to create a new database using Database Creation Assistant (dbca) and configure it with Oracle Managed Files (OMF) on a file system in silent mode. I really like to use OMF in my lab databases as it saves me a lot of typing. I have also seen Oracle databases deployed in the cloud on file systems without ASM. So I was quite happy (more...)