Daoting / dt

利用 C# + XAML 进行快速业务开发的跨平台框架(搬运工)
https://github.com/daoting/dt
56 stars 13 forks source link

Dt.Cm运行一段时间后,会出错停止,似乎与MySql有关 #76

Closed sunl158 closed 2 years ago

sunl158 commented 2 years ago

HTTP Error 500.30 - ASP.NET Core app failed to start Common solutions to this issue: The app failed to start The app started but then stopped The app started but threw an exception during startup Troubleshooting steps: Check the system event log for error messages Enable logging the application process' stdout messages Attach a debugger to the application process and inspect Application '/LM/W3SVC/1/ROOT/dt-cm' with physical root 'D:\dt\Service\src\Cm\' failed to load coreclr. Exception message: CLR worker thread exited prematurely Process Id: 13072. File Version: 16.0.22232.9. Description: IIS ASP.NET Core Module V2 Request Handler. Commit: 3fe12b935c03138f76364dc877a7e069e254b5b2 Application '/LM/W3SVC/1/ROOT/dt-cm' with physical root 'D:\dt\Service\src\Cm\' hit unexpected managed exception, exception code = '0xe0434352'. First 30KB characters of captured stdout and stderr logs: Unhandled exception. MySqlConnector.MySqlException (0x80004005): Couldn't connect to server ---> System.IO.IOException: Unable to read data from the transport connection: 你的主机中的软件中止了一个已建立的连接。. ---> System.Net.Sockets.SocketException (10053): 你的主机中的软件中止了一个已建立的连接。 at System.Net.Sockets.NetworkStream.Read(Span1 buffer) --- End of inner exception stack trace --- at System.Net.Sockets.NetworkStream.Read(Span1 buffer) at System.Net.Security.SslStream.EnsureFullTlsFrameAsync[TIOAdapter](TIOAdapter adapter) at System.Net.Security.SslStream.ReadAsyncInternal[TIOAdapter](TIOAdapter adapter, Memory1 buffer) at System.Net.Security.SslStream.Read(Byte[] buffer, Int32 offset, Int32 count) at System.IO.Stream.Read(Span1 buffer) at MySqlConnector.Utilities.Utility.Read(Stream stream, Memory1 buffer) in /_/src/MySqlConnector/Utilities/Utility.cs:line 569 at MySqlConnector.Protocol.Serialization.StreamByteHandler.<ReadBytesAsync>g__DoReadBytesSync|6_0(Memory1 buffer) in //src/MySqlConnector/Protocol/Serialization/StreamByteHandler.cs:line 33 --- End of stack trace from previous location --- at MySqlConnector.Protocol.Serialization.BufferedByteReader.ReadBytesAsync(IByteHandler byteHandler, ArraySegment`1 buffer, Int32 totalBytesToRead, IOBehavior ioBehavior) in //src/MySqlConnector/Protocol/Serialization/BufferedByteReader.cs:line 34 at MySqlConnector.Protocol.Serialization.ProtocolUtility.gAddContinuation|10(ValueTask1 headerBytes, BufferedByteReader bufferedByteReader, IByteHandler byteHandler, Func1 getNextSequenceNumber, ProtocolErrorBehavior protocolErrorBehavior, IOBehavior ioBehavior) in //src/MySqlConnector/Protocol/Serialization/ProtocolUtility.cs:line 423 at MySqlConnector.Protocol.Serialization.ProtocolUtility.gAddContinuation|50(ValueTask1 readPacketTask, BufferedByteReader bufferedByteReader, IByteHandler byteHandler, Func1 getNextSequenceNumber, ArraySegmentHolder`1 previousPayloads, ProtocolErrorBehavior protocolErrorBehavior, IOBehavior ioBehavior) in //src/MySqlConnector/Protocol/Serialization/ProtocolUtility.cs:line 490 at MySqlConnector.Core.ServerSession.ReceiveReplyAsyncAwaited(ValueTask1 task) in /_/src/MySqlConnector/Core/ServerSession.cs:line 947 at MySqlConnector.Core.ServerSession.ConnectAsync(ConnectionSettings cs, MySqlConnection connection, Int32 startTickCount, ILoadBalancer loadBalancer, IOBehavior ioBehavior, CancellationToken cancellationToken) in /_/src/MySqlConnector/Core/ServerSession.cs:line 549 at MySqlConnector.Core.ServerSession.ConnectAsync(ConnectionSettings cs, MySqlConnection connection, Int32 startTickCount, ILoadBalancer loadBalancer, IOBehavior ioBehavior, CancellationToken cancellationToken) in /_/src/MySqlConnector/Core/ServerSession.cs:line 587 at MySqlConnector.Core.ConnectionPool.ConnectSessionAsync(MySqlConnection connection, String logMessage, Int32 startTickCount, IOBehavior ioBehavior, CancellationToken cancellationToken) in /_/src/MySqlConnector/Core/ConnectionPool.cs:line 367 at MySqlConnector.Core.ConnectionPool.GetSessionAsync(MySqlConnection connection, Int32 startTickCount, IOBehavior ioBehavior, CancellationToken cancellationToken) in /_/src/MySqlConnector/Core/ConnectionPool.cs:line 94 at MySqlConnector.Core.ConnectionPool.GetSessionAsync(MySqlConnection connection, Int32 startTickCount, IOBehavior ioBehavior, CancellationToken cancellationToken) in /_/src/MySqlConnector/Core/ConnectionPool.cs:line 124 at MySqlConnector.MySqlConnection.CreateSessionAsync(ConnectionPool pool, Int32 startTickCount, Nullable1 ioBehavior, CancellationToken cancellationToken) in //src/MySqlConnector/MySqlConnection.cs:line 919 at MySqlConnector.MySqlConnection.OpenAsync(Nullable`1 ioBehavior, CancellationToken cancellationToken) in //src/MySqlConnector/MySqlConnection.cs:line 410 at MySqlConnector.MySqlConnection.Open() in /_/src/MySqlConnector/MySqlConnection.cs:line 373 at Dt.Core.DbSchema.LoadSchema() in D:\dt\Service\src\Dt.Core\Base\MySql\DbSchema.cs:line 66 at Dt.Core.DbSchema.Init() in D:\dt\Service\src\Dt.Core\Base\MySql\DbSchema.cs:line 45 at Dt.Core.Launcher.Run(String[] p_args, Stub p_stub, Boolean pisSingletonSvc) in D:\dt\Service\src\Dt.Core\Base\Start\Launcher.cs:line 46 at Program.

