[issue13335] Service application hang in python25.dll
New submission from Chandra Sekhar Reddy : Service application hanged in python25.dll, below are the environment details. Operating System : Windows server 2008 R2 (Virtual Machine) Application Type : Service Application We have got the process dump from the customer environment and after analyzing the dump using the Windbg tool. Below is the status of the 4 running threads. Last error for thread 0: LastErrorValue: (Win32) 0 (0) - The operation completed successfully. LastStatusValue: (NTSTATUS) 0 - STATUS_WAIT_0 Last error for thread 1: LastErrorValue: (Win32) 0 (0) - The operation completed successfully. LastStatusValue: (NTSTATUS) 0 - STATUS_WAIT_0 Last error for thread 2: LastErrorValue: (Win32) 0 (0) - The operation completed successfully. LastStatusValue: (NTSTATUS) 0 - STATUS_WAIT_0 Last error for thread 3: LastErrorValue: (Win32) 0 (0) - The operation completed successfully. LastStatusValue: (NTSTATUS) 0 - STATUS_WAIT_0 But as part of the hang analysis the command "!analyze -hang" shows some problem with thread 1 Probably caused by : python25.dll ( python25!PyList_New+62 ) 03dff250 1e072c5b python25!PyFuture_FromAST+0x873 03dff25c 1e073307 python25!PyFuture_FromAST+0xbcb 03dff264 1e07332e python25!PyObject_GC_Malloc+0x67 03dff270 1e081502 python25!PyObject_GC_New+0xe python25!PyList_New+0x62 Thanks, -Chandra -- components: Windows messages: 146928 nosy: chandra priority: normal severity: normal status: open title: Service application hang in python25.dll type: performance versions: Python 2.6 ___ Python tracker <http://bugs.python.org/issue13335> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue13335] Service application hang in python25.dll
Chandra Sekhar Reddy added the comment: Hi Amaury and Terry, Thanks for your feedback, actually the product that we have delivered to customer is now in support phase, so currently there is no development going on, so we cannot use the latest python. It would be of great help if you could provide your inputs by looking at the process call stack. So that I can proceed further. >From the call stack the function appears to be like memory allocation related >functions from python module. Is it possible for a process to hang if memory >request to OS is not satisfied. Awaiting for your valuable inputs, -Chandra -- ___ Python tracker <http://bugs.python.org/issue13335> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12755] Service application crash in python25!PyObject_Malloc
New submission from Chandra Sekhar Reddy : Service application crashed in python25.dll, below are the environment details. Operating System : Windows server 2008 R2 (Virtual Machine) Application Type : Service Application FAULTING_IP: python25!PyObject_Malloc+2d 1e09603d 8b30mov esi,dword ptr [eax] EXCEPTION_RECORD: -- (.exr 0x) ExceptionAddress: 1e09603d (python25!PyObject_Malloc+0x002d) ExceptionCode: c005 (Access violation) ExceptionFlags: NumberParameters: 2 Parameter[0]: Parameter[1]: Attempt to read from address PROCESS_NAME: adem.exe ADDITIONAL_DEBUG_TEXT: Use '!findthebuild' command to search for the target build information. If the build information is available, run '!findthebuild -s ; .reload' to set symbol path and load symbols. FAULTING_MODULE: 76f8 ntdll DEBUG_FLR_IMAGE_TIMESTAMP: 4625bfe5 ERROR_CODE: (NTSTATUS) 0xc005 - The instruction at 0x%08lx referenced memory at 0x%08lx. The memory could not be %s. EXCEPTION_CODE: (NTSTATUS) 0xc005 - The instruction at 0x%08lx referenced memory at 0x%08lx. The memory could not be %s. EXCEPTION_PARAMETER1: EXCEPTION_PARAMETER2: READ_ADDRESS: FOLLOWUP_IP: python25!PyObject_Malloc+2d 1e09603d 8b30mov esi,dword ptr [eax] FAULTING_THREAD: 2474 BUGCHECK_STR: APPLICATION_FAULT_INVALID_POINTER_WRITE_NULL_POINTER_WRITE_NULL_POINTER_READ_WRONG_SYMBOLS PRIMARY_PROBLEM_CLASS: INVALID_POINTER_WRITE_NULL_POINTER_WRITE DEFAULT_BUCKET_ID: INVALID_POINTER_WRITE_NULL_POINTER_WRITE LAST_CONTROL_TRANSFER: from 1e0c1093 to 1e09603d STACK_TEXT: WARNING: Stack unwind information not available. Following frames may be wrong. 0505f088 1e0c1093 0025 04a128ea 04a128d0 python25!PyObject_Malloc+0x2d python25!PyString_FromStringAndSize+0x43 STACK_COMMAND: ~4s; .ecxr ; kb SYMBOL_STACK_INDEX: 0 SYMBOL_NAME: python25!PyObject_Malloc+2d FOLLOWUP_NAME: MachineOwner MODULE_NAME: python25 IMAGE_NAME: python25.dll BUCKET_ID: WRONG_SYMBOLS FAILURE_BUCKET_ID: INVALID_POINTER_WRITE_NULL_POINTER_WRITE_c005_python25.dll!PyObject_Malloc -- components: Windows messages: 142163 nosy: chandra priority: normal severity: normal status: open title: Service application crash in python25!PyObject_Malloc type: crash ___ Python tracker <http://bugs.python.org/issue12755> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12755] Service application crash in python25!PyObject_Malloc
Chandra Sekhar Reddy added the comment: Hi Amaury, Thanks for your update on the issue. Here are few details of our application adem.exe 1. We have three c-projects namely, AdemCube, wv, CAM, the output of the build binaries will give us _ADEMCube.pyd, _wv.pyd, _cam.pyd 2. The main project is spider project which is in python, this python code will make us of the above libraries. The output of this project will result in adem.exe The adem.exe when it executes it internally calls methods to above libraries explained in point 1. Here in this library we use call to the method below PyErr_SetString(CubeError, errorString); The call to this method is internally calls PyString_FromStringAndSize() which internally calls PyObject_Malloc(). This is the place where it is crashing. Please let me know if you need any information. Thanks, -Chandra -- ___ Python tracker <http://bugs.python.org/issue12755> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12755] Service application crash in python25!PyObject_Malloc
Chandra Sekhar Reddy added the comment: Hi, Thanks for your valuable feedback, As per your suggestion I have re-verified the code for the possibility of NULL values, intrestingly I have observed that buffer overrun is happening in our application, where there is a character array declared with size 200 and a string is being copied without considering the null terminating character. static PyObject *eError; char errorString[200]; _snprintf(errorString, 200, "some message content"); PyErr_SetString(eError, errorString); I am not 100% sure if this may cause the PyObject_Malloc to fail. Thanks, -Chandra -- ___ Python tracker <http://bugs.python.org/issue12755> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com