How to install packages in servers with no Internet access

Israel Barth
Israel Barth
  • Updated

Authors: Israel Barth and Prince Nwando.

This article takes a look at how we can install RPM and DEB packages in a server that is not connected to the Internet.

One way of doing that is described in the knowledge base article How to proxy our private Yum and Apt repositories, which consists of using a proxy for the repositories. It works both for RPM and DEB based installations.

Another way is described in the present article, which also works with RHEL based RPM as well as a Debian based DEB platforms. It consists of downloading the packages and its dependencies through RPM/DEB repository on a server with Internet access, and then copying the RPM / DEB packages to the server without Internet and lastly performing a local installation.

1- Install EDB repos

EDB currently has two independent repository systems:

  • EDB Repos 2.0 is the latest, recommended system.
  • EDB Repos 1.0 is the legacy system.

Please note that the EDB Repos 1.0 will be dismissed in the near future, therefore, unless you have any special reasons to use it, we recommend using EDB Repos 2.0, which is our more advanced repository system.

As an example in this article, we will demonstrate installing PostgreSQL 15 on a Rockylinux 8 and Ubuntu 22.04 servers using both repository systems.

EDB Repos 2.0

  • Navigate to and click on "Access EDB Repos 2.0"
  • Select Platform
  • Click on the desired product
  • Run the commands as demonstrated below to set up the repository in your server that is connected to the Internet.

Within EDB Repos 2.0, there are two options for installation. Choose one of them:

  • Auto
  • Manual

EDB Repos 2.0 Auto installation

# Install yum-utils
dnf install -y yum-utils

# Run repo setup autocommand
# **your_company_token** will already be filled up for you (NOTE: never share the token in Support tickets or via email)
curl -1sLf '**your_company_token**/enterprise/' | sudo -E bash

# Disable the built-in PostgreSQL module:
dnf -qy module disable postgresql
Debian / Ubuntu
curl -1sLf '**<your_company_token>**/enterprise/' | sudo -E bash

EDB Repos 2.0 Manual installation

# Install yum-utils
dnf install -y yum-utils

# Import key
rpm --import '**your_company_token**/enterprise/gpg.E71EB0829F1EF813.key'

# Import config
curl -1sLf '**your_company_token**/enterprise/config.rpm.txt?distro=el&codename=8' > /tmp/enterprise.repo

# Add config
dnf config-manager --add-repo '/tmp/enterprise.repo'

# Enable repo
dnf -q makecache -y --disablerepo='*' --enablerepo='enterprisedb-enterprise'

# Disable the built-in PostgreSQL module:
dnf -qy module disable postgresql
Debian / Ubuntu
apt-get install -y debian-keyring  # debian only

apt-get install -y debian-archive-keyring  # debian only

apt-get install -y apt-transport-https

# For Debian Stretch, Ubuntu 16.04 and later


curl -1sLf '**your_company_token**/enterprise/gpg.E71EB0829F1EF813.key' |  gpg --dearmor > ${keyring_location}

curl -1sLf '**your_company_token**/enterprise/config.deb.txt?distro=ubuntu&codename=<your_ubuntu_flavor>' > /etc/apt/sources.list.d/enterprisedb-enterprise.list

apt-get update

EDB Repos 1.0

  • Navigate to
  • Take note of your Repo Username/Password shown in the EDB Repos 1.0 section. These credentials are different than the ones you used to login to the website
  • Click "Access EDB Repos 1.0"
  • Select Platform
  • Click on the desired product
  • Run the commands as demonstrated below to set up the repository in your Internet connected server


# Install yum-utils
dnf install -y yum-utils

# Install the repository configuration
dnf -y install

# Replace 'USERNAME:PASSWORD' below with the Repo username and password you annotated previously
# Go back to in case you need to get them
sed -i "s@<username>:<password>@USERNAME:PASSWORD@" /etc/yum.repos.d/edb.repo

# Install EPEL repo
dnf -y install

