RTC Forums
April 26, 2024, 09:30:19 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
 
   Home   Help Login Register  
Pages: 1 [2]
  Print  
Author Topic: Server eating up all cpu  (Read 11876 times)
Cesar
RTC Expired
*
Posts: 17


« Reply #15 on: June 26, 2013, 12:40:15 AM »

The db connection management was one of my first guesses of the problem,

myDac automatically handles the connection pooling, (in the code i gave you i had it disabled because i was testing)

But even with pooling disabled it never goes higher than 50 active connections. also MyDAc handles when you have exahusted your connections and raise an Error.

And the destructor of the connection handles the closing. anyways I'm making the changes, to manually close them before freeing them.
Logged
Cesar
RTC Expired
*
Posts: 17


« Reply #16 on: June 26, 2013, 02:02:30 AM »

I just made a new test with interesting results.

I logged every time i enter in the PosEx Function

i discovered it doesn't get stuck in it, but instead, when the cpu spikes, it gets called again and again with the same parameters and length.

now im running a new test logging the contents of InBuffer in the internalRead to see what exactly is sending. unfortunately, my users are already logging out and my traffic might not be enough to make another spike until tomorrow
Logged
D.Tkalcec (RTC)
Administrator
*****
Posts: 1881


« Reply #17 on: June 26, 2013, 02:53:41 AM »

I've analyzed the code responsible for reading data with Chunked Transfer encoding and found a possible scenario which could result in an endless loop, calling InternalRead over and over again. I am working on an update now, will be releasing it shortly.

Best Regards,
Danijel Tkalcec
Logged
Cesar
RTC Expired
*
Posts: 17


« Reply #18 on: June 26, 2013, 03:14:47 AM »

Thanks Danijiel,

let me know if you need to test anything, i'll gladly be your guinea pig Wink
Logged
D.Tkalcec (RTC)
Administrator
*****
Posts: 1881


« Reply #19 on: June 26, 2013, 03:24:28 AM »

I've uploaded the RTC SDK v6.15 to the "RTC SDK Downloads" area.
Please let me know if this update has resolved your issue with 100% CPU drain.

Best Regards,
Danijel Tkalcec
Logged
D.Tkalcec (RTC)
Administrator
*****
Posts: 1881


« Reply #20 on: June 26, 2013, 09:37:21 PM »

Is my "guinea pig" dead? Or how should I interpret the long silence? Wink
Logged
Cesar
RTC Expired
*
Posts: 17


« Reply #21 on: June 27, 2013, 02:08:43 AM »

hehehe sorry,

i made the changes yesterday and the server has not spiked up again, it's almost 24 hours since the change so I'll say its officially working now.

Thank you very much this bug was cracking my head for the last 3 weeks
Logged
D.Tkalcec (RTC)
Administrator
*****
Posts: 1881


« Reply #22 on: June 27, 2013, 02:44:06 AM »

I'm glad you've decided to report this issue. Any RTC Server hosting content for mobile phones could have ended up with the same problem. I'm surprised it wasn't happening more often. Anyway ... I'm going to send an E-Mail now for everyone to download this update, because it's a bug I would rather not have in a production Server.

Best Regards,
Danijel Tkalcec
Logged
Pages: 1 [2]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.024 seconds with 16 queries.