Sybase ASE is terminating this process. Connection died while writing to socket

橙三吉。 提交于 2019-12-12 03:32:54

问题


In Sybase, we are intermittent exception like

System.Data.OleDb.OleDbException (0x80004005): [08S01]
[ASEOLEDB]ASE is terminating this process.
   at System.Data.OleDb.OleDbCommand.ExecuteCommandTextErrorHandling(OleDbHResult hr)
   at System.Data.OleDb.OleDbCommand.ExecuteCommandTextForMultpleResults(tagDBPARAMS dbParams, Object& executeResult)
   at System.Data.OleDb.OleDbCommand.ExecuteCommandText(Object& executeResult)
   at System.Data.OleDb.OleDbCommand.ExecuteReaderInternal(CommandBehavior behavior, String method)
   at System.Data.OleDb.OleDbCommand.ExecuteReader(CommandBehavior behavior)

or

System.Data.OleDb.OleDbException (0x80004005): [08S01]
[ASEOLEDB]Sybase  Connection died while writing to socket. Socket returned error code 10053.
at System.Data.OleDb.OleDbCommand.ExecuteCommandTextErrorHandling(OleDbHResult hr)
   at System.Data.OleDb.OleDbCommand.ExecuteCommandTextForMultpleResults(tagDBPARAMS dbParams, Object& executeResult)
   at System.Data.OleDb.OleDbCommand.ExecuteCommandText(Object& executeResult)
   at System.Data.OleDb.OleDbCommand.ExecuteReaderInternal(CommandBehavior behavior, String method)
   at System.Data.OleDb.OleDbCommand.ExecuteNonQuery()

The number of records in the table is less than 200K and queries are typically inline inserts or select with temporary tables

After the disconnection, we need to recycle the thread or bounce the process.

Do we need to change at Sybase configuration end? Or inside the application process?


回答1:


This is likely an issue on the side of the ASE server. Check out the ASE errorlog file, there should be a stack trace with clues as to why the process was terminated. Depending on what you find there, you may need to contact TechSupport and get the latest patch, or incrementing certain ASE config settings might also help.




回答2:


I generally have seen this error phrasing when the connection is a victim of a deadlock situation. If that's the case it should be in the ASE error logs.




回答3:


Here we have a generic WinSock "10053" error code, displayed from the OS where the .net (ASE, Oledb, etc...) client is calling the DB.

It is possible that you find nothing in the ASE error logs (unless you activate a specific user tracing), because the server is closing the connection in a standard way, while the Sybase client software has cached its request and is still writing to the windows socket (btw, yes, it is a bug/issue: you could search the latest information on EBFs and software maintenance or open a new support request).

I've had this problem when creating a temporary table (from .Net ASE Client dll): possible cause is that the local temporary table get dropped if the connection is returned to the connection pool (in fact the error was present each day at the first trial). I've tried turning off the connection pooling in connection string and that worked for me.

    Data Source=myASEsrv;Port=nnnn;Database=myDB;Uid=myUsr;Pwd=myPswd;Pooling=False;


来源:https://stackoverflow.com/questions/35906317/sybase-ase-is-terminating-this-process-connection-died-while-writing-to-socket

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!