I'm facing an issue when importing a database to my LocalDB instance. The .bacpac file is an export of my production database and is 1GB in size.
Error SQL72016: Could not allocate a new page for database 'xxxxxx' because of insufficient disk space in filegroup 'PRIMARY'. Create the necessary space by dropping objects in the filegroup, adding additional files to the filegroup, or setting autogrowth on for existing files in the filegroup.
The statement has been terminated.
I think the problem is that the log file is limited to 2GB and has autogrowth disabled. When re-enabling indexes, the log file size needs to be able to grow beyond that limit but it fails.
I've tried to following:
Anyone had success with restoring a large database locally?
What seems to work is install SQL Server, not use Local DB or SQL Server Express. The Developer Edition is good enough for local use. The import succeeded.
Your question is probably more suited to StackOverflow or an mssql forum.
However, based on the information you have provided see the issue here.