SQLLocalDB doesn't start and throws an error as below.
**C:\Windows\system32>sqllocaldb c MSSQLLocalDB**
Creation of LocalDB instance "MSSQLLocalDB" failed because of the following error:
Error occurred during LocalDB instance startup: SQL Server process failed to start.
***Note:*** Command started with Run as Administrator.
Event viewer shows below log:
Windows API call WaitForMultipleObjects returned error code: 575. Windows system error message is: {Application Error}
The application was unable to start correctly (0x%lx). Click OK to close the application.
Reported at line: 3714.
Source: SQLLocalDB 15.0
Event ID: 528
Level: Error
Operating system: Windows 11 Pro build 22000.832
Version installed: Microsoft SQL Server 2019 (15.0.4153.1)
While connecting SQLLocalDB from Visual Studio 2022 version 17.2.6, it shows below message:
TITLE: Error
A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 50 - Local Database Runtime error occurred. Error occurred during LocalDB instance startup: SQL Server process failed to start.
) (Microsoft SQL Server, Error: -1983577846)
For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft%20SQL%20Server&EvtSrc=MSSQLServer&EvtID=-1983577846&LinkId=20476
------------------------------
Error Number: -1983577846
Severity: 20
State: 0
Below is detail from file <error.log>:
2022-07-28 12:13:11.50 Server Microsoft SQL Server 2019 (RTM-CU12) (KB5004524) - 15.0.4153.1 (X64)
Jul 19 2021 15:37:34
Copyright (C) 2019 Microsoft Corporation
Express Edition (64-bit) on Windows 10 Pro 10.0 <X64> (Build 22000: )
2022-07-28 12:13:11.50 Server UTC adjustment: 5:30
2022-07-28 12:13:11.50 Server (c) Microsoft Corporation.
2022-07-28 12:13:11.50 Server All rights reserved.
2022-07-28 12:13:11.50 Server Server process ID is 10072.
2022-07-28 12:13:11.50 Server System Manufacturer: 'LENOVO', System Model: '82KB'.
2022-07-28 12:13:11.50 Server Authentication mode is MIXED.
2022-07-28 12:13:11.50 Server Logging SQL Server messages in file 'C:\Users\<user>\AppData\Local\Microsoft\Microsoft SQL Server Local DB\Instances\MSSQLLocalDB\error.log'.
2022-07-28 12:13:11.50 Server The service account is '<domain\user>'. This is an informational message; no user action is required.
2022-07-28 12:13:11.50 Server Command Line Startup Parameters:
-c
-S "MSSQL15E.LOCALDB"
-s "LOCALDB#C0C8C320"
-d "C:\Users\<user>\AppData\Local\Microsoft\Microsoft SQL Server Local DB\Instances\MSSQLLocalDB\master.mdf"
-l "C:\Users\<user>\AppData\Local\Microsoft\Microsoft SQL Server Local DB\Instances\MSSQLLocalDB\mastlog.ldf"
-e "C:\Users\<user>\AppData\Local\Microsoft\Microsoft SQL Server Local DB\Instances\MSSQLLocalDB\error.log"
2022-07-28 12:13:11.51 Server SQL Server detected 1 sockets with 4 cores per socket and 8 logical processors per socket, 8 total logical processors; using 8 logical processors based on SQL Server licensing. This is an informational message; no user action is required.
2022-07-28 12:13:11.51 Server SQL Server is starting at normal priority base (=7). This is an informational message only. No user action is required.
2022-07-28 12:13:11.51 Server Detected 16183 MB of RAM. This is an informational message; no user action is required.
2022-07-28 12:13:11.51 Server Using conventional memory in the memory manager.
2022-07-28 12:13:11.51 Server Page exclusion bitmap is enabled.
2022-07-28 12:13:11.64 Server Buffer Pool: Allocating 2097152 bytes for 1740277 hashPages.
2022-07-28 12:13:11.66 Server Default collation: SQL_Latin1_General_CP1_CI_AS (us_english 1033)
2022-07-28 12:13:11.67 Server Buffer pool extension is already disabled. No action is necessary.
2022-07-28 12:13:11.70 Server Query Store settings initialized with enabled = 1,
2022-07-28 12:13:11.70 Server The maximum number of dedicated administrator connections for this instance is '1'
2022-07-28 12:13:11.70 Server Node configuration: node 0: CPU mask: 0x00000000000000ff:0 Active CPU mask: 0x00000000000000ff:0. This message provides a description of the NUMA configuration for this computer. This is an informational message only. No user action is required.
2022-07-28 12:13:11.70 Server Using dynamic lock allocation. Initial allocation of 2500 Lock blocks and 5000 Lock Owner blocks per node. This is an informational message only. No user action is required.
2022-07-28 12:13:11.71 Server In-Memory OLTP initialized on standard machine.
2022-07-28 12:13:11.71 Server [INFO] Created Extended Events session 'hkenginexesession'
2022-07-28 12:13:11.71 Server Database Instant File Initialization: disabled. For security and performance considerations see the topic 'Database Instant File Initialization' in SQL Server Books Online. This is an informational message only. No user action is required.
2022-07-28 12:13:11.72 Server Total Log Writer threads: 2. This is an informational message; no user action is required.
2022-07-28 12:13:11.73 Server clwb is selected for pmem flush operation.
2022-07-28 12:13:11.73 Server Software Usage Metrics is disabled.
2022-07-28 12:13:11.74 spid9s Starting up database 'master'.
2022-07-28 12:13:11.75 spid9s There have been 256 misaligned log IOs which required falling back to synchronous IO. The current IO is on file C:\Users\<user>\AppData\Local\Microsoft\Microsoft SQL Server Local DB\Instances\MSSQLLocalDB\master.mdf.
Tried so far: I have tried removing SSIS, VS, Registry keys, folders etc. Even I install clean Windows 11 again to avoid this issue of residual files /registry post uninstall.
My domain account is already in administrator groups on this computer. But I have also added into sysadmin additionally. Folder already has enough permission where MDF files are there.
c
switch creates a new instance. To start an existing one, uses
instead. Also, I highly recommend to avoid any elevation of privileges when dealing with LocalDB instances. They are per-user instances by default, and as such, don't require UAC elevation. – Paradigmerror.log
? – Taliafsutil fsinfo ntfsinfo C:\
? Seems like you're on a hybrid disk that uses 4096 byte sectors natively while reporting 512 byte sectors to the operating system. Since you're on CU12 it seems like you need to install KB5011644 - Cumulative Update 16 for SQL Server 2019. – Topliffe