Categories
Articles SQL

Ubuntu 24.04 — Plesk & MSSQL 2025 Installation & Configuration Guide

 

The complete installation and configuration of Plesk and Microsoft SQL Server 2025 Preview on an Ubuntu 24.04 server.

🖥️ Ubuntu 24.04 LTS
🗄️ MSSQL 2025 Preview (17.0.1000.7)
🌐 Plesk Obsidian
🕐 Timezone: Europe/Istanbul (UTC+3)

1

System Preparation

1.1 System Update

Before starting any installation, ensure the system is fully up to date:

sudo apt update && sudo apt upgrade -y

1.2 Timezone Configuration

Set the server timezone to Turkey (Europe/Istanbul):

sudo timedatectl set-timezone Europe/Istanbul
timedatectl status

Expected output:

Time zone: Europe/Istanbul (+03, +0300)

1.3 Required Packages

sudo apt install -y curl wget gnupg2 software-properties-common apt-transport-https

2

Plesk Installation

2.1 Downloading the Plesk Installer

⚠️

Using the direct sh <(curl ...) method on Ubuntu 24.04 causes a sh: 0: cannot open /dev/fd/63 error. Download the installer to disk first instead.

Download the installer to /tmp, then execute it:

curl -o /tmp/plesk-installer https://autoinstall.plesk.com/plesk-installer
chmod +x /tmp/plesk-installer
sudo /tmp/plesk-installer

2.2 Installation Options

Select Plesk Obsidian from the interactive installer menu. Installation time varies between 10–30 minutes depending on server speed.

2.3 First Login

Once installation is complete, access the panel via browser:

https://<server-ip>:8443

ℹ️

You will be prompted to create an administrator password on first login. Choose a strong password.

2.4 Plesk License

After installation, Plesk runs with a 14-day trial license. License information can be found at Tools & Settings → License Management.

License TypeDurationNotes
Trial14 daysAll features active
Web Admin EditionPaid / AnnualLimited domains
Web Pro EditionPaid / AnnualMid-scale hosting
Web Host EditionPaid / AnnualUnlimited domains

⚠️

The trial period cannot be extended. A license must be purchased before it expires. Visit: plesk.com/pricing

3

MSSQL 2025 Preview Installation

3.1 Add Microsoft GPG Key and Repository

# Add the GPG key
curl -fsSL https://packages.microsoft.com/keys/microsoft.asc | \
  sudo gpg --dearmor -o /usr/share/keyrings/microsoft-prod.gpg

# Add the SQL Server 2025 Preview repository
curl -fsSL https://packages.microsoft.com/config/ubuntu/24.04/mssql-server-preview.list | \
  sudo tee /etc/apt/sources.list.d/mssql-server-preview.list

sudo apt update

3.2 Install SQL Server

sudo apt install -y mssql-server

3.3 Initial Configuration

sudo /opt/mssql/bin/mssql-conf setup

During the setup wizard:

StepSelection
Edition selectionInitially shows Enterprise Evaluation (can be changed later)
SA passwordSet a strong password (uppercase + lowercase + numbers + special characters)
License acceptanceYes

3.4 Start the Service and Verify

sudo systemctl start mssql-server
sudo systemctl enable mssql-server
sudo systemctl status mssql-server

If the output shows Active: active (running), the installation was successful.

3.5 Install sqlcmd Tools

# Add the sqlcmd repository
curl -fsSL https://packages.microsoft.com/config/ubuntu/24.04/prod.list | \
  sudo tee /etc/apt/sources.list.d/mssql-tools18.list

sudo apt update
sudo apt install -y mssql-tools18 unixodbc-dev

# Add to PATH
echo 'export PATH="$PATH:/opt/mssql-tools18/bin"' >> ~/.bashrc
source ~/.bashrc

3.6 Connection Test

sqlcmd -S localhost -U SA -P '<your-SA-password>' -C -Q "SELECT @@VERSION"

4

Changing MSSQL Edition — Developer Edition

ℹ️

The initial installation defaults to Enterprise Evaluation Edition (180-day trial). For development environments, switching to Developer Edition is recommended — it is free, includes all Enterprise features, but cannot be used in production.

