SQLite is a widely used, lightweight, and cross-platform database engine. Unlike traditional client-server databases, SQLite is serverless and self-contained, making it ideal for applications requiring an embedded database. In this guide, we’ll walk through the process of installing SQLite3 on AlmaLinux 9.
Prerequisites
- AlmaLinux 9 installed.
- Root access or administrative privileges.
Step 1: Update Your System
Before installing any new packages, ensure your system is fully updated by running:
dnf update -y
Step 2: Install wget
To download the SQLite source code, you’ll need the wget
utility. If it’s not already installed, add it with:
dnf install wget -y
Step 3: Install Development Tools
To compile SQLite from source, you’ll need a set of development tools such as GCC, make, and tar. Install these tools by running:
dnf groupinstall "Development Tools" -y
Step 4: Download and Extract SQLite Source Code
Visit the SQLite download page and find the latest version of the autoconf source code, named something like sqlite-autoconf-.tar.gz
.
Download the source file using wget
, and extract it with:
wget https://www.sqlite.org/2023/sqlite-autoconf-3420000.tar.gz
tar xvfz sqlite-autoconf-3420000.tar.gz
Rename the extracted folder for ease of use and navigate into it:
mv sqlite-autoconf-3420000 sqlite
cd sqlite
Step 5: Compile and Install SQLite3
Compile and install SQLite3 using the following commands:
./configure
make
make install
Step 6: Confirm the Installation
To verify that SQLite3 was installed correctly, check its version:
sqlite3 --version
If everything is set up properly, you should see an output similar to:
3.42.0 2023-05-16 12:36:15 831d0fb2836b71c9bc51067c49fee4b8f18047814f24422d817d25195cf350b0
Conclusion
And there you have it! SQLite3 is now installed on your AlmaLinux 9 system. This versatile and lightweight database engine is ready to be used in your applications.