SQL Server fails to start on Ubuntu 22.04

Sebastian Meckovski 25 Reputation points
2024-04-18T09:23:20.59+00:00

I created a new instance of Azure VM running Ubuntu 22.04 just to reproduce this issue.

I'm following this guide to install the SQL server on my freshly deployed VM. There should be definately enough resources to run it with 8GB RAM and 2 CPU cores.

I did run sudo apt update and sudo apt dist-upgrade before proceeding.

After running sudo /opt/mssql/bin/mssql-conf setup I go through the SQL server setup journey, setting the sa password. It warns me about a missing the library.

Enter the SQL Server system administrator password:
Confirm the SQL Server system administrator password:
Configuring SQL Server...
/opt/mssql/bin/sqlservr: error while loading shared libraries: liblber-2.5.so.0: cannot open shared object file: No such file or directory
Created symlink /etc/systemd/system/multi-user.target.wants/mssql-server.service → /lib/systemd/system/mssql-server.service.
Setup has completed successfully. SQL Server is now starting.

When I try to verify that the service is running using systemctl status mssql-server --no-pagerI get the following output:


● mssql-server.service - Microsoft SQL Server Database Engine
     Loaded: loaded (/lib/systemd/system/mssql-server.service; enabled; vendor preset: enabled)
     Active: failed (Result: exit-code) since Thu 2024-04-18 09:03:08 UTC; 14s ago
       Docs: https://docs.microsoft.com/en-us/sql/linux
    Process: 8875 ExecStart=/opt/mssql/bin/sqlservr (code=exited, status=127)
   Main PID: 8875 (code=exited, status=127)

Apr 18 09:03:08 seb-linux-azure systemd[1]: mssql-server.service: Scheduled restart job, restart counter is at 4.
Apr 18 09:03:08 seb-linux-azure systemd[1]: Stopped Microsoft SQL Server Database Engine.
Apr 18 09:03:08 seb-linux-azure systemd[1]: mssql-server.service: Start request repeated too quickly.
Apr 18 09:03:08 seb-linux-azure systemd[1]: mssql-server.service: Failed with result 'exit-code'.
Apr 18 09:03:08 seb-linux-azure systemd[1]: Failed to start Microsoft SQL Server Database Engine.

Is this something very recent that Microsoft hasn't updated in their docs or am I missing something? It certainly wasn't an issue when I tried to do the same on IBM virtual machines about a week ago.

Let me know if further details are required and which command I need to get them, as I'm fairly new to Linux.

Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
7,145 questions
SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
12,738 questions
{count} votes

Accepted answer
  1. kobulloc-MSFT 23,491 Reputation points Microsoft Employee
    2024-04-18T16:58:01.53+00:00

    Hello, @Sebastian Meckovski !

    I'm glad that you were able to resolve your issue and thank you for posting your solution so that others experiencing the same thing can easily reference this! Since the Microsoft Q&A community has a policy that "The question author cannot accept their own answer. They can only accept answers by others ", I'll repost your solution in case you'd like to "Accept " the answer.

    Issue:

    SQL Server fails to start on Ubuntu 22.04 while following the Install SQL Server and create a database on Ubuntu quickstart.

    Solution (from Sebastian Meckovski):

    Wait! I just realized I was on Ubuntu 20.04 while following the guide for 22.04. I reproduced the same steps on 22.04 and all works fine. Apologies for the false alarm!

    Please take a moment to accept answers as this helps increase visibility of this question for other members of the Microsoft Q&A community. Thank you for helping to improve Microsoft Q&A!

    User's image

    1 person found this answer helpful.
    0 comments No comments

0 additional answers

Sort by: Most helpful