4.1 Stop the Service

sudo systemctl stop mssql-server
sudo systemctl status mssql-server
# Should show: Active: inactive (dead)

4.2 Change the Edition

In SQL Server 2025, edition changes are made using the set-edition command:

sudo /opt/mssql/bin/mssql-conf set-edition

Select Developer from the menu that appears and confirm.

4.3 Restart the Service

sudo systemctl start mssql-server
sudo systemctl status mssql-server

4.4 Verify the Edition Change

sqlcmd -S localhost -U SA -P '<your-SA-password>' -C -Q \
  "SELECT Edition, ProductVersion, GETDATE() AS SqlServerTime FROM sys.dm_os_sys_info CROSS JOIN (SELECT SERVERPROPERTY('Edition') AS Edition, SERVERPROPERTY('ProductVersion') AS ProductVersion) AS props"

Successful output:

Edition ProductVersion SqlServerTime
———————————— ————— ———————–
Standard Developer Edition (64-bit) 17.0.1000.7 2026-08-19 14:47:47.600

Standard Developer Edition (64-bit) — Edition change completed successfully.

5

Plesk License Information

5.1 License Screen

Additional license keys are managed under Tools & Settings → License Management → Additional License Keys. This screen is empty on the trial version.

5.2 License Renewal / Purchase

MethodDescription
From Plesk PanelTools & Settings → License Management → Buy License
Plesk WebsitePurchase at plesk.com/pricing, then enter the key in the panel
Hosting ProviderSome providers bundle a Plesk license with the server package

⚠️

When the trial license expires, the panel enters restricted mode — no new domains or databases can be added. Existing sites continue to work.

6

Plesk & MSSQL Co-existence Architecture

🚫

Important Limitation: Plesk for Linux cannot add or manage MSSQL Server from its Database Servers screen. Only MariaDB / MySQL / PostgreSQL appear there. MSSQL runs as a completely independent service alongside Plesk.

6.1 Current Architecture

ComponentPortManagement Interface
Plesk Panel8443 (HTTPS)Web browser
MariaDB (Plesk)3306Plesk → Database Servers
MSSQL 20251433sqlcmd / SSMS / Azure Data Studio

6.2 Connecting to MSSQL Remotely

Open port 1433 in the firewall:

sudo ufw allow 1433/tcp
sudo ufw reload

Then connect using SQL Server Management Studio (SSMS) or Azure Data Studio on Windows:

FieldValue
Server nameserver IP or Domain,1433
AuthenticationSQL Server Authentication
LoginSA
Password<password set during installation>
Trust server certificate✅ Checked

6.3 Using MSSQL in Plesk-hosted Web Applications

A web application hosted on Plesk that needs to connect to MSSQL should use localhost,1433 or the server IP in its connection string. Plesk does not manage this connection — the application connects directly to MSSQL.

# .NET / C# example connection string
Server=localhost,1433;Database=MyDb;User Id=SA;Password=<password>;TrustServerCertificate=True;
# PHP (PDO) example
$pdo = new PDO("sqlsrv:Server=localhost,1433;Database=MyDb", "SA", "<password>");

7

MSSQL Management — Essential Commands

7.1 Service Management

# Start the service
sudo systemctl start mssql-server

# Stop the service
sudo systemctl stop mssql-server

# Restart the service
sudo systemctl restart mssql-server

# Check status
sudo systemctl status mssql-server

# Enable auto-start on boot
sudo systemctl enable mssql-server

7.2 Basic Operations with sqlcmd

# Connect
sqlcmd -S localhost -U SA -P '<password>' -C

# List databases
SELECT name FROM sys.databases;
GO

# Create a new database
CREATE DATABASE MyDatabase;
GO

# Create a user
CREATE LOGIN myuser WITH PASSWORD = 'Strong@Password123';
CREATE USER myuser FOR LOGIN myuser;
GO

# Check version and edition
SELECT @@VERSION;
SELECT SERVERPROPERTY('Edition');
GO

7.3 Log Files

# MSSQL log directory
sudo ls /var/opt/mssql/log/

# View the error log
sudo tail -100 /var/opt/mssql/log/errorlog

