How to Install Microsoft SQL Server on Debian 12
Introduction
Microsoft SQL Server is a powerful relational database management system used by many organizations worldwide. Installing SQL Server on Debian 12 allows you to leverage its features for your applications and data storage needs. In this guide, we'll walk you through the step-by-step process of installing Microsoft SQL Server on Debian 12.
Prerequisites
Before you begin, make sure you have the following:
- A Debian 12 system with sudo privileges
- A stable internet connection
Step 1: Import the Microsoft SQL Server Repository GPG Key
First, you need to import the Microsoft SQL Server repository GPG key using the following command:
wget -qO- https://packages.microsoft.com/keys/microsoft.asc | sudo apt-key add -
Step 2: Add the Microsoft SQL Server Repository
Next, add the Microsoft SQL Server repository to your Debian system:
sudo add-apt-repository "$(wget -qO- https://packages.microsoft.com/config/ubuntu/$(lsb_release -rs)/mssql-server-2019.list)"
Step 3: Install Microsoft SQL Server
Now, update the package index and install Microsoft SQL Server:
sudo apt-get update
sudo apt-get install -y mssql-server
Step 4: Configure Microsoft SQL Server
After the installation is complete, run the configuration script and follow the prompts to set up Microsoft SQL Server:
sudo /opt/mssql/bin/mssql-conf setup
Step 5: Start and Enable the SQL Server Service
Finally, start the SQL Server service and enable it to automatically start on system boot:
sudo systemctl start mssql-server
sudo systemctl enable mssql-server
Conclusion
Congratulations! You've successfully installed Microsoft SQL Server on Debian 12. You can now start using SQL Server to manage your databases and perform various data operations on your Debian system.