{"id":10192,"date":"2026-05-19T13:07:40","date_gmt":"2026-05-19T07:37:40","guid":{"rendered":"https:\/\/pheonixsolutions.com\/blog\/?p=10192"},"modified":"2026-08-26T10:24:38","modified_gmt":"2026-08-26T04:54:38","slug":"liquibase-installation-on-ubuntu-24","status":"publish","type":"post","link":"https:\/\/pheonixsolutions.com\/blog\/liquibase-installation-on-ubuntu-24\/","title":{"rendered":"Liquibase Installation on Ubuntu 24"},"content":{"rendered":"\n<h1 class=\"wp-block-heading\">Introduction<\/h1>\n\n\n\n<p class=\"wp-block-paragraph\">This guide explains how to <strong>install Liquibase on Ubuntu<\/strong>, an open-source database change management tool used to track, version, and deploy database schema changes in a structured, controlled way. Liquibase is commonly used in DevOps pipelines and CI\/CD workflows \u2014 Jenkins, GitLab, and ArgoCD among them \u2014 to keep database schemas consistent across development, testing, and production environments.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">Implementation<\/h2>\n\n\n\n<h3 class=\"wp-block-heading\">I. Prerequisites<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Before you install Liquibase on Ubuntu, make sure your system meets the following requirements:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Ubuntu 22.04 or 24.04 LTS<\/li>\n\n\n\n<li>Java 11 or higher<\/li>\n\n\n\n<li>Internet access for downloading packages<\/li>\n\n\n\n<li>The <code>wget<\/code> and <code>unzip<\/code> utilities<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">If any of these tools are missing, they can be installed using <code>apt<\/code>, as shown in the steps below.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">II. Why Use Liquibase?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Before diving into the installation steps, it&#8217;s worth understanding what problem Liquibase actually solves. Manually applying database schema changes across development, staging, and production environments is error-prone \u2014 a change tested locally can easily be forgotten, applied out of order, or skipped entirely in production. Liquibase solves this by tracking every schema change as a version-controlled &#8220;changeset,&#8221; similar to how Git tracks code changes. This makes schema updates repeatable, auditable, and safe to roll back, which is exactly why teams integrate it into CI\/CD pipelines rather than running SQL scripts by hand.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">III. Update System Packages<\/h3>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">sudo apt update\n<\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">IV. Install Java<\/h3>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">sudo apt install -y default-jre\n<\/pre>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p class=\"wp-block-paragraph\"><strong>Note:<\/strong> <code>default-jre<\/code> installs a Java Runtime Environment, which is sufficient to run Liquibase. If you also plan to compile custom Liquibase extensions or Java-based changelogs, you may want <code>default-jdk<\/code> (the full Java Development Kit) instead.<\/p>\n<\/blockquote>\n\n\n\n<h3 class=\"wp-block-heading\">V. Verify the Java Installation<\/h3>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">java -version\n<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Expected output: Java 11 or higher.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">VI. Navigate to the \/opt Directory<\/h3>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">cd \/opt\n<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><code>\/opt<\/code> is a conventional location for optional, self-contained third-party software on Linux, which makes it a sensible place to install Liquibase outside of your package manager.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">VII. Download and Install Liquibase on Ubuntu<\/h3>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">sudo wget https:\/\/github.com\/liquibase\/liquibase\/releases\/download\/v4.29.2\/liquibase-4.29.2.zip\n<\/pre>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p class=\"wp-block-paragraph\"><strong>Tip:<\/strong> Check the <a href=\"https:\/\/github.com\/liquibase\/liquibase\/releases\" target=\"_blank\" rel=\"noopener\">official Liquibase releases page<\/a> for the current version before downloading, so you install the latest stable release rather than a fixed older version.<\/p>\n<\/blockquote>\n\n\n\n<p class=\"wp-block-paragraph\">Extract the package:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">sudo unzip liquibase-4.29.2.zip\n<\/pre>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p class=\"wp-block-paragraph\">If <code>unzip<\/code> isn&#8217;t already installed, add it first with <code>sudo apt install -y unzip<\/code>.<\/p>\n<\/blockquote>\n\n\n\n<h3 class=\"wp-block-heading\">VIII. Verify the Liquibase Installation<\/h3>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">\/opt\/liquibase --version\n<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Expected output: <code>Liquibase Version 4.29.2<\/code><\/p>\n\n\n\n<h3 class=\"wp-block-heading\">IX. Add Liquibase to PATH (Optional)<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">To run <code>liquibase<\/code> from anywhere without typing the full path, add <code>\/opt<\/code> to your shell&#8217;s PATH:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">echo 'export PATH=$PATH:\/opt' >> ~\/.bashrc\nsource ~\/.bashrc\n<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Verify it worked:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">liquibase --version\n<\/pre>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p class=\"wp-block-paragraph\"><strong>Note:<\/strong> Appending the entire <code>\/opt<\/code> directory to PATH also exposes any other tools installed there. If you&#8217;d rather keep PATH changes scoped to Liquibase specifically, create a symlink instead: <code>sudo ln -s \/opt\/liquibase-4.29.2\/liquibase \/usr\/local\/bin\/liquibase<\/code>.<\/p>\n<\/blockquote>\n\n\n\n<h3 class=\"wp-block-heading\">X. Conclusion<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">You&#8217;ve now successfully installed Liquibase on Ubuntu, along with the Java prerequisite it depends on. The system is ready for database version control and migration management.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Typical next steps include:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Configuring a database connection using <code>liquibase.properties<\/code><\/li>\n\n\n\n<li>Creating and running your first migration script<\/li>\n\n\n\n<li>Integrating Liquibase with a CI\/CD pipeline such as <a href=\"https:\/\/pheonixsolutions.com\/blog\/jenkins-user-creation-and-permission-management-guide\/\">Jenkins<\/a> or GitLab<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">Frequently Asked Questions<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Do I need the full JDK, or is the JRE enough to run Liquibase?<\/strong> The JRE (<code>default-jre<\/code>) is enough to run Liquibase itself. You&#8217;d only need the full JDK if you&#8217;re building custom extensions or writing Java-based changelogs.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Can I install Liquibase on Ubuntu using apt instead of downloading the zip manually?<\/strong> Ubuntu&#8217;s default repositories don&#8217;t reliably carry the latest Liquibase releases, so downloading directly from the official GitHub releases page \u2014 as shown above \u2014 is the more dependable way to get a current, specific version when you install Liquibase on Ubuntu.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Is it safe to add the entire \/opt directory to my PATH?<\/strong> It works, but it&#8217;s broader than necessary \u2014 anything else installed under <code>\/opt<\/code> also becomes runnable by name. A symlink to just the Liquibase binary in <code>\/usr\/local\/bin<\/code> is a more scoped alternative if that matters for your setup.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>What&#8217;s the difference between Liquibase and Flyway?<\/strong> Both are database migration tools, but Liquibase supports a wider range of changelog formats (XML, YAML, JSON, and SQL) and has built-in rollback support for most change types, while Flyway is SQL-first and generally considered simpler to set up for straightforward use cases.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Introduction This guide explains how to install Liquibase on Ubuntu, an open-source database change management tool used to track, version, [&hellip;]<\/p>\n","protected":false},"author":508,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_feature_clip_id":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"jetpack_post_was_ever_published":false},"categories":[1022],"tags":[],"class_list":["post-10192","post","type-post","status-publish","format-standard","hentry","category-web-architecture","psol-cat-web-architecture"],"jetpack_publicize_connections":[],"jetpack_shortlink":"https:\/\/wp.me\/phn2x7-2Eo","jetpack_sharing_enabled":true,"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/10192","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/users\/508"}],"replies":[{"embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/comments?post=10192"}],"version-history":[{"count":3,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/10192\/revisions"}],"predecessor-version":[{"id":11072,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/10192\/revisions\/11072"}],"wp:attachment":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/media?parent=10192"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/categories?post=10192"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/tags?post=10192"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}