# Disable the built-in PostgreSQL module:
dnf -qy module disable postgresql

Debian / Ubuntu

# Setup the EDB repository
sudo su -c 'echo "deb [arch=amd64]$(lsb_release -cs)-edb/ $(lsb_release -cs) main" > /etc/apt/sources.list.d/edb-$(lsb_release -cs).list'

# Replace '<USERNAME>' and '<PASSWORD>' below with your username and password for the EDB repositories.
# Visit to get your username and password
sudo su -c 'echo "machine login <USERNAME> password <PASSWORD>" > /etc/apt/auth.conf.d/edb.conf'

# Add support for secure APT repositories
sudo apt-get -y install apt-transport-https

# Add the EDB signing key
sudo wget -q -O - | sudo apt-key add -

# Update the repository meta data
sudo apt update

2 Create and enter destination directory

Still in the server with Internet connection, create a directory to receive all RPM / DEB files and enter (cd) into that directory. As an example, we will host all downloaded RPM / DEB files under a folder called edb_packages:

mkdir edb_packages && cd edb_packages

3- Download the packages


On the Internet connected server, run yumdownloader to download the package you want. The --resolve option will also resolve and download all dependencies:

yumdownloader -y postgresql15-server postgresql15-contrib --resolve


dnf download postgresql15-server postgresql15-contrib --resolve --alldeps

Debian / Ubuntu

sudo apt-get --download-only -o Dir::Cache=$(pwd) install postgresql-15

At this point the folder edb_packages will contain all the required packages and their dependencies. Confirm that the files are present with ls -l, for example, on RHEL 8:

-rw-r--r-- 1 root root 9258864 Apr 24 13:13 libicu-60.3-2.el8_1.x86_64.rpm
-rw-r--r-- 1 root root 254484 Apr 24 13:13 libxslt-1.1.32-6.el8.x86_64.rpm
-rw-r--r-- 1 root root 104920 Apr 24 13:13 lz4-1.8.3-3.el8_4.x86_64.rpm
-rw-r--r-- 1 root root 29776 Apr 24 13:12 perl-Carp-1.42-396.el8.noarch.rpm...
-rw-r--r-- 1 root root 1703300 Apr 24 13:03 postgresql15-15.2-1PGDG.rhel8.x86_64.rpm
-rw-r--r-- 1 root root 767956 Apr 24 13:03 postgresql15-contrib-15.2-1PGDG.rhel8.x86_64.rpm
-rw-r--r-- 1 root root 299780 Apr 24 13:03 postgresql15-libs-15.2-1PGDG.rhel8.x86_64.rpm
-rw-r--r-- 1 root root 6200624 Apr 24 13:03 postgresql15-server-15.2-1PGDG.rhel8.x86_64.rpm

4- Copy files to the Internet-less server

Now you can copy the above folder containing all RPM / DEB files to your isolated Internet-less server.

5- Install packages on the Internet-less server

Enter (cd) into the directory containing the RPM / DEB files in the Internet-less server and install the packages with one of the following commands.


dnf --disablerepo=* localinstall *.rpm

Debian / Ubuntu

apt install -y *.deb

6- Review installation

You can check the installed package with the following commands.


dnf list installed postgresql15-server

Example output:

Installed Packages
postgresql15-server.x86_64 15.2-1PGDG.rhel8 @@commandline

Debian / Ubuntu

sudo apt list postgresql-15 -a
Listing... Done
postgresql-15/jammy,now 15.7-1EDB.jammy amd64 [installed]
postgresql-15/jammy 15.6-2EDB.jammy amd64
postgresql-15/jammy 15.6-1EDB.jammy amd64
postgresql-15/jammy 15.5-1EDB.jammy amd64
postgresql-15/jammy 15.4-1.jammy amd64
postgresql-15/jammy 15.3-1.jammy amd64
postgresql-15/jammy 15.2-1.pgdg22.04+1 amd64

Was this article helpful?

0 out of 0 found this helpful