Freeswitch Crashed by ODBC32.dll
I have a javascript run every 30 seconds to invoke 5 other javascript through "apiExecute". Each of these 5 script is simple and only do 3-5 of SQL commands through ODBC and it works fine in short time. But when I leave it overnight, I got a crash report in the morning showing the crashing module is odbc32.dll. The system I am using is win xp. odbc32.dll is provided by Microsoft. Is it really Microsoft's bug or something wrong in FS? As odbc32.dll has been so widely used for many years, it should not be so fragile.
Are you on latest (GIT) version of FS? I know there was an issue in Javascript/ODBC, but that was several months ago. /Peter Från: freeswitch-users-bounces@lists.freeswitch.org [mailto:freeswitch-users-bounces@lists.freeswitch.org] För xuyan yang Skickat: den 30 juli 2010 11:57 Till: FreeSWITCH Users Help Ämne: [Freeswitch-users] Freeswitch Crashed by ODBC32.dll I have a javascript run every 30 seconds to invoke 5 other javascript through "apiExecute". Each of these 5 script is simple and only do 3-5 of SQL commands through ODBC and it works fine in short time. But when I leave it overnight, I got a crash report in the morning showing the crashing module is odbc32.dll. The system I am using is win xp. odbc32.dll is provided by Microsoft. Is it really Microsoft's bug or something wrong in FS? As odbc32.dll has been so widely used for many years, it should not be so fragile. !DSPAM:4c52a41d32931828916853!
Yes, it is the git version 2 to 3 days ago. By my estimation, the crash may take about 5 to 8 hours. Now I have increased the sql frequency by 10 times to see whether it will got crash much sooner. On Fri, Jul 30, 2010 at 6:15 PM, Peter Olsson < peter.olsson@visionutveckling.se> wrote:
Are you on latest (GIT) version of FS? I know there was an issue in Javascript/ODBC, but that was several months ago.
/Peter
*Från:* freeswitch-users-bounces@lists.freeswitch.org [mailto: freeswitch-users-bounces@lists.freeswitch.org] *För *xuyan yang *Skickat:* den 30 juli 2010 11:57 *Till:* FreeSWITCH Users Help *Ämne:* [Freeswitch-users] Freeswitch Crashed by ODBC32.dll
I have a javascript run every 30 seconds to invoke 5 other javascript through "apiExecute". Each of these 5 script is simple and only do 3-5 of SQL commands through ODBC and it works fine in short time. But when I leave it overnight, I got a crash report in the morning showing the crashing module is odbc32.dll.
The system I am using is win xp. odbc32.dll is provided by Microsoft. Is it really Microsoft's bug or something wrong in FS?
As odbc32.dll has been so widely used for many years, it should not be so fragile.
!DSPAM:4c52a41d32931828916853!
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
When I increase the frequency of my script by 10 times to once every 3 seconds, it do crash 10 times faster, in about 23 minutes. On Fri, Jul 30, 2010 at 6:50 PM, xuyan yang <xyangni@gmail.com> wrote:
Yes, it is the git version 2 to 3 days ago. By my estimation, the crash may take about 5 to 8 hours. Now I have increased the sql frequency by 10 times to see whether it will got crash much sooner.
On Fri, Jul 30, 2010 at 6:15 PM, Peter Olsson < peter.olsson@visionutveckling.se> wrote:
Are you on latest (GIT) version of FS? I know there was an issue in Javascript/ODBC, but that was several months ago.
/Peter
*Från:* freeswitch-users-bounces@lists.freeswitch.org [mailto: freeswitch-users-bounces@lists.freeswitch.org] *För *xuyan yang *Skickat:* den 30 juli 2010 11:57 *Till:* FreeSWITCH Users Help *Ämne:* [Freeswitch-users] Freeswitch Crashed by ODBC32.dll
I have a javascript run every 30 seconds to invoke 5 other javascript through "apiExecute". Each of these 5 script is simple and only do 3-5 of SQL commands through ODBC and it works fine in short time. But when I leave it overnight, I got a crash report in the morning showing the crashing module is odbc32.dll.
The system I am using is win xp. odbc32.dll is provided by Microsoft. Is it really Microsoft's bug or something wrong in FS?
As odbc32.dll has been so widely used for many years, it should not be so fragile.
!DSPAM:4c52a41d32931828916853!
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
Could ju run it within the debugger (in Visual Studio) and wait for the crash, and then copy/paste the entire call stack? Also, I think it's better if you create a new issue for this on Jira, and provide all information there. /Peter Från: freeswitch-users-bounces@lists.freeswitch.org [mailto:freeswitch-users-bounces@lists.freeswitch.org] För xuyan yang Skickat: den 30 juli 2010 13:40 Till: FreeSWITCH Users Help Ämne: Re: [Freeswitch-users] Freeswitch Crashed by ODBC32.dll When I increase the frequency of my script by 10 times to once every 3 seconds, it do crash 10 times faster, in about 23 minutes. On Fri, Jul 30, 2010 at 6:50 PM, xuyan yang <xyangni@gmail.com<mailto:xyangni@gmail.com>> wrote: Yes, it is the git version 2 to 3 days ago. By my estimation, the crash may take about 5 to 8 hours. Now I have increased the sql frequency by 10 times to see whether it will got crash much sooner. On Fri, Jul 30, 2010 at 6:15 PM, Peter Olsson <peter.olsson@visionutveckling.se<mailto:peter.olsson@visionutveckling.se>> wrote: Are you on latest (GIT) version of FS? I know there was an issue in Javascript/ODBC, but that was several months ago. /Peter Från: freeswitch-users-bounces@lists.freeswitch.org<mailto:freeswitch-users-bounces@lists.freeswitch.org> [mailto:freeswitch-users-bounces@lists.freeswitch.org<mailto:freeswitch-users-bounces@lists.freeswitch.org>] För xuyan yang Skickat: den 30 juli 2010 11:57 Till: FreeSWITCH Users Help Ämne: [Freeswitch-users] Freeswitch Crashed by ODBC32.dll I have a javascript run every 30 seconds to invoke 5 other javascript through "apiExecute". Each of these 5 script is simple and only do 3-5 of SQL commands through ODBC and it works fine in short time. But when I leave it overnight, I got a crash report in the morning showing the crashing module is odbc32.dll. The system I am using is win xp. odbc32.dll is provided by Microsoft. Is it really Microsoft's bug or something wrong in FS? As odbc32.dll has been so widely used for many years, it should not be so fragile. _______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org<mailto:FreeSWITCH-users@lists.freeswitch.org> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org !DSPAM:4c52bc1d32931069989341!
While doing testing with a modified version of conf-ivr-js, we (RemoteLink) ran into a problem with ODBC. It was consistent at a given number of calls. Barry Nicholson (Co-founder & Director of Engineering) traced it to a problem with Select in the ODBC driver code. I understand that there is a fix for this. I will ask him to provide additional detail which we will try to post. -- View this message in context: http://freeswitch-users.2379917.n2.nabble.com/Freeswitch-Crashed-by-ODBC32-d... Sent from the freeswitch-users mailing list archive at Nabble.com.
I found a 6 lines script which can cause FS to crash. The report showing that the crash mod is ntdll.dll. But when there are other scripts with odbc connection runing in background, the reported mod will become odbc32.dll. I am not sure whether this is the root cause of the failure I found before. I hope this simple test case be better than calling stack. // test.js use("ODBC"); var db = new ODBC("odbcxxxx", "", ""); db.connect(); db.query("select * from `user` where Mobile = '00447575xxxxxx'"); db.connect(); db.close(); On Fri, Jul 30, 2010 at 10:29 PM, David Swardstrom < dswardstrom@remotelink.com> wrote:
While doing testing with a modified version of conf-ivr-js, we (RemoteLink) ran into a problem with ODBC. It was consistent at a given number of calls. Barry Nicholson (Co-founder & Director of Engineering) traced it to a problem with Select in the ODBC driver code. I understand that there is a fix for this. I will ask him to provide additional detail which we will try to post. -- View this message in context: http://freeswitch-users.2379917.n2.nabble.com/Freeswitch-Crashed-by-ODBC32-d... Sent from the freeswitch-users mailing list archive at Nabble.com.
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
More information on the problem with ODBC from Barrry: Note: This is using a Postgresql driver, but there is a chance that similar problematic code could be in other ODBC drivers.
Here's a description of the issue we had.
Recently, while load testing the FreeSWITCH system we discovered a crash at an approximate load of 560 simultaneous calls. This problem turned out to be difficult to find because the stack was being corrupted so we could not trace the crash reliably.
Eventually, we got lucky and trapped a crash with gdb active and a mildly corrupted stack. The problem turned out to be an issue with a tcp/ip select() call. The default fdset variable used by the select() call only allowed 1024 file descriptors to be used by the entire system. Since FreeSWITCH uses two file descriptors (SIP) per call we exceeded that number quite quickly. Technically, we were corrupting the stack at the 500 call level, but the stack wasn't getting corrupted 'enough' to crash until we approached 560 simultaneous calls.
The fdset variable/select() call that was causing the issue was in the Postgresql v8.4 0200 Driver code. We contacted the Postgresql developers list and almost immediately received a patch from them. The patch converted the select() call to a Linux poll call. Problem solved. We were able to test the system to 2500 simultaneous calls.
Barry Nicholson
-- View this message in context: http://freeswitch-users.2379917.n2.nabble.com/Freeswitch-Crashed-by-ODBC32-d... Sent from the freeswitch-users mailing list archive at Nabble.com.
participants (3)
-
David Swardstrom
-
Peter Olsson
-
xuyan yang