7.4 mssql-conf Configuration Commands

# List all settings
sudo /opt/mssql/bin/mssql-conf list

# Change edition
sudo /opt/mssql/bin/mssql-conf set-edition

# Reset SA password
sudo /opt/mssql/bin/mssql-conf set-sa-password

# Set memory limit (in MB)
sudo /opt/mssql/bin/mssql-conf set memory.memorylimitmb 4096

8

Important Notes & Warnings

#TopicDescription
1MSSQL 2025 PreviewThis version is still in Preview. It is not recommended for production use.
2Developer EditionFree of charge and includes all Enterprise features. May only be used in development/test environments — not in production.
3Plesk + MSSQLPlesk for Linux cannot manage MSSQL through its panel. Both run as independent services.
4FirewallOpen port 1433 only to trusted IP addresses. Leaving it open to the public is a security risk.
5SA AccountAvoid using the SA account directly. Create dedicated users with minimum required permissions.
6Plesk LicenseThe 14-day trial cannot be extended. Purchase a license before it expires.
7BackupsBack up MSSQL databases regularly. Plesk’s built-in backup system does not cover MSSQL.

📌

Installation Summary:
✅ Ubuntu 24.04 — Ready
✅ Timezone: Europe/Istanbul (UTC+3)
✅ Plesk Obsidian — Installed (Trial license)
✅ MSSQL 2025 Preview (17.0.1000.7) — Installed
✅ Edition: Standard Developer Edition (64-bit)
✅ sqlcmd — Installed (/opt/mssql-tools18/bin/sqlcmd)
 

 

Categories
Articles SQL Windows Server

What are the TLS supports in SQL Server?

SQL Server can support different TLS (Transport Layer Security) versions across various editions. The TLS versions supported by SQL Server may vary depending on the SQL Server version and the Windows operating system in use.

In general, SQL Server 2008 and later versions typically support TLS 1.0, TLS 1.1, and TLS 1.2. However, it’s essential to obtain the most up-to-date information from Microsoft’s official sources, as security updates and patch releases are primarily designed to address security vulnerabilities.

Below is a table illustrating the commonly supported TLS versions. Keep in mind that this information may change over time:

SQL Server VersionMin. TLS VersionMax. TLS Version
SQL Server 2008TLS 1.0TLS 1.2
SQL Server 2008 R2TLS 1.0TLS 1.2
SQL Server 2012TLS 1.0TLS 1.2
SQL Server 2014TLS 1.0TLS 1.2
SQL Server 2016TLS 1.0TLS 1.2
SQL Server 2017TLS 1.0TLS 1.2
SQL Server 2019TLS 1.2TLS 1.3*

* SQL Server 2019 may support TLS 1.3, but this is contingent on the operating system and configuration.

From a security perspective, it is recommended to use the latest version of SQL Server and keep the operating system up to date. Additionally, avoiding the use of unsupported TLS versions is crucial to prevent potential security vulnerabilities.


If you have any questions or details you would like to add, feel free to write me.

Categories
Articles Backups SQL

How many types of backups can be taken in SQL Server?

In SQL Server, backups are typically taken in four different types:

  1. Full Backup
  2. Differential Backup
  3. Transaction Log Backup
  4. File or Filegroup Backup

Let’s delve into the details of each type of backup in SQL Server:

1.Full Backup:

  • Description: A complete backup of the entire database.
  • Purpose: Provides a baseline for a complete restore of the database in case of a failure.
  • Frequency: Typically performed on a regular basis, such as daily or weekly.

2.Differential Backup :

  • Description: Captures only the data that has changed since the last full backup.
  • Purpose: Reduces the time and space required for backups by including only the changes.
  • Frequency: Can be taken between full backups to provide incremental updates.

3.Transaction Log Backup:

  • Description: Backs up the transaction log, recording changes made to the database since the last transaction log backup.
  • Purpose: Allows for point-in-time recovery and minimizes data loss.
  • Frequency: Usually taken more frequently, especially in databases with high transaction volumes.

4.File or Filegroup Backup:

  • Description: Targets specific files or filegroups within the database.
  • Purpose: Enables more granular backup and restore operations, useful for large databases.
  • Frequency: Can be used based on the need to selectively backup specific portions of the database.

