Installing the MongoDB Foreign Data Wrapper v5.2.9

The MongoDB Foreign Data Wrapper can be installed with an RPM package. During the installation process, the installer will satisfy software prerequisites. If yum encounters a dependency that it cannot resolve, it will provide a list of the required dependencies that you must manually resolve.

Installing the MongoDB Foreign Data Wrapper using an RPM Package

You can install the MongoDB Foreign Data Wrapper using an RPM package on the following platforms:

On RHEL or CentOS 7 PPCLE

  1. Use the following command to create a configuration file and install Advance Toolchain:

    rpm --import https://public.dhe.ibm.com/software/server/POWER/Linux/toolchain/at/redhat/RHEL7/gpg-pubkey-6976a827-5164221b
    
    cat > /etc/yum.repos.d/advance-toolchain.repo <<EOF
    # Begin of configuration file
    [advance-toolchain]
    name=Advance Toolchain IBM FTP
    baseurl=https://public.dhe.ibm.com/software/server/POWER/Linux/toolchain/at/redhat/RHEL7
    failovermethod=priority
    enabled=1
    gpgcheck=1
    gpgkey=ftp://public.dhe.ibm.com/software/server/POWER/Linux/toolchain/at/redhat/RHELX/gpg-pubkey-6976a827-5164221b
    # End of configuration file
    EOF
  2. Install the EDB repository:

    yum -y install https://yum.enterprisedb.com/edbrepos/edb-repo-latest.noarch.rpm
  3. Replace ‘USERNAME:PASSWORD’ below with your username and password for the EDB repositories:

    sed -i "s@<username>:<password>@USERNAME:PASSWORD@" /etc/yum.repos.d/edb.repo
  4. Install the EPEL repository:

    yum -y install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
  5. On RHEL 7 PPCLE, enable the additional repositories to resolve EPEL dependencies:

    subscription-manager repos --enable "rhel-*-optional-rpms" --enable "rhel-*-extras-rpms"  --enable "rhel-ha-for-rhel-*-server-rpms"
  6. Install the selected package:

    dnf install edb-as<xx>-mongo_fdw

    where xx is the server version number.

On RHEL 7

  1. To create the repository configuration file, assume superuser privileges, and invoke the following command:

    yum -y install https://yum.enterprisedb.com/edbrepos/edb-repo-latest.noarch.rpm
  2. Replace ‘USERNAME:PASSWORD’ below with your username and password for the EDB repositories:

    sed -i "s@<username>:<password>@USERNAME:PASSWORD@" /etc/yum.repos.d/edb.repo
  3. Install the EPEL repository:

    yum -y install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
  4. Enable the additional repositories to resolve dependencies:

    subscription-manager repos --enable "rhel-*-optional-rpms" --enable "rhel-*-extras-rpms"  --enable "rhel-ha-for-rhel-*-server-rpms"
  5. Install the selected package:

    dnf install edb-as<xx>-mongo_fdw

    where xx is the server version number.

On RHEL 8

  1. To create the repository configuration file, assume superuser privileges, and invoke the following command:

    dnf -y install https://yum.enterprisedb.com/edbrepos/edb-repo-latest.noarch.rpm
  2. Replace ‘USERNAME:PASSWORD’ below with your username and password for the EDB repositories:

    sed -i "s@<username>:<password>@USERNAME:PASSWORD@" /etc/yum.repos.d/edb.repo
  3. Install the EPEL repository:

    dnf -y install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm
  4. Enable the additional repositories to resolve dependencies:

    ARCH=$( /bin/arch ) subscription-manager repos --enable "codeready-builder-for-rhel-8-${ARCH}-rpms"
  5. Disable the built-in PostgreSQL module:

    dnf -qy module disable postgresql
  6. Install the selected package:

    dnf install edb-as<xx>-mongo_fdw

    where xx is the server version number.

On CentOS 7

  1. To create the repository configuration file, assume superuser privileges, and invoke the following command:

    yum -y install https://yum.enterprisedb.com/edbrepos/edb-repo-latest.noarch.rpm
  2. Replace ‘USERNAME:PASSWORD’ below with your username and password for the EDB repositories:

    sed -i "s@<username>:<password>@USERNAME:PASSWORD@" /etc/yum.repos.d/edb.repo
  3. Install the EPEL repository:

    yum -y install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
  4. Install the selected package:

    dnf install edb-as<xx>-mongo_fdw

    where xx is the server version number.

On CentOS 8

  1. To create the repository configuration file, assume superuser privileges, and invoke the following command:

    dnf -y install https://yum.enterprisedb.com/edbrepos/edb-repo-latest.noarch.rpm
  2. Replace ‘USERNAME:PASSWORD’ below with your username and password for the EDB repositories:

    sed -i "s@<username>:<password>@USERNAME:PASSWORD@" /etc/yum.repos.d/edb.repo
  3. Install the EPEL repository:

    dnf -y install epel-release
  4. Enable the additional repositories to resolve dependencies:

    dnf config-manager --set-enabled PowerTools
  5. Disable the built-in PostgreSQL module:

    dnf -qy module disable postgresql
  6. Install the selected package:

    dnf install edb-as<xx>-mongo_fdw

    where xx is the server version number.

Installing the MongoDB Foreign Data Wrapper on a Debian or Ubuntu Host

To install the MongoDB Foreign Data Wrapper on a Debian or Ubuntu host, you must have credentials that allow access to the EDB repository. To request credentials for the repository, visit the EDB website.

The following steps will walk you through using the EDB apt repository to install a Debian package. When using the commands, replace the username and password with the credentials provided by EDB.

  1. Assume superuser privileges:

    sudo su –
  2. Configure the EDB repository:

    On Debian 9 and Ubuntu:

    sh -c 'echo "deb https://username:password@apt.enterprisedb.com/$(lsb_release -cs)-edb/ $(lsb_release -cs) main" > /etc/apt/sources.list.d/edb-$(lsb_release -cs).list'

    On Debian 10:

    1. Set up the EDB repository:

      sh -c 'echo "deb [arch=amd64] https://apt.enterprisedb.com/$(lsb_release -cs)-edb/ $(lsb_release -cs) main" > /etc/apt/sources.list.d/edb-$(lsb_release -cs).list'
    2. Substitute your EDB credentials for the username and password in the following command:

      sh -c 'echo "machine apt.enterprisedb.com login <username> password <password>" > /etc/apt/auth.conf.d/edb.conf'
  3. Add support to your system for secure APT repositories:

    apt-get install apt-transport-https
  4. Add the EDB signing key:

    wget -q -O - https://<username>:<password>@apt.enterprisedb.com/edb-deb.gpg.key | apt-key add -
  5. Update the repository metadata:

    apt-get update
  6. Install the Debian package:

    apt-get install edb-as<xx>-mongo-fdw

    where xx is the server version number.