containers / fuse-overlayfs

FUSE implementation for overlayfs
GNU General Public License v2.0
524 stars 84 forks source link

Error running MSSQL image #167

Closed abitrolly closed 4 years ago

abitrolly commented 4 years ago

/kind bug Description

I needed to run this image to port this app to another DB. Using officially provided docker command didn't work.

Click to expand
✗ podman run -e 'ACCEPT_EULA=Y' -e 'SA_PASSWORD=yourStrong(!)Password' -p 1433:1433 -it mcr.microsoft.com/mssql/server:2017-CU8-ubuntu 
Trying to pull mcr.microsoft.com/mssql/server:2017-CU8-ubuntu...
Getting image source signatures
Copying blob 5594e4e5950b done  
Copying blob b70745c852a2 done  
Copying blob 4fa80d7b805d done  
Copying blob 484dd0f2fbdc done  
Copying blob 718060832ef2 done  
Copying blob 47004b22ec62 done  
Copying blob 7d648891de3f done  
Copying blob 5b67719e2956 done  
Copying blob e0d1b3db20c8 done  
Copying blob ded313a21911 done  
Copying config 229d30f7b4 done  
Writing manifest to image destination
Storing signatures
^[  2020-01-13 14:08:10.45 Server      Setup step is copying system data file 'C:\templatedata\master.mdf' to '/var/opt/mssql/data/master.mdf'.
2020-01-13 14:08:10.55 Server      Did not find an existing master data file /var/opt/mssql/data/master.mdf, copying the missing default master and other system database files. If you have moved the database location, but not moved the database files, startup may fail. To repair: shutdown SQL Server, move the master database to configured location, and restart.
2020-01-13 14:08:10.55 Server      Setup step is copying system data file 'C:\templatedata\mastlog.ldf' to '/var/opt/mssql/data/mastlog.ldf'.
2020-01-13 14:08:10.56 Server      Setup step is copying system data file 'C:\templatedata\model.mdf' to '/var/opt/mssql/data/model.mdf'.
2020-01-13 14:08:10.59 Server      Setup step is copying system data file 'C:\templatedata\modellog.ldf' to '/var/opt/mssql/data/modellog.ldf'.
2020-01-13 14:08:10.61 Server      Setup step is copying system data file 'C:\templatedata\msdbdata.mdf' to '/var/opt/mssql/data/msdbdata.mdf'.
2020-01-13 14:08:10.65 Server      Setup step is copying system data file 'C:\templatedata\msdblog.ldf' to '/var/opt/mssql/data/msdblog.ldf'.
2020-01-13 14:08:10.80 Server      Microsoft SQL Server 2017 (RTM-CU8) (KB4338363) - 14.0.3029.16 (X64) 
    Jun 13 2018 13:35:56 
    Copyright (C) 2017 Microsoft Corporation
    Developer Edition (64-bit) on Linux (Ubuntu 16.04.4 LTS)
2020-01-13 14:08:10.80 Server      UTC adjustment: 0:00
2020-01-13 14:08:10.80 Server      (c) Microsoft Corporation.
2020-01-13 14:08:10.80 Server      All rights reserved.
2020-01-13 14:08:10.80 Server      Server process ID is 4124.
2020-01-13 14:08:10.80 Server      Logging SQL Server messages in file '/var/opt/mssql/log/errorlog'.
2020-01-13 14:08:10.80 Server      Registry startup parameters: 
     -d /var/opt/mssql/data/master.mdf
     -l /var/opt/mssql/data/mastlog.ldf
     -e /var/opt/mssql/log/errorlog
2020-01-13 14:08:10.81 Server      SQL Server detected 1 sockets with 2 cores per socket and 4 logical processors per socket, 4 total logical processors; using 4 logical processors based on SQL Server licensing. This is an informational message; no user action is required.
2020-01-13 14:08:10.81 Server      SQL Server is starting at normal priority base (=7). This is an informational message only. No user action is required.
2020-01-13 14:08:10.81 Server      Detected 6129 MB of RAM. This is an informational message; no user action is required.
2020-01-13 14:08:10.81 Server      Using conventional memory in the memory manager.
2020-01-13 14:08:11.09 Server      Buffer pool extension is already disabled. No action is necessary. 
2020-01-13 14:08:11.22 Server      InitializeExternalUserGroupSid failed. Implied authentication will be disabled.
2020-01-13 14:08:11.22 Server      Implied authentication manager initialization failed. Implied authentication will be disabled.
2020-01-13 14:08:11.22 Server      Successfully initialized the TLS configuration. Allowed TLS protocol versions are ['1.0 1.1 1.2']. Allowed TLS ciphers are ['ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES128-SHA256:ECDHE-ECDSA-AES256-SHA384:ECDHE-ECDSA-AES256-SHA:ECDHE-ECDSA-AES128-SHA:AES256-GCM-SHA384:AES128-GCM-SHA256:AES256-SHA256:AES128-SHA256:AES256-SHA:AES128-SHA:!DHE-RSA-AES256-GCM-SHA384:!DHE-RSA-AES128-GCM-SHA256:!DHE-RSA-AES256-SHA:!DHE-RSA-AES128-SHA'].
2020-01-13 14:08:11.26 Server      The maximum number of dedicated administrator connections for this instance is '1'
2020-01-13 14:08:11.26 Server      Node configuration: node 0: CPU mask: 0x000000000000000f:0 Active CPU mask: 0x000000000000000f:0. This message provides a description of the NUMA configuration for this computer. This is an informational message only. No user action is required.
2020-01-13 14:08:11.27 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.
2020-01-13 14:08:11.28 Server      In-Memory OLTP initialized on lowend machine.
2020-01-13 14:08:11.35 Server      Database Instant File Initialization: enabled. 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.
ForceFlush is enabled for this instance. 
2020-01-13 14:08:11.36 Server      Query Store settings initialized with enabled = 1, 
2020-01-13 14:08:11.36 spid6s      Starting up database 'master'.
2020-01-13 14:08:11.37 Server      Software Usage Metrics is disabled.
ForceFlush feature is enabled for log durability.
2020-01-13 14:08:11.65 spid6s      The tail of the log for database master is being rewritten to match the new sector size of 4096 bytes.  3072 bytes at offset 418816 in file /var/opt/mssql/data/mastlog.ldf will be written.
2020-01-13 14:08:11.65 spid6s      Error: 17053, Severity: 16, State: 1.
2020-01-13 14:08:11.65 spid6s      FCB::ZeroFile(), GetOverLappedResult(): Operating system error 997(Overlapped I/O operation is in progress.) encountered.
2020-01-13 14:08:11.65 spid6s      Cannot recover the master database. SQL Server is unable to run. Restore master from a full backup, repair it, or rebuild it. For more information about how to rebuild the master database, see SQL Server Books Online.
  

I couldn't find any references of application error in image tracker https://github.com/microsoft/mssql-docker/search?q=Cannot+recover+the+master+database.+SQL+Server+is+unable+to+run.+&type=Issues and concluded that the error is caused by the podman itself.

Output of podman version:

Version:            1.7.0
RemoteAPI Version:  1
Go Version:         go1.13.5
OS/Arch:            linux/amd64
giuseppe commented 4 years ago

that error is coming from the container, so it can't be Podman.

Are you running as root or rootless?

In the second case it could be the interaction with fuse-overlayfs

giuseppe commented 4 years ago

in general I don't think you want your DB to use a FUSE file system or even overlay. It is better to use a volume

abitrolly commented 4 years ago

Are you running as root or rootless?

Without sudo.

abitrolly commented 4 years ago

When it will possibly be released?

rhatdan commented 4 years ago

We have one outstanding PR, and then @giuseppe can cut a release. Of course depending on the distro, it may take time to get to you.

abitrolly commented 4 years ago

https://bodhi.fedoraproject.org/updates/FEDORA-2020-412314100c

I can confirm this is fixed. Awesome. )

rhatdan commented 4 years ago

@giuseppe Can we get a new package onto Fedora 31?

giuseppe commented 4 years ago

It should already be on bodhi