{"id":2080,"date":"2024-04-24T00:22:06","date_gmt":"2023-11-10T16:22:30","guid":{"rendered":""},"modified":"2025-02-02T00:46:18","modified_gmt":"2025-02-01T23:46:18","slug":"how-to-install-microsoft-sql-server-on-debian-12","status":"publish","type":"post","link":"https:\/\/netcloud24.com\/knowledgebase\/how-to-install-microsoft-sql-server-on-debian-12\/","title":{"rendered":"Linux VPS &#038; VPS Windows Setup Guide | NetCloud24 Microsoft SQL Server on Debian 12"},"content":{"rendered":"<p>\u00a0<\/p>\n<\/p>\n<header>\n<h1>\u00a0<\/h1>\n<\/header>\n<article>\n<p><strong>Microsoft SQL Server<\/strong> is a powerful relational database management system (RDBMS) widely used for enterprise-grade database applications. Though it&#8217;s traditionally associated with Windows, SQL Server can also be installed on Linux distributions like Debian. In this guide, we will walk you through how to install Microsoft SQL Server on <strong>Debian 12<\/strong>. Hosting SQL Server on a  ensures better performance and scalability using the dedicated resources of a <strong>VPS server<\/strong>.<\/p>\n<h2>Step 1: Update Your VPS Server<\/h2>\n<p>Before installing SQL Server, ensure that your <a href=\"https:\/\/ie.netcloud24.com\">VPS server<\/a> is up to date. Run the following commands to update your Debian system:<\/p>\n<pre><code>sudo apt update &amp;&amp; sudo apt upgrade -y<\/code><\/pre>\n<p>By using a <strong>Windows VPS<\/strong>, you can take advantage of dedicated CPU, memory, and storage resources, ensuring your SQL Server installation performs optimally, even for high-demand database applications.<\/p>\n<h2>Step 2: Import the Microsoft GPG Key<\/h2>\n<p>Microsoft provides official repositories for installing SQL Server on Linux. First, you need to import the Microsoft GPG key:<\/p>\n<pre><code>\r\nwget -qO- https:\/\/packages.microsoft.com\/keys\/microsoft.asc | sudo tee \/etc\/apt\/trusted.gpg.d\/microsoft.asc\r\n<\/code><\/pre>\n<h2>Step 3: Add the SQL Server Repository<\/h2>\n<p>Next, add the SQL Server repository for Debian 12 by running the following commands:<\/p>\n<pre><code>\r\nsudo add-apt-repository \"$(wget -qO- https:\/\/packages.microsoft.com\/config\/debian\/12\/prod.list)\"\r\n<\/code><\/pre>\n<p>Update the package list after adding the repository:<\/p>\n<pre><code>sudo apt update<\/code><\/pre>\n<h2>Step 4: Install Microsoft SQL Server<\/h2>\n<p>Now, you can install Microsoft SQL Server using the following command:<\/p>\n<pre><code>sudo apt install -y mssql-server<\/code><\/pre>\n<p>After the installation is complete, run the following command to start the setup process:<\/p>\n<pre><code>sudo \/opt\/mssql\/bin\/mssql-conf setup<\/code><\/pre>\n<p>During the setup, you will be prompted to choose the SQL Server edition (e.g., Evaluation, Developer, Express) and set the <strong>SA<\/strong> (system administrator) password. Choose the edition that best suits your needs and make sure to set a strong SA password.<\/p>\n<h2>Step 5: Verify SQL Server Installation<\/h2>\n<p>Once the setup is complete, verify that SQL Server is running by checking the service status:<\/p>\n<pre><code>systemctl status mssql-server --no-pager<\/code><\/pre>\n<p>If the service is running, you should see output indicating that the <strong>mssql-server<\/strong> service is active.<\/p>\n<h2>Step 6: Install SQL Server Tools (Optional)<\/h2>\n<p>To interact with SQL Server, you can install the SQL Server command-line tools such as <code>sqlcmd<\/code> and <code>bcp<\/code>. First, add the Microsoft repository for SQL Server tools:<\/p>\n<pre><code>\r\nsudo add-apt-repository \"$(wget -qO- https:\/\/packages.microsoft.com\/config\/debian\/12\/prod.list)\"\r\nsudo apt update\r\n<\/code><\/pre>\n<p>Then install the tools with:<\/p>\n<pre><code>sudo apt install mssql-tools unixodbc-dev -y<\/code><\/pre>\n<p>To make the tools accessible from any location, add them to your <code>PATH<\/code> environment variable:<\/p>\n<pre><code>\r\necho 'export PATH=\"$PATH:\/opt\/mssql-tools\/bin\"' &gt;&gt; ~\/.bashrc\r\nsource ~\/.bashrc\r\n<\/code><\/pre>\n<h2>Step 7: Allow Remote Connections (Optional)<\/h2>\n<p>If you want to access SQL Server remotely, you need to open the necessary ports. SQL Server typically listens on port <code>1433<\/code> by default. Allow traffic on this port using the following firewall commands:<\/p>\n<pre><code>\r\nsudo ufw allow 1433\/tcp\r\nsudo ufw reload\r\n<\/code><\/pre>\n<h2>Step 8: Optimize Your VPS Server for SQL Server<\/h2>\n<p>Running Microsoft SQL Server on a  allows you to leverage the dedicated resources of a <strong>VPS server<\/strong> for your database applications. A VPS provides better performance, especially when dealing with high-concurrency transactions, large databases, and mission-critical applications. As your database grows, you can scale your VPS resources, ensuring that SQL Server continues to perform efficiently under heavy workloads.<\/p>\n<h2>Conclusion<\/h2>\n<p>Installing Microsoft SQL Server on Debian 12 allows you to take advantage of a powerful relational database system on a Linux environment. Hosting SQL Server on a  ensures your database has the performance, scalability, and reliability needed for enterprise-grade applications.<\/p>\n<p>For more information about VPS hosting and optimizing your SQL Server setup, visit  today.<\/p>\n<\/article>\n<footer>\n<p>\u00a9 2024 Windows VPS &#8211; All Rights Reserved<\/p>\n<\/footer>\n<div class=\"post-author-box\" style=\"border-top:1px solid #ddd;margin-top:20px;padding-top:15px;\">\n<p><strong>Author:<\/strong> \u0141ukasz Bodziony<\/p>\n<p><strong>Website:<\/strong> <a href=\"https:\/\/ca.netcloud24.com\" target=\"_blank\" rel=\"dofollow\">Windows VPS<\/a><\/p>\n<p><em>\u0141ukasz Bodziony is the CEO and founder of <a href=\"https:\/\/netcloud24.com\" target=\"_blank\" rel=\"dofollow\">NETCLOUD24<\/a>, a global VPS hosting brand proudly originating from Poland. With extensive experience in cloud computing, virtualization, and server management, he delivers high-performance <strong>Windows VPS<\/strong> and <strong>Remote Desktop Services (RDS)<\/strong> solutions to clients across Europe, North America, and beyond.<\/em><\/p>\n<p><em>His expertise covers a wide range of technologies, including <strong>Microsoft Azure<\/strong>, <strong>Proxmox VE<\/strong>, <strong>Amazon Web Services (AWS)<\/strong>, and numerous other virtualization and cloud platforms.<\/em><\/p>\n<p><em>Beyond running his hosting business, \u0141ukasz also provides <strong>professional paid server configuration and optimization services<\/strong> for companies and individuals. Outside of work, he is dedicated to caring for his children and building a secure future for them.<\/em><\/p>\n<p><em>If you are interested in working with him or need expert assistance with your hosting, cloud environment, or server setup, feel free to reach out via <a href=\"https:\/\/ca.netcloud24.com\" target=\"_blank\" rel=\"dofollow\">Windows VPS<\/a>.<\/em><\/p>\n<\/p><\/div>\n","protected":false},"excerpt":{"rendered":"<p>\u00a0 \u00a0 Microsoft SQL Server is a powerful relational database management system (RDBMS) widely used for enterprise-grade database applications. Though it&#8217;s traditionally associated with Windows, SQL Server can\u2026<\/p>\n","protected":false},"author":1,"featured_media":3421,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_seopress_robots_primary_cat":"","_seopress_titles_title":"","_seopress_titles_desc":"","_seopress_robots_index":"","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}},"categories":[],"tags":[14,12,11,23,20,21,22,17,7,8,6,10,18,19,15,24,16,5,13,9],"class_list":["post-2080","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","tag-cheapvps","tag-cloudvps","tag-hostingvps","tag-rds","tag-rdscal","tag-remotedesktop","tag-remotedesktopvps","tag-servervps","tag-ukvps","tag-virtualserver","tag-vpshosting","tag-vpsserver","tag-vpssolutions","tag-vpswindows","tag-vpswithwindows","tag-windowsrds","tag-windowsserver","tag-windowsvps","tag-windowsvpshosting","tag-windowsvpsuk"],"jetpack_publicize_connections":[],"_links":{"self":[{"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/posts\/2080","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/comments?post=2080"}],"version-history":[{"count":0,"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/posts\/2080\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/media\/3421"}],"wp:attachment":[{"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/media?parent=2080"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/categories?post=2080"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/netcloud24.com\/knowledgebase\/wp-json\/wp\/v2\/tags?post=2080"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}