These backup types collectively form a comprehensive strategy for ensuring data integrity, availability, and recoverability in SQL Server environments. The choice of which backup type(s) to use depends on factors such as the database size, recovery objectives, and the desired balance between backup frequency and resource utilization.


If you have any questions or details you would like to add, feel free to write me.

Categories
Articles Backups SQL Windows Server

How to Perform a Database Copy in SQL Server

Copying databases can often be quite useful, but knowing how to do it is crucial. In SQL Server, an easy way to copy a database is to use the “Database Copy Wizard.” Here’s how to do it using this wizard:

  1. First, open the SQL Server Management Studio (SSMS) application and connect to your SQL Server.

You can access the article where I previously explained the installation process from here.

2. In the “Databases” tab on the left, locate the database you want to copy. This is the database you’ll be duplicating.

3. Now, right-click on it and select the “Tasks” option, then click on “Copy Database” to start the Database Copy Wizard.

4. On the wizard’s initial screen, you’ll see the “Welcome to the Copy Database Wizard” message. Click “Next” to proceed.

5. On the “Select a Source Server and Database” screen, enter the name of your source SQL Server instance and, if necessary, provide authentication credentials. Then, choose the database you want to copy.

6. On the “Select a Destination Server and Database” screen, specify the name of your destination SQL Server instance and enter a new name for the copied database.

7. On the “Select Transfer Method” screen, you typically prefer to use the “Use the SQL Management Object method” option.

8. On the “Select Databases” screen, select the relevant database for the copy operation..

9. Next, on the “Configure Destination Database” screen, you can configure settings like database size, growth options, and other configurations.

10. “Configure the Package” will create an Integration Services package with your specified settings.

11. On the “Schedule and Start Copying” screen, you can choose to start the process immediately or create a scheduling plan.

12. In the final step, review the operation and click “Finish” to initiate the database copying process.

This process can take some time depending on your settings and the database’s size. Once completed, the new database will be created on the destination server.

So, you’ve successfully copied your database!


If you have any questions or details you would like to add, feel free to write me.

Categories
Articles SQL Windows

Azure Data Studio or SSMS — which should I use?

Azure Data Studio (ADS) and SQL Server Management Studio (SSMS) are both database management tools used for different purposes, and which tool to use depends on your needs and preferences.

Azure Data Studio (ADS):

Azure Data Studio (ADS):
Azure Data Studio (ADS):
  • ADS offers cross-platform support, meaning it can be used on Windows, macOS, and Linux. This can be essential for collaboration among team members using different operating systems.
  • It is primarily designed for database development and query creation. It is used for editing queries, visualizing query results, and managing databases at a high level.
  • It comes with an integrated query editor with advanced development features such as syntax highlighting, auto-completion, and code hints.
  • ADS can work with multiple database systems (SQL Server, PostgreSQL, MySQL, MongoDB, etc.) and allows you to create different connection profiles.
  • You can extend its functionality using extensions and plugins, enabling you to customize your workflow by installing or developing specific extensions.

SQL Server Management Studio (SSMS):

SQL Server Management Studio (SSMS):
  • SSMS only runs on the Windows operating system and is specifically designed for managing SQL Server. Therefore, it is recommended for those working primarily with SQL Server databases.
  • SSMS allows you to create, edit, manage, and back up database objects. It provides tools for tasks like database backup, security configuration, and performance monitoring.
  • It offers specialized reports and performance monitoring tools for professional SQL Server administration.
  • SSMS provides specialized tools and design surfaces for tasks like creating databases, writing stored procedures, and designing workflows.
  • It offers advanced monitoring and security features for database administrators.

In conclusion, the choice between Azure Data Studio (ADS) and SQL Server Management Studio (SSMS) depends on your project requirements, team member preferences, and the database system you are working with. If you have general database development and query-writing needs across various platforms, ADS might be a better fit. However, if you are primarily working with SQL Server and handling administrative tasks, SSMS is the more suitable choice. To make the best decision for your needs, consider trying out both tools and assessing which one aligns better with your workflow.


If you have any questions or details you would like to add, feel free to write me.