Perform the following steps to install yb-voyager using apt for Ubuntu:
Note
apt installation is only supported for Ubuntu 22. For other versions such as 18 and 20, use the install script via the Source installation option.
-
Install the Yugabyte apt repository on your machine using the following command:
wget https://software.yugabyte.com/repos/reporpms/yb-apt-repo_1.0.0_all.deb sudo apt-get install ./yb-apt-repo_1.0.0_all.debThis repository contains the
yb-voyagerDebian package and the dependencies required to runyb-voyager. -
Install the
postgresql-commonrepository to fetch PostgreSQL 16 using the following commands:sudo apt install -y postgresql-common sudo /usr/share/postgresql-common/pgdg/apt.postgresql.org.sh -
Clean the
apt-getcache and package lists using the following commands:sudo apt-get clean sudo apt-get update -
Install yb-voyager and its dependencies using the following command:
sudo apt-get install yb-voyagerNote: If you see a failure in the install step similar to the following:
Depends: ora2pg (= 23.2-yb.2) but 24.3-1.pgdg22.04+1 is to be installedTry installing ora2pg using the following command:
sudo apt-get install ora2pg=23.2-yb.2Then try installing yb-voyager using the following command:
sudo apt-get install yb-voyager -
Check that yb-voyager is installed using the following command:
yb-voyager version
Upgrade yb-voyager
Note
If you are upgrading Voyager from version 1.8.0 or earlier, you need to install the postgresql-common repository before the upgrade as follows:
sudo apt install -y postgresql-common
sudo /usr/share/postgresql-common/pgdg/apt.postgresql.org.sh
Upgrade yb-voyager using the following command:
sudo apt-get upgrade yb-voyager