SQL Server on Linux: Why Do I Have Two SQL Server Processes?

Moved from: bobsql.com


When starting SQL Server on Linux why are there two (2) sqlservr processes?


systemctl status mssql-server
mssql-server.service – Microsoft SQL Server Database Engine

   CGroup: /system.slice/mssql-server.service
           ├─85829 /opt/mssql/bin/sqlservr       <——— WATCHDOG | MONITOR
           └─85844 /opt/mssql/bin/sqlservr       <——— SQLSERVER.EXE

The simple answer is the first entry (85829) is not what you are used to on a Windows system as sqlservr.exe and does not listen for TDS traffic or open database files.  The parent process handles basic configuration activities and then forks the child process.  The parent process (WATCHDOG) becomes a lightweight monitor and the child process runs the sqlservr.exe process.