$(String[] args) in D:\dt\Service\src\Cm\Program.cs:line 1
Process Id: 13072. File Version: 16.0.22232.9. Description: IIS ASP.NET Core Module V2 Request Handler. Commit: 3fe12b935c03138f76364dc877a7e069e254b5b2 Application: w3wp.exe CoreCLR Version: 6.0.922.41905 .NET Version: 6.0.9 Description: The process was terminated due to an unhandled exception. Exception Info: MySqlConnector.MySqlException (0x80004005): Couldn't connect to server ---> System.IO.IOException: Unable to read data from the transport connection: 你的主机中的软件中止了一个已建立的连接。. ---> System.Net.Sockets.SocketException (10053): 你的主机中的软件中止了一个已建立的连接。 at System.Net.Sockets.NetworkStream.Read(Span1 buffer) --- End of inner exception stack trace --- at System.Net.Sockets.NetworkStream.Read(Span1 buffer) at System.Net.Security.SslStream.EnsureFullTlsFrameAsync[TIOAdapter](TIOAdapter adapter) at System.Net.Security.SslStream.ReadAsyncInternal[TIOAdapter](TIOAdapter adapter, Memory1 buffer) at System.Net.Security.SslStream.Read(Byte[] buffer, Int32 offset, Int32 count) at System.IO.Stream.Read(Span1 buffer) at MySqlConnector.Utilities.Utility.Read(Stream stream, Memory`1 buffer) in /
/src/MySqlConnector/Utilities/Utility.cs:line 569 at MySqlConnector.Protocol.Serialization.StreamByteHandler.g__DoReadBytesSync|60(Memory`1 buffer) in //src/MySqlConnector/Protocol/Serialization/StreamByteHandler.cs:line 33 --- End of stack trace from previous location --- at MySqlConnector.Protocol.Serialization.BufferedByteReader.ReadBytesAsync(IByteHandler byteHandler, ArraySegment1 buffer, Int32 totalBytesToRead, IOBehavior ioBehavior) in /_/src/MySqlConnector/Protocol/Serialization/BufferedByteReader.cs:line 34 at MySqlConnector.Protocol.Serialization.ProtocolUtility.<ReadPacketAsync>g__AddContinuation|1_0(ValueTask1 headerBytes, BufferedByteReader bufferedByteReader, IByteHandler byteHandler, Func1 getNextSequenceNumber, ProtocolErrorBehavior protocolErrorBehavior, IOBehavior ioBehavior) in /_/src/MySqlConnector/Protocol/Serialization/ProtocolUtility.cs:line 423 at MySqlConnector.Protocol.Serialization.ProtocolUtility.<DoReadPayloadAsync>g__AddContinuation|5_0(ValueTask1 readPacketTask, BufferedByteReader bufferedByteReader, IByteHandler byteHandler, Func1 getNextSequenceNumber, ArraySegmentHolder1 previousPayloads, ProtocolErrorBehavior protocolErrorBehavior, IOBehavior ioBehavior) in //src/MySqlConnector/Protocol/Serialization/ProtocolUtility.cs:line 490 at MySqlConnector.Core.ServerSession.ReceiveReplyAsyncAwaited(ValueTask`1 task) in //src/MySqlConnector/Core/ServerSession.cs:line 947 at MySqlConnector.Core.ServerSession.ConnectAsync(ConnectionSettings cs, MySqlConnection connection, Int32 startTickCount, ILoadBalancer loadBalancer, IOBehavior ioBehavior, CancellationToken cancellationToken) in //src/MySqlConnector/Core/ServerSession.cs:line 549 at MySqlConnector.Core.ServerSession.ConnectAsync(ConnectionSettings cs, MySqlConnection connection, Int32 startTickCount, ILoadBalancer loadBalancer, IOBehavior ioBehavior, CancellationToken cancellationToken) in //src/MySqlConnector/Core/ServerSession.cs:line 587 at MySqlConnector.Core.ConnectionPool.ConnectSessionAsync(MySqlConnection connection, String logMessage, Int32 startTickCount, IOBehavior ioBehavior, CancellationToken cancellationToken) in //src/MySqlConnector/Core/ConnectionPool.cs:line 367 at MySqlConnector.Core.ConnectionPool.GetSessionAsync(MySqlConnection connection, Int32 startTickCount, IOBehavior ioBehavior, CancellationToken cancellationToken) in //src/MySqlConnector/Core/ConnectionPool.cs:line 94 at MySqlConnector.Core.ConnectionPool.GetSessionAsync(MySqlConnection connection, Int32 startTickCount, IOBehavior ioBehavior, CancellationToken cancellationToken) in //src/MySqlConnector/Core/ConnectionPool.cs:line 124 at MySqlConnector.MySqlConnection.CreateSessionAsync(ConnectionPool pool, Int32 startTickCount, Nullable`1 ioBehavior, CancellationToken cancellationToken) in //src/MySqlConnector/MySqlConnection.cs:line 919 at MySqlConnector.MySqlConnection.OpenAsync(Nullable`1 ioBehavior, CancellationToken cancellationToken) in //src/MySqlConnector/MySqlConnection.cs:line 410 at MySqlConnector.MySqlConnection.Open() in //src/MySqlConnector/MySqlConnection.cs:line 373 at Dt.Core.DbSchema.LoadSchema() in D:\dt\Service\src\Dt.Core\Base\MySql\DbSchema.cs:line 66 at Dt.Core.DbSchema.Init() in D:\dt\Service\src\Dt.Core\Base\MySql\DbSchema.cs:line 45 at Dt.Core.Launcher.Run(String[] p_args, Stub p_stub, Boolean p_isSingletonSvc) in D:\dt\Service\src\Dt.Core\Base\Start\Launcher.cs:line 46 at Program.
$(String[] args) in D:\dt\Service\src\Cm\Program.cs:line 1