Optional: Installing native external MonetDB

You can install MonetDB on a separate machine and use it as a database for IBM Process Mining.

To install MonetDB on Ubuntu do the following steps:

  1. Run the following commands. You must state the explicit version of MonetDB during the installation:
    
    echo "deb https://dev.monetdb.org/downloads/deb/ $(lsb_release -sc) monetdb" | sudo tee /etc/apt/sources.list.d/monetdb.list
    sudo wget --output-document=/etc/apt/trusted.gpg.d/monetdb.gpg https://dev.monetdb.org/downloads/MonetDB-GPG-KEY.gpg
    sudo apt update
    sudo apt install monetdb5-server=11.55.1 libmonetdb-client28=11.55.1 libmonetdb-stream28=11.55.1 libmonetdb31=11.55.1 monetdb-server=11.55.1 monetdb-sql=11.55.1 libmonetdbe27=11.55.1 libmonetdb-mutils=11.55.1 monetdb5-server-dev=11.55.1 libmonetdb-dev=11.55.1 libmonetdb-stream-dev=11.55.1 monetdb-server-dev=11.55.1 monetdb-sql-dev=11.55.1 libmonetdbe-dev=11.55.1 libmonetdb-client-dev=11.55.1 monetdb-client=11.55.1
        
  2. Make sure that the version is pinned and does not get upgraded accidentally with the following command:
    dpkg -l | grep monetdb | cut -d " " -f 3 | xargs -I {} sh -c "echo {} hold | sudo dpkg --set-selections"
    

    For more information, see Ubuntu&Debian Easy Setup.

  3. Download the IBM Process Mining package to obtain the MonetDB module library:
    1. Go to the Online tab in IBM® Passport Advantage® and log in with your IBMid.
    2. Refer to Distribution package to get the part numbers of the IBM Process Mining and IBM Task Mining packages that you want to download.
    3. Search for your IBM Process Mining package by using the part number.
    4. Download the files to a directory on your computer.
  4. Run the following command to extract the IBM Process Mining MonetDB module library:
    
    cd ~
    tar xvf ibmprocessmining-monet-X.Y.Z.tar.gz
    
    Note: The ibmprocessmining-monet-X.Y.Z.tar.gz file is included in the IBM Process Mining package downloaded from Passport Advantage®, where X.Y.Z represents the version number (for example, ibmprocessmining-monet-2.1.0_960b582.tar.gz where X=major version, Y=minor version, and Z=SHA for the release).
  5. Add IBM Process Mining MonetDB module library to your MonetDB deployment with the following commands:
    
    pushd /usr/lib/x86_64-linux-gnu/monetdb5
    # Folder present per Ubuntu version
    # monet-library/ubuntu
    # ├── jammy
    # └── noble
    cp ~/monet-library/ubuntu/$(lsb_release -sc)/*.so .
    ln -s lib_PM-sql-2.1.0.so lib_PM-sql.so
    popd
    

To install MonetDB on RedHat do the following steps:

  1. Run the following commands. You must state the explicit version of MonetDB during the installation:
    
    sudo yum install https://dev.monetdb.org/downloads/epel/MonetDB-release-epel.noarch.rpm
    sudo rpm --import https://dev.monetdb.org/downloads/MonetDB-GPG-KEY
    sudo yum install MonetDB-SQL-11.55.1 MonetDB-client-11.55.1 MonetDB-11.55.1 MonetDB-stream-11.55.1
    
  2. Make sure that the version is pinned and does not get upgraded accidentally. You can block version update in one of the two ways:
    • Use the following command to lock the version:
      
      sudo yum install python3-dnf-plugin-versionlock
      sudo yum versionlock MonetDB*
      
    • Use the following command to do a manual yum update without updating MonetDB:
      
      sudo yum update --exclude MonetDB*
      

    For more information, see RedHat&CentOS Easy Setup.

    Important: With RedHat 9, if you encounter a KEY import error, you need to temporarily set crypto-policies to LEGACY with the following command:
    
    sudo rpm --import https://dev.monetdb.org/downloads/MonetDB-GPG-KEY
    warning: Signature not supported. Hash algorithm SHA1 not available.
    error: https://dev.monetdb.org/downloads/MonetDB-GPG-KEY: key 1 import failed.
    
    update-crypto-policies --set LEGACY
    rpm --import https://dev.monetdb.org/downloads/MonetDB-GPG-KEY
    update-crypto-policies --set DEFAULT
    
  3. Download the IBM Process Mining package to obtain the MonetDB module library:
    1. Go to the Online tab in IBM® Passport Advantage® and log in with your IBMid.
    2. Refer to Distribution package to get the part numbers of the IBM Process Mining and IBM Task Mining packages that you want to download.
    3. Search for your IBM Process Mining package by using the part number.
    4. Download the files to a directory on your computer.
  4. Run the following command to extract the IBM Process Mining MonetDB module library:
    
    cd ~
    tar xvf ibmprocessmining-monet-X.Y.Z.tar.gz
    
    Note: The ibmprocessmining-monet-X.Y.Z.tar.gz file is included in the IBM Process Mining package downloaded from Passport Advantage®, where X.Y.Z represents the version number (for example, ibmprocessmining-monet-2.1.0_960b582.tar.gz where X=major version, Y=minor version, and Z=SHA for the release).
  5. Add IBM Process Mining MonetDB module library to your MonetDB deployment with the following commands:
    
    pushd /usr/lib64/monetdb5-11.55.1
    # Folder present per RHEL version
    # monet-library/rhel
    # ├── 8
    # ├── 9
    cp ~/monet-library/rhel/$(lsb_release -rs | awk '{printf"%d",$NF}')/*.so .
    ln -s lib_PM-sql-2.2.0.so lib_PM-sql.so
    popd
    

Configuring MonetDB

Do the following steps to configure an external MonetDB database:

  1. Optional: Configure an alternative database farm location. You can skip this step if you are using the default location /var/monetdb5/dbfarm.

    Create the alternative location with the following command:

    
    sudo monetdbd create /path/to/mydbfarm
    sudo monetdbd start /path/to/mydbfarm
    
  2. Set the network address MonetDB will listen on.

    The following command will open MonetDB to all addresses. You can change this setting according to your deployment approach:

    sudo monetdbd set listenaddr=0.0.0.0 /var/monetdb5/dbfarm
    
  3. Default port is 50000.

    You can set an alternative port with the following command:

    sudo monetdbd set port=50000 /var/monetdb5/dbfarm
    
  4. Check contents of the following properties file to confirm the changes:
    sudo cat /var/monetdb5/dbfarm/.merovingian_properties
    
  5. Enable and start MonetDB service with the following command:
    
    sudo systemctl enable monetdbd
    sudo systemctl start monetdbd
    
  6. Confirm MonetDB launched successfully with the following command:
    
    sudo systemctl status monetdbd
    sudo tail /var/log/monetdb/merovingian.log
    
  7. Create a MonetDB database:
    1. Set a password and configuration with the following command:
      
      export PM_MONET_PWD="OCP-processmining"
      export PM_MONET_DB="ocp-processmining"
      
      sudo monetdb create -p "${PM_MONET_PWD}" ${PM_MONET_DB}
      sudo monetdb set loadmodules=PM-sql ${PM_MONET_DB}
      sudo monetdb set nclients=96 ${PM_MONET_DB}
      
      sudo monetdb start ${PM_MONET_DB}
      
    2. Confirm MonetDB database launched successfully with the following command:
      
      sudo tail /var/log/monetdb/merovingian.log