Introduction

This article describes the installation procedure for Mimer SQL on Linux. The information herein is in principle valid for Linux and Unix distributions of Mimer SQL from version 9.1, but its focus is later Mimer SQL versions on Linux.

The Mimer SQL software installation is expected to be completed in less than a minute, and creating the initial data dictionary and starting the database server will only take just a little longer.

Why do we need sudo access to install?

To provide for a complete and proper easy-to-use installation, the procedure when installing Mimer SQL is doing all needed installation actions automatically. This includes updates to operating system locations, such as /usr/bin, /usr/lib and /etc. For example, the following tasks are handled:

  • TCP/IP settings for Mimer SQL client/server access (/etc/xinetd.d, or /etc/systemd/system),
  • autostart settings for Mimer SQL databases (/etc/init.d),
  • desktop menu items (/etc/xdg, /usr/share),
  • system wide Mimer SQL database catalog (/etc/sqlhosts),
  • system wide ODBC data source catalog (typically /etc/odbc.ini and /etc/odbcinst.ini),
  • system wide Mimer SQL man-page setup (/usr/man, or /usr/share/man), and
  • easy access for Mimer SQL programs and libraries (/usr/bin and /usr/lib).

To achieve this, the installation requires sudo access, or it has to be executed as root.

Prerequisites

When using the RPM package, the RPM package manager environment must be installed. Installation using the RPM package means that a predefined installation is made to a default setup.

When using the DEB package, a package manager environment that can cope with DEB-files must be installed. Installation using the DEB package means that a predefined installation is made to a default setup.

The TAR installation procedure allows for a more flexible installation, but other other hand, it requires some answers to questions. The questions are given with explanations to each installation step and with default options.

Environment

Which components will be installed?

The Mimer SQL distribution contains the following:

  • Tools, libraries, examples, man-pages, etc.
  • A complete documentation set in PDF format. Online documentation, in PDF and/or HTML can be obtained here at the Documentation page.
  • An ODBC Driver, available in the libmimodbc shared library – see ODBC interface. This driver can be used for direct access to a Mimer SQL database, or it can be used with a third party ODBC Driver Manager, for example unixODBC, or iODBC.
  • A JDBC Driver, type-4, written in 100% Java – see JDBC interface.
  • Python interface (from Mimer SQL version 11).
  • Various other database APIs like Embedded SQL and a native Mimer API.

The default installation location is /opt, where a sub directory named according to the package is created. For example, if Mimer SQL 11.0.0A is installed, an installation path like /opt/mimersql1100-11.0.0A is used. This Mimer SQL main directory then contains the following sub directories:

  • bin – contains Mimer SQL tools, and other executable files.
  • DbVisualizer – contains all resources for the DbVisualizer tool that is bundled with Mimer SQL. Please note that an even more powerful version, DbVisualizer Pro, that can be purchased from www.dbvis.com. The DbVisualizer Pro features are enabled by installing a license key file.
  • doc – contains Mimer SQL documentation.
  • examples – contains example files.
  • include – contains various header files that may be needed when developing with Mimer SQL.
  • lib – contains library files.
  • lib32 – contains 32-bit libraries for execution of 32-bit applications. (Only available in installation packages for 64-bit platforms).
  • man – contains Mimer SQL man pages.
  • misc – contains various additional files, like desktop menu system resources.

Several methods to install

For Linux platforms the software package is currently available in three different shapes:

  1. RPM installation
    This installation type needs the RPM package manager environment to be installed. An advantage is that possible dependencies to other software automatically are verified and arranged for.
  2. DEB installation
    This installation type needs a Debian package manager to be installed. In the example below the ‘dpkg’ command will be used. Dependencies will be verified during this installation.
  3. TAR installation
    This installation type is platform independent and is the one that can be used for all UNIX platforms. If a customized installation is desired, for example if the software should be located in a non-default location, the TAR installation may be handy. On the other hand, a TAR installation is not integrated in commonly used package managers and must therefore be managed manually.

Using the RPM distribution package

This is the procedure to follow when using an RPM distribution of Mimer SQL.

When using RPM, installed files are fully maintained by the RPM package manager. RPM will keep track of all files installed by RPM, and it will also check that all dependencies to system libraries are available and up-to-date.

To get a short description of an RPM file before installing it, you can use the following command:

# rpm -qpid mimersql1100-11.0.0A-24298.x86_64.rpm

An example installation using RPM could be as follows:

# sudo rpm -i mimersql1100-11.0.0A-24298.x86_64.rpm

From the Mimer SQL point of view, the RPM installation is a silent install. RPM can be instructed to be “very verbose” by using the ‘-ivv’ switch instead of ‘-i’, which will display the information known by, and performed by, RPM for the installed package.

You can run the installation procedure without actually installing anything by using the “–test” option as in the following example:

# rpm -i --test mimersql1100-11.0.0A-24298.x86_64.rpm

If an older version of an RPM-package is already installed when a new RPM-package is available, the upgrade switch can be used. See the following example:

# sudo rpm -U mimersql1100-11.0.0A-24298.x86_64.rpm

Note! An upgrade can only be done if the only difference in the package name is the package revision number, in this case “24298”. Otherwise the new product is installed using the ‘-i’ option, and then the old package is removed (see below).

To get a listing of all installed rpm packages the “-qa” switch is used. Combined with grep the following command will display all Mimer SQL packages installed with the rpm command:

# rpm -qa | grep -i mimer

To get details of the package and to get instructions on how to continue, including how to create a database using the dbinstall, use the following command:

# rpm -qid mimersql1100-11.0.0A-24298

For further details about RPM, see the corresponding man-page, or visit the RPM Documentation page.

Using the DEB distribution package

For platforms that use the Debian installation format, we suggest the dpkg command to be used. This is the procedure to follow when using an DEB distribution of Mimer SQL with dpkg.

To get a description of an DEB file before installing it, you can use the following command:

# dpkg-deb -I mimersql1100_11.0.0A-24298_amd64.deb

An example installation using a DEB file could be as follows:

# sudo dpkg -i mimersql1100_11.0.0A-24298_amd64.deb

From the Mimer SQL point of view, the DEB installation is a silent install, not displaying any details in operations performed.

Note! Installations that in fact is an upgrade of an existing package is handled automatically by the dpkg command.

To get a listing of all installed DEB packages the “-l” switch is used. Combined with grep, the following command will display all DEB packages installed for Mimer SQL with the command:

# dpkg -l | grep -i mimer

Using the TAR distribution package

This is the procedure to follow when using a TAR format distribution of Mimer SQL.

Unpack the distributed TAR archive by using a standard tar extract command, for example:

# tar xvf mimersql1100-11.0.0A-24298_linux26_64.tar

Command line options used:

  • x – means extract
  • v – means verbose
  • f – means that the file name that follows is the one that should be used.

A subdirectory named according to the distribution has now been created in the current directory, holding the tar archive contents. There, the miminstall command is available, which should be executed to install the Mimer SQL software. Simply execute the command as follows:

# ./miminstall

During the miminstall session the license agreement should be accepted, a temporary location for unpacking should be chosen, and then the location for the Mimer SQL software in the file system should be specified.

The tar installation can also be executed in silent mode, mainly aimed for embedded installations.

Note! The miminstall command can be executed in a non-operational mode by using the ‘-n’ option, meaning it only prints information about the installation steps without performing them.

Running several Mimer SQL versions in parallel

If it is desirable to run two or more Mimer SQL versions in parallel on a host computer, this is fully feasible, but the following must be regarded:

  • If installing an RPM version while a tar installation is already made, it may be the case that host global configuration files such as /etc/sqlhosts for database registration and /etc/mimerkey for the license keys are reinstalled. In this case the original files are renamed to have the file name extension ‘.rpmsave’.
  • If two or more packages of the same version is to be installed, only one can be installed using RPM or DEB installation packages. For additional installations the TAR package should be used where other installation directories than /opt is used.
  • If installing using RPM or DEB, the installation will always put itself as the preferred installation, located via /usr/bin and /usr/lib, for example. This is an installation option if installing with TAR. The commands mimlink and mimunlink can be used to adjust this after installations are done, but please note that it is essential that there is an installation linked to these locations since various default settings are pointing there.

Creating an initial database

Once you have installed the software you can build a Mimer SQL database by using the dbinstall command.

As mentioned before, the dbinstall command requires sudo access, or must be executed by root. If not started from a privileged shell sudo password will be asked for:

# dbinstall
 This operation needs root access. Using sudo...
 root's password:
 Mimer SQL Version 11.0.0, Database Server Installation Procedure...

During the dbinstall session, database name, database location, and password for the database administrator (i.e. SYSADM) should be specified. There will also be options for installing example environments, etc. When the session is completed, a fully operational database is available – enabled for client/server access over TCP and automatic start at reboot.

Note! dbinstall creates all system databank files in the given database server home directory. In a production system it is recommended that the SYSDB, TRANSDB and LOGDB files are located on separate disks due to performance and reliability reasons. You can read more about this in the Mimer SQL System Management Handbook part of the Mimer SQL Documentation Set (found at the Documentation page).

Upgrading an existing database

If you are upgrading an existing database from an earlier version of Mimer SQL, please see the Mimer SQL Release Notes for detailed information. This document is provided within each Mimer SQL distribution package. In short the steps are as follows:

  1. Install the new Mimer SQL version in parallel with your existing Mimer SQL.
  2. Stop the database.
  3. Make sure the new Mimer SQL version is the one accessed, and run the sdbgen -u database command.
  4. Start the database with the database server program from the new Mimer SQL version.

Uninstalling the software

What happens to the databases?

The commands described below, mimuninstall, dpkg -r and rpm -e, will remove the given software installation, but any databases using the installation will remain intact. Since databases may contain valuable data, the removal of databank files is not made under cover.

If a database, and its databank files, is going to be removed, use the dbuninstall command. When executed, a question will be raised asking if specified database should be removed, i.e. permanently deleted.

# dbuninstall database_name

Removing an RPM installation

To remove an installation installed using RPM, use the following RPM command:

# rpm -e mimersql1100-11.0.0A-24298

For more detailed information printout when uninstalling, the -ev or -evv options can be used.

Removing a DEB installation

To remove a DEB package installation, use the following dpkg command:

# sudo dpkg -r mimersql1100

Removing a TAR installation

To remove an installation that was installed using the miminstall command, use the mimuninstall command as follows:

# mimuninstall /opt/mimersql1100-11.0.0A

When running the mimuninstall command a question will be raised on if the /etc/sqlhosts and /etc/mimerkey files should be removed. These are global files to Mimer SQL, used by any installation, so the recommendation is to.

Links

Read more on RPM »

On your Debian linux system you can do ‘man dpkg’ for more information on that command.

It should also be mentioned that there are some Linux/Unix specific appendixes in the System Management Handbook part of the Mimer SQL Documentation Set that may be worth reading.

Graphic Element - Cube