Unable to restore database with in-memory optimized tables into mssql docker container

Ivan Minchev 1 Reputation point
2022-06-30T04:09:13.847+00:00

Hi,
I'm running mcr.microsoft.com/mssql/server docker image on macOS 12.4.
My simple docker-compose.yml:
---
version: '3.9'

services:  
  sqlserver:  
    image: mcr.microsoft.com/mssql/server  
    container_name: MsSqlServer  
    environment:  
      SA_PASSWORD: "MySuperSecretPWD"  
      ACCEPT_EULA: "Y"  
    ports:  
      - "1433:1433"  
    volumes:  
      - dbData:/var/opt/mssql  
volumes:  
  dbData:  

---

When I try to restore a backup that contains in-memory optimized tables I receive the following error:

Msg 3634, Level 16, State 1, Server 20b03f9dce7e, Line 1
The operating system returned the error '(null)' while attempting 'CreateFileW' on '/var/opt/mssql/data/Core_Orig_memory.ndf/$FSLOG/fffff385-ffff5771-fff0.00000c7a-0000a88e-0009.1d601ff6-c0d7-4e63-b294-7bd0c551d04f~0bf3f7b5-ec86-41ba-8d88-539d15c56246~00000c7a-0000a88e-0009.2630bf-0.1000011'.

I opened a shell in the container and I could create a file manually at that location with that name as a mssql user so it doesn't seem to be a permissions issue.
Any ideas how to proceed with the troubleshooting are greatly appreciated.

Thanks!

SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
8,562 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Seeya Xi-MSFT 12,746 Reputation points Microsoft Employee
    2022-07-01T07:12:21.453+00:00

    Hi @Ivan Minchev ,

    Welcome to Microsoft Q&A!
    The restore activity may fail due to out-of-memory errors. It is recommended to configure a dedicated resource pool for In-Memory optimized database. In general, there would be a need of 3 * the size of the durable memory-optimized memory for the successful database restores operation. It is recommended test the backup and restore procedures in your environment.
    Please refer to these links:
    Restore and recovery of memory-optimized tables
    Resolve Out Of Memory issues
    In-Memory Optimized database backup and restore in SQL Server

    Best regards,
    Seeya


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    No comments