dotnet / efcore

EF Core is a modern object-database mapper for .NET. It supports LINQ queries, change tracking, updates, and schema migrations.
https://docs.microsoft.com/ef/
MIT License
13.73k stars 3.17k forks source link

.Net5.0.8 sqlite connection to database Segmentation fault #25453

Closed ganxw closed 2 years ago

ganxw commented 3 years ago

.Net version 5.0.8 ubuntu version 18.04 arch arm64 depend lib spatialte5.0.1
-rwxr-xr-x 1 root root 1074 ?? 8 21:10 mod_spatialite.la lrwxrwxrwx 1 root root 23 ?? 8 21:10 mod_spatialite.so -> mod_spatialite.so.7.1.0 lrwxrwxrwx 1 root root 23 ?? 8 21:10 mod_spatialite.so.7 -> mod_spatialite.so.7.1.0 -rwxr-xr-x 1 root root 19011120 ?? 8 21:10 mod_spatialite.so.7.1.0

error info: [21:20:07 DBG] Connection id "0HMAQDST0LTD0" completed keep alive response. [21:20:07 INF] Request finished HTTP/1.1 GET http://192.168.0.6/swagger/v1/swagger.json - - - 200 - application/json;+charset=utf-8 5377.0862ms [21:20:17 INF] Request starting HTTP/1.1 POST http://192.168.0.6/api/Home/Login application/json 66 [21:20:17 VRB] All hosts are allowed. [21:20:17 DBG] The request has an origin header: 'http://192.168.0.6'. [21:20:17 INF] CORS policy execution successful. [21:20:17 DBG] Connection id "0HMAQDST0LTD0", Request id "0HMAQDST0LTD0:00000004": started reading request body. [21:20:17 DBG] Connection id "0HMAQDST0LTD0", Request id "0HMAQDST0LTD0:00000004": done reading request body. [21:20:17 DBG] POST requests are not supported [21:20:17 DBG] 1 candidate(s) found for the request path '/api/Home/Login' [21:20:17 DBG] Endpoint 'CellCounter.Api.Controllers.HomeController.Login (CellCounter.Api)' with route pattern 'api/Home/Login' is valid for the request path '/api/Home/Login' [21:20:17 DBG] Request matched endpoint 'CellCounter.Api.Controllers.HomeController.Login (CellCounter.Api)' [21:20:17 DBG] AuthenticationScheme: Bearer was not authenticated. [21:20:17 INF] Executing endpoint 'CellCounter.Api.Controllers.HomeController.Login (CellCounter.Api)' [21:20:17 DBG] Registered model binder providers, in the following order: ["Microsoft.AspNetCore.Mvc.ModelBinding.Binders.BinderTypeModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.ServicesModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.BodyModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.HeaderModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.FloatingPointTypeModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.EnumTypeModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.DateTimeModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.SimpleTypeModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.CancellationTokenModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.ByteArrayModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.FormFileModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.FormCollectionModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.KeyValuePairModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.DictionaryModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.ArrayModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.CollectionModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.ComplexObjectModelBinderProvider"] [21:20:17 INF] Route matched with {action = "Login", controller = "Home"}. Executing controller action with signature System.Threading.Tasks.Task1[CellCounter.Util.AjaxResult1[CellCounter.Api.Model.Home_LoginResponse]] Login(CellCounter.Api.Model.Home_LoginRequest) on controller CellCounter.Api.Controllers.HomeController (CellCounter.Api). [21:20:17 DBG] Execution plan of authorization filters (in the following order): ["None"] [21:20:17 DBG] Execution plan of resource filters (in the following order): ["None"] [21:20:17 DBG] Execution plan of action filters (in the following order): ["Microsoft.AspNetCore.Mvc.ModelBinding.UnsupportedContentTypeFilter (Order: -3000)", "CellCounter.Api.ValidFilterAttribute", "CellCounter.Api.GlobalExceptionFilter", "CellCounter.Api.FormatResponseAttribute"] [21:20:17 DBG] Execution plan of exception filters (in the following order): ["CellCounter.Api.GlobalExceptionFilter"] [21:20:17 DBG] Execution plan of result filters (in the following order): ["Microsoft.AspNetCore.Mvc.Infrastructure.ClientErrorResultFilter (Order: -2000)"] [21:20:17 DBG] Executing controller factory for controller CellCounter.Api.Controllers.HomeController (CellCounter.Api) [21:20:18 DBG] An 'IServiceProvider' was created for internal use by Entity Framework. [21:20:19 INF] Entity Framework Core 5.0.4 initialized 'GenericDbContext' using provider 'Microsoft.EntityFrameworkCore.Sqlite' with options: LoadSpatialite using NetTopologySuite [21:20:20 DBG] Executed controller factory for controller CellCounter.Api.Controllers.HomeController (CellCounter.Api) [21:20:20 DBG] Attempting to bind parameter 'para' of type 'CellCounter.Api.Model.Home_LoginRequest' ... [21:20:20 DBG] Attempting to bind parameter 'para' of type 'CellCounter.Api.Model.Home_LoginRequest' using the name '' in request data ... [21:20:20 DBG] Rejected input formatter 'Microsoft.AspNetCore.Mvc.Formatters.NewtonsoftJsonPatchInputFormatter' for content type 'application/json'. [21:20:20 DBG] Selected input formatter 'Microsoft.AspNetCore.Mvc.Formatters.NewtonsoftJsonInputFormatter' for content type 'application/json'. [21:20:20 DBG] Done attempting to bind parameter 'para' of type 'CellCounter.Api.Model.Home_LoginRequest'. [21:20:20 DBG] Done attempting to bind parameter 'para' of type 'CellCounter.Api.Model.Home_LoginRequest'. [21:20:20 DBG] Attempting to validate the bound parameter 'para' of type 'CellCounter.Api.Model.Home_LoginRequest' ... [21:20:20 DBG] Done attempting to validate the bound parameter 'para' of type 'CellCounter.Api.Model.Home_LoginRequest'. [21:20:20 VRB] Action Filter: Before executing OnActionExecuting on filter Microsoft.AspNetCore.Mvc.ModelBinding.UnsupportedContentTypeFilter. [21:20:20 VRB] Action Filter: After executing OnActionExecuting on filter Microsoft.AspNetCore.Mvc.ModelBinding.UnsupportedContentTypeFilter. [21:20:20 VRB] Action Filter: Before executing OnActionExecutionAsync on filter CellCounter.Api.ValidFilterAttribute. [21:20:20 VRB] Action Filter: Before executing OnActionExecutionAsync on filter CellCounter.Api.GlobalExceptionFilter. [21:20:20 VRB] Action Filter: Before executing OnActionExecutionAsync on filter CellCounter.Api.FormatResponseAttribute. [21:20:20 INF] Executing action method CellCounter.Api.Controllers.HomeController.Login (CellCounter.Api) - Validation state: Valid [21:20:20 VRB] Executing action method CellCounter.Api.Controllers.HomeController.Login (CellCounter.Api) with arguments (["CellCounter.Api.Model.Home_LoginRequest"]) [21:20:20 DBG] Compiling query expression: 'DbSet() .AsNoTracking() .Where(x => x.UserName == __name_0) .FirstOrDefault()' [21:20:21 DBG] Generated query execution expression: 'queryContext => new SingleQueryingEnumerable( (RelationalQueryContext)queryContext, RelationalCommandCache.SelectExpression( Projection Mapping: EmptyProjectionMember -> Dictionary<IProperty, int> { [Property: UserInfo.UserID (long) Required PK AfterSave:Throw ValueGenerated.OnAdd, 0], [Property: UserInfo.CreateTime (DateTime) Required, 1], [Property: UserInfo.Creator (long) Required, 2], [Property: UserInfo.Description (string), 3], [Property: UserInfo.FailTimes (int) Required, 4], [Property: UserInfo.JobNumber (string), 5], [Property: UserInfo.LastFailTime (Nullable), 6], [Property: UserInfo.LastLoginTime (Nullable), 7], [Property: UserInfo.Modifier (long) Required, 8], [Property: UserInfo.ModifyTime (Nullable), 9], [Property: UserInfo.Password (string), 10], [Property: UserInfo.Phone (string), 11], [Property: UserInfo.PsdInvalidTime (Nullable), 12], [Property: UserInfo.PsdPeriod (int) Required, 13], [Property: UserInfo.RealName (string), 14], [Property: UserInfo.UserLevel (int) Required, 15], [Property: UserInfo.UserName (string), 16], [Property: UserInfo.UserStatus (int) Required, 17], } SELECT TOP(1) u.UserID, u.CreateTime, u.Creator, u.Description, u.FailTimes, u.JobNumber, u.LastFailTime, u.LastLoginTime, u.Modifier, u.ModifyTime, u.Password, u.Phone, u.PsdInvalidTime, u.PsdPeriod, u.RealName, u.UserLevel, u.UserName, u.UserStatus FROM UserInfo AS u WHERE u.UserName == @__name_0), Func<QueryContext, DbDataReader, ResultContext, SingleQueryResultCoordinator, UserInfo>, EFCore.Sharding.GenericDbContext, False, False ) .SingleOrDefault()' [21:20:21 DBG] Creating DbCommand for 'ExecuteReader'. [21:20:21 DBG] Created DbCommand for 'ExecuteReader' (17ms). [21:20:21 DBG] Opening connection to database 'main' on server '/home/cellapi/db/cellcounter.db'. Segmentation fault

I want connection to database(sqlite),but it Segmentation fault.How to fix it?

Other information

depend lib spatialte 4.3.0

error info: [22:01:07 ERR] An error occurred using the connection to database 'main' on server '/home/cellapi/db/cellcounter.db'. [22:01:07 ERR] An exception occurred while iterating over the results of a query for context type 'EFCore.Sharding.GenericDbContext'. Microsoft.Data.Sqlite.SqliteException (0x80004005): SQLite Error 1: '/usr/lib/mod_spatialite.so: undefined symbol: gaiaCreateDxfParser'. at Microsoft.Data.Sqlite.SqliteException.ThrowExceptionForRC(Int32 rc, sqlite3 db) at Microsoft.Data.Sqlite.SqliteDataReader.NextResult() at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReader(CommandBehavior behavior) at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReader() at Microsoft.Data.Sqlite.SqliteCommand.ExecuteNonQuery() at Microsoft.Data.Sqlite.SqliteConnectionExtensions.ExecuteNonQuery(SqliteConnection connection, String commandText, SqliteParameter[] parameters) at Microsoft.Data.Sqlite.SqliteConnection.LoadExtensionCore(String file, String proc) at Microsoft.Data.Sqlite.SqliteConnection.Open() at Microsoft.EntityFrameworkCore.Storage.RelationalConnection.OpenDbConnection(Boolean errorsExpected) at Microsoft.EntityFrameworkCore.Storage.RelationalConnection.OpenInternal(Boolean errorsExpected) at Microsoft.EntityFrameworkCore.Storage.RelationalConnection.Open(Boolean errorsExpected) at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReader(RelationalCommandParameterObject parameterObject) at Microsoft.Data.Sqlite.SqliteDataReader.NextResult() at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReader(CommandBehavior behavior) at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReader() at Microsoft.Data.Sqlite.SqliteCommand.ExecuteNonQuery() at Microsoft.Data.Sqlite.SqliteConnectionExtensions.ExecuteNonQuery(SqliteConnection connection, String commandText, SqliteParameter[] parameters) at Microsoft.Data.Sqlite.SqliteConnection.LoadExtensionCore(String file, String proc) at Microsoft.Data.Sqlite.SqliteConnection.Open() at Microsoft.EntityFrameworkCore.Storage.RelationalConnection.OpenDbConnection(Boolean errorsExpected) at Microsoft.EntityFrameworkCore.Storage.RelationalConnection.OpenInternal(Boolean errorsExpected) at Microsoft.EntityFrameworkCore.Storage.RelationalConnection.Open(Boolean errorsExpected) at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReader(RelationalCommandParameterObject parameterObject)

ghost commented 3 years ago

Tagging subscribers to this area: @roji, @ajcvickers See info in area-owners.md if you want to be subscribed.

Issue Details
.Net version 5.0.8 ubuntu version 18.04 arch arm64 depend lib spatialte5.0.1 -rwxr-xr-x 1 root root 1074 ?? 8 21:10 mod_spatialite.la lrwxrwxrwx 1 root root 23 ?? 8 21:10 mod_spatialite.so -> mod_spatialite.so.7.1.0 lrwxrwxrwx 1 root root 23 ?? 8 21:10 mod_spatialite.so.7 -> mod_spatialite.so.7.1.0 -rwxr-xr-x 1 root root 19011120 ?? 8 21:10 mod_spatialite.so.7.1.0 error info: [21:20:07 DBG] Connection id "0HMAQDST0LTD0" completed keep alive response. [21:20:07 INF] Request finished HTTP/1.1 GET http://192.168.0.6/swagger/v1/swagger.json - - - 200 - application/json;+charset=utf-8 5377.0862ms [21:20:17 INF] Request starting HTTP/1.1 POST http://192.168.0.6/api/Home/Login application/json 66 [21:20:17 VRB] All hosts are allowed. [21:20:17 DBG] The request has an origin header: 'http://192.168.0.6'. [21:20:17 INF] CORS policy execution successful. [21:20:17 DBG] Connection id "0HMAQDST0LTD0", Request id "0HMAQDST0LTD0:00000004": started reading request body. [21:20:17 DBG] Connection id "0HMAQDST0LTD0", Request id "0HMAQDST0LTD0:00000004": done reading request body. [21:20:17 DBG] POST requests are not supported [21:20:17 DBG] 1 candidate(s) found for the request path '/api/Home/Login' [21:20:17 DBG] Endpoint 'CellCounter.Api.Controllers.HomeController.Login (CellCounter.Api)' with route pattern 'api/Home/Login' is valid for the request path '/api/Home/Login' [21:20:17 DBG] Request matched endpoint 'CellCounter.Api.Controllers.HomeController.Login (CellCounter.Api)' [21:20:17 DBG] AuthenticationScheme: Bearer was not authenticated. [21:20:17 INF] Executing endpoint 'CellCounter.Api.Controllers.HomeController.Login (CellCounter.Api)' [21:20:17 DBG] Registered model binder providers, in the following order: ["Microsoft.AspNetCore.Mvc.ModelBinding.Binders.BinderTypeModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.ServicesModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.BodyModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.HeaderModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.FloatingPointTypeModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.EnumTypeModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.DateTimeModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.SimpleTypeModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.CancellationTokenModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.ByteArrayModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.FormFileModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.FormCollectionModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.KeyValuePairModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.DictionaryModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.ArrayModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.CollectionModelBinderProvider", "Microsoft.AspNetCore.Mvc.ModelBinding.Binders.ComplexObjectModelBinderProvider"] [21:20:17 INF] Route matched with {action = "Login", controller = "Home"}. Executing controller action with signature System.Threading.Tasks.Task`1[CellCounter.Util.AjaxResult`1[CellCounter.Api.Model.Home_LoginResponse]] Login(CellCounter.Api.Model.Home_LoginRequest) on controller CellCounter.Api.Controllers.HomeController (CellCounter.Api). [21:20:17 DBG] Execution plan of authorization filters (in the following order): ["None"] [21:20:17 DBG] Execution plan of resource filters (in the following order): ["None"] [21:20:17 DBG] Execution plan of action filters (in the following order): ["Microsoft.AspNetCore.Mvc.ModelBinding.UnsupportedContentTypeFilter (Order: -3000)", "CellCounter.Api.ValidFilterAttribute", "CellCounter.Api.GlobalExceptionFilter", "CellCounter.Api.FormatResponseAttribute"] [21:20:17 DBG] Execution plan of exception filters (in the following order): ["CellCounter.Api.GlobalExceptionFilter"] [21:20:17 DBG] Execution plan of result filters (in the following order): ["Microsoft.AspNetCore.Mvc.Infrastructure.ClientErrorResultFilter (Order: -2000)"] [21:20:17 DBG] Executing controller factory for controller CellCounter.Api.Controllers.HomeController (CellCounter.Api) [21:20:18 DBG] An 'IServiceProvider' was created for internal use by Entity Framework. [21:20:19 INF] Entity Framework Core 5.0.4 initialized 'GenericDbContext' using provider 'Microsoft.EntityFrameworkCore.Sqlite' with options: LoadSpatialite using NetTopologySuite [21:20:20 DBG] Executed controller factory for controller CellCounter.Api.Controllers.HomeController (CellCounter.Api) [21:20:20 DBG] Attempting to bind parameter 'para' of type 'CellCounter.Api.Model.Home_LoginRequest' ... [21:20:20 DBG] Attempting to bind parameter 'para' of type 'CellCounter.Api.Model.Home_LoginRequest' using the name '' in request data ... [21:20:20 DBG] Rejected input formatter 'Microsoft.AspNetCore.Mvc.Formatters.NewtonsoftJsonPatchInputFormatter' for content type 'application/json'. [21:20:20 DBG] Selected input formatter 'Microsoft.AspNetCore.Mvc.Formatters.NewtonsoftJsonInputFormatter' for content type 'application/json'. [21:20:20 DBG] Done attempting to bind parameter 'para' of type 'CellCounter.Api.Model.Home_LoginRequest'. [21:20:20 DBG] Done attempting to bind parameter 'para' of type 'CellCounter.Api.Model.Home_LoginRequest'. [21:20:20 DBG] Attempting to validate the bound parameter 'para' of type 'CellCounter.Api.Model.Home_LoginRequest' ... [21:20:20 DBG] Done attempting to validate the bound parameter 'para' of type 'CellCounter.Api.Model.Home_LoginRequest'. [21:20:20 VRB] Action Filter: Before executing OnActionExecuting on filter Microsoft.AspNetCore.Mvc.ModelBinding.UnsupportedContentTypeFilter. [21:20:20 VRB] Action Filter: After executing OnActionExecuting on filter Microsoft.AspNetCore.Mvc.ModelBinding.UnsupportedContentTypeFilter. [21:20:20 VRB] Action Filter: Before executing OnActionExecutionAsync on filter CellCounter.Api.ValidFilterAttribute. [21:20:20 VRB] Action Filter: Before executing OnActionExecutionAsync on filter CellCounter.Api.GlobalExceptionFilter. [21:20:20 VRB] Action Filter: Before executing OnActionExecutionAsync on filter CellCounter.Api.FormatResponseAttribute. [21:20:20 INF] Executing action method CellCounter.Api.Controllers.HomeController.Login (CellCounter.Api) - Validation state: Valid [21:20:20 VRB] Executing action method CellCounter.Api.Controllers.HomeController.Login (CellCounter.Api) with arguments (["CellCounter.Api.Model.Home_LoginRequest"]) [21:20:20 DBG] Compiling query expression: 'DbSet() .AsNoTracking() .Where(x => x.UserName == __name_0) .FirstOrDefault()' [21:20:21 DBG] Generated query execution expression: 'queryContext => new SingleQueryingEnumerable( (RelationalQueryContext)queryContext, RelationalCommandCache.SelectExpression( Projection Mapping: EmptyProjectionMember -> Dictionary { [Property: UserInfo.UserID (long) Required PK AfterSave:Throw ValueGenerated.OnAdd, 0], [Property: UserInfo.CreateTime (DateTime) Required, 1], [Property: UserInfo.Creator (long) Required, 2], [Property: UserInfo.Description (string), 3], [Property: UserInfo.FailTimes (int) Required, 4], [Property: UserInfo.JobNumber (string), 5], [Property: UserInfo.LastFailTime (Nullable), 6], [Property: UserInfo.LastLoginTime (Nullable), 7], [Property: UserInfo.Modifier (long) Required, 8], [Property: UserInfo.ModifyTime (Nullable), 9], [Property: UserInfo.Password (string), 10], [Property: UserInfo.Phone (string), 11], [Property: UserInfo.PsdInvalidTime (Nullable), 12], [Property: UserInfo.PsdPeriod (int) Required, 13], [Property: UserInfo.RealName (string), 14], [Property: UserInfo.UserLevel (int) Required, 15], [Property: UserInfo.UserName (string), 16], [Property: UserInfo.UserStatus (int) Required, 17], } SELECT TOP(1) u.UserID, u.CreateTime, u.Creator, u.Description, u.FailTimes, u.JobNumber, u.LastFailTime, u.LastLoginTime, u.Modifier, u.ModifyTime, u.Password, u.Phone, u.PsdInvalidTime, u.PsdPeriod, u.RealName, u.UserLevel, u.UserName, u.UserStatus FROM UserInfo AS u WHERE u.UserName == @__name_0), Func, EFCore.Sharding.GenericDbContext, False, False ) .SingleOrDefault()' [21:20:21 DBG] Creating DbCommand for 'ExecuteReader'. [21:20:21 DBG] Created DbCommand for 'ExecuteReader' (17ms). [21:20:21 DBG] Opening connection to database 'main' on server '/home/cellapi/db/cellcounter.db'. Segmentation fault I want connection to database(sqlite),but it Segmentation fault.How to fix it? ### Other information depend lib spatialte 4.3.0 error info: [22:01:07 ERR] An error occurred using the connection to database 'main' on server '/home/cellapi/db/cellcounter.db'. [22:01:07 ERR] An exception occurred while iterating over the results of a query for context type 'EFCore.Sharding.GenericDbContext'. Microsoft.Data.Sqlite.SqliteException (0x80004005): SQLite Error 1: '/usr/lib/mod_spatialite.so: undefined symbol: gaiaCreateDxfParser'. at Microsoft.Data.Sqlite.SqliteException.ThrowExceptionForRC(Int32 rc, sqlite3 db) at Microsoft.Data.Sqlite.SqliteDataReader.NextResult() at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReader(CommandBehavior behavior) at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReader() at Microsoft.Data.Sqlite.SqliteCommand.ExecuteNonQuery() at Microsoft.Data.Sqlite.SqliteConnectionExtensions.ExecuteNonQuery(SqliteConnection connection, String commandText, SqliteParameter[] parameters) at Microsoft.Data.Sqlite.SqliteConnection.LoadExtensionCore(String file, String proc) at Microsoft.Data.Sqlite.SqliteConnection.Open() at Microsoft.EntityFrameworkCore.Storage.RelationalConnection.OpenDbConnection(Boolean errorsExpected) at Microsoft.EntityFrameworkCore.Storage.RelationalConnection.OpenInternal(Boolean errorsExpected) at Microsoft.EntityFrameworkCore.Storage.RelationalConnection.Open(Boolean errorsExpected) at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReader(RelationalCommandParameterObject parameterObject) at Microsoft.Data.Sqlite.SqliteDataReader.NextResult() at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReader(CommandBehavior behavior) at Microsoft.Data.Sqlite.SqliteCommand.ExecuteReader() at Microsoft.Data.Sqlite.SqliteCommand.ExecuteNonQuery() at Microsoft.Data.Sqlite.SqliteConnectionExtensions.ExecuteNonQuery(SqliteConnection connection, String commandText, SqliteParameter[] parameters) at Microsoft.Data.Sqlite.SqliteConnection.LoadExtensionCore(String file, String proc) at Microsoft.Data.Sqlite.SqliteConnection.Open() at Microsoft.EntityFrameworkCore.Storage.RelationalConnection.OpenDbConnection(Boolean errorsExpected) at Microsoft.EntityFrameworkCore.Storage.RelationalConnection.OpenInternal(Boolean errorsExpected) at Microsoft.EntityFrameworkCore.Storage.RelationalConnection.Open(Boolean errorsExpected) at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReader(RelationalCommandParameterObject parameterObject)
Author: ganxw
Assignees: -
Labels: `area-System.Data`, `untriaged`
Milestone: -
ganxw commented 3 years ago

Segmentation fault detail info:

Thread 58 ".NET ThreadPool" received signal SIGSEGV, Segmentation fault. [Switching to Thread 0x7a187f01c0 (LWP 10430)] 0x0000000000000000 in ?? () (gdb) bt

0 0x0000000000000000 in ?? ()

dotnet/runtime#1 0x0000007a3c7134dc in sqlite3_busy_handler () from /usr/lib/aarch64-linux-gnu/libsqlite3.so.0 dotnet/runtime#2 0x0000007a9c1f3848 in sqlite3_busy_timeout () from /home//cellapi/runtimes/linux-arm64/native/libe_sqlite3.so dotnet/runtime#3 0x0000007a5c2bda28 in init_spatialite_extension (pApi=, pzErrMsg=0x7a187eb630, db=0x7a20170b98) at spatialite.c:53440 dotnet/runtime#4 sqlite3_modspatialite_init (db=0x7a20170b98, pzErrMsg=0x7a187eb630, pApi=) at spatialite.c:53637 dotnet/runtime#5 0x0000007a9c23e050 in sqlite3_load_extension () from /home//cellapi/runtimes/linux-arm64/native/libe_sqlite3.so dotnet/runtime#6 0x0000007a9c23e25c in loadExt () from /home//cellapi/runtimes/linux-arm64/native/libe_sqlite3.so dotnet/runtime#7 0x0000007a9c26fc8c in sqlite3VdbeExec () from /home//cellapi/runtimes/linux-arm64/native/libe_sqlite3.so dotnet/runtime#8 0x0000007a9c271730 in sqlite3_step () from /home/***/cellapi/runtimes/linux-arm64/native/libe_sqlite3.so dotnet/runtime#9 0x0000007f33a26b6c in ?? () dotnet/runtime#10 0x0000007fa7727ff0 in ?? () from /usr/share/dotnet/shared/Microsoft.NETCore.App/5.0.8/libcoreclr.so Backtrace stopped: previous frame inner to this frame (corrupt stack?)

ajcvickers commented 3 years ago

/cc @bricelam

bricelam commented 3 years ago

Don't use e_sqlite3 with recent versions of mod_spatialite. See the workaround in the docs.