I''m experiencing an intermittent appearance of "Mysql::Error: Lost connection to MySQL server during query" Read through many of the prior messages (most from mid 2006), and I don''t see any that apply to my setup. The usual blames I saw were change from MySQL 4.0 to 4.1 so password type mistmatch, old version of a mysql gem, tabs in database.yml. None of these apply. Someone also previously suggested adding this to environment.rb: ActiveRecord::Base.verification_timeout = 14400 I did that, but it made no difference. As I say, intermittent. Several requests are just fine, then I get a Proxy Error message. go look in the production.log, and see the Mysql::Error entry. All requests are within a couple seconds of each other just bouncing around pages. * fresh install of OS X 10.5.2 on box "app01" we''ll call it. * fresh install of OS X 10.5.2 on box "data01" we''ll call it. * using built-in MySQL on "data01" for now (5.0.45). * installed a Rails app on "app01" with a frozen 1.2.3 in /vendor. * database.yml defines the connection using "host:" with an IP address and a password. * the database connection is actually going to MySQL Proxy on app01 which balances a master-master cluster. (http://forge.mysql.com/wiki/MySQL_Proxy) * both machines are new intel Xserves, just now being set up so they''re not busy at all. Looking for new ideas... Thanks, -- gw --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Hi! On Mar 28, 2008, at 10:24 PM, Greg Willits wrote:> > I''m experiencing an intermittent appearance of > "Mysql::Error: Lost connection to MySQL server during query" > > Read through many of the prior messages (most from mid 2006), and I > don''t see any that apply to my setup. > > The usual blames I saw were change from MySQL 4.0 to 4.1 so password > type mistmatch, old version of a mysql gem, tabs in database.yml. None > of these apply. > > Someone also previously suggested adding this to environment.rb: > > ActiveRecord::Base.verification_timeout = 14400 > > I did that, but it made no difference. > > As I say, intermittent. Several requests are just fine, then I get a > Proxy Error message. go look in the production.log, and see the > Mysql::Error entry. All requests are within a couple seconds of each > other just bouncing around pages. > > * fresh install of OS X 10.5.2 on box "app01" we''ll call it. > > * fresh install of OS X 10.5.2 on box "data01" we''ll call it. > > * using built-in MySQL on "data01" for now (5.0.45). > > * installed a Rails app on "app01" with a frozen 1.2.3 in /vendor. > > * database.yml defines the connection using "host:" with an IP > address and > a password. > > * the database connection is actually going to MySQL Proxy on app01 > which balances a master-master cluster. > (http://forge.mysql.com/wiki/MySQL_Proxy) > > * both machines are new intel Xserves, just now being set up so > they''re > not busy at all. > > Looking for new ideas... > > Thanks, > > -- gwHave you verified that you have the native C ruby-mysql bindings? the pure ruby ones that rails falls back to do this diconnection dance all the time. You can verify by requireing mysql.bundle and see if it fails: ~/rubinius > irb >> require ''rubygems'' => false >> require ''mysql.bundle'' => true Cheers- - Ezra Zygmuntowicz -- Founder & Software Architect -- ezra-NLltGlunAUd/unjJdyJNww@public.gmane.org -- EngineYard.com --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
> On Mar 28, 2008, at 10:24 PM, Greg Willits wrote: >> I''m experiencing an intermittent appearance of >> "Mysql::Error: Lost connection to MySQL server during query"> On Mar 29, 2008, at 12:09 AM, Ezra Zygmuntowicz wrote: > Have you verified that you have the native C ruby-mysql bindings? the > pure ruby ones that rails falls back to do this diconnection dance all > the time. You can verify by requireing mysql.bundle and see if it > fails: > > ~/rubinius > irb >>> require ''rubygems'' > => false >>> require ''mysql.bundle'' > => trueHmmm... I compiled that for my dev system, and so my dev system says true, but indeed these Xserves say false -- kinda lame for Apple to have not included the C versions. I will pursue this line further. Thanks! -- gw --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
On Mar 29, 2008, at 2:18 AM, Greg Willits wrote:> >> On Mar 28, 2008, at 10:24 PM, Greg Willits wrote: >>> I''m experiencing an intermittent appearance of >>> "Mysql::Error: Lost connection to MySQL server during query" > >> On Mar 29, 2008, at 12:09 AM, Ezra Zygmuntowicz wrote: >> Have you verified that you have the native C ruby-mysql bindings? >> the >> pure ruby ones that rails falls back to do this diconnection dance >> all >> the time. You can verify by requireing mysql.bundle and see if it >> fails: >> >> ~/rubinius > irb >>>> require ''rubygems'' >> => false >>>> require ''mysql.bundle'' >> => true > > > Hmmm... I compiled that for my dev system, and so my dev system says > true, but indeed these Xserves say false -- kinda lame for Apple to > have not included the C versions. > > I will pursue this line further. Thanks!OK, dumb question, having finally found the right witchcraft for installing this on my platform, my question is whether ruby/rails will use it automatically? Do I have to do anything in environment.rb or elswhere to ensure the C version gets used instead of the Ruby version? -- gw --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
On Mar 29, 2008, at 3:26 AM, Greg Willits wrote:> > On Mar 29, 2008, at 2:18 AM, Greg Willits wrote: >> >>> On Mar 28, 2008, at 10:24 PM, Greg Willits wrote: >>>> I''m experiencing an intermittent appearance of >>>> "Mysql::Error: Lost connection to MySQL server during query" >> >>> On Mar 29, 2008, at 12:09 AM, Ezra Zygmuntowicz wrote: >>> Have you verified that you have the native C ruby-mysql bindings? >>> the >>> pure ruby ones that rails falls back to do this diconnection dance >>> all >>> the time. You can verify by requireing mysql.bundle and see if it >>> fails: >>> >>> ~/rubinius > irb >>>>> require ''rubygems'' >>> => false >>>>> require ''mysql.bundle'' >>> => true >> >> >> Hmmm... I compiled that for my dev system, and so my dev system says >> true, but indeed these Xserves say false -- kinda lame for Apple to >> have not included the C versions. >> >> I will pursue this line further. Thanks! > > > OK, dumb question, having finally found the right witchcraft for > installing this on my platform, my question is whether ruby/rails > will use it automatically? Do I have to do anything in environment.rb > or elswhere to ensure the C version gets used instead of the Ruby > version? > > -- gwYeah it should get used automatically if you have it installed. Cheers- - Ezra Zygmuntowicz -- Founder & Software Architect -- ezra-NLltGlunAUd/unjJdyJNww@public.gmane.org -- EngineYard.com --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Just thought I''d add a note in here that could help, I started getting this error once when I was adding too much stuff to session. The thread is here: http://groups.google.com/group/rubyonrails-talk/browse_thread/thread/320984b2a7f117/dae118da427aa979 On Mar 30, 8:01 am, Ezra Zygmuntowicz <ezmob...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> On Mar 29, 2008, at 3:26 AM, Greg Willits wrote: > > > > > > > On Mar 29, 2008, at 2:18 AM, Greg Willits wrote: > > >>> On Mar 28, 2008, at 10:24 PM, Greg Willits wrote: > >>>> I''m experiencing an intermittent appearance of > >>>> "Mysql::Error: Lost connection to MySQL server during query" > > >>> On Mar 29, 2008, at 12:09 AM, Ezra Zygmuntowicz wrote: > >>> Have you verified that you have the native C ruby-mysql bindings? > >>> the > >>> pure ruby ones that rails falls back to do this diconnection dance > >>> all > >>> the time. You can verify by requireing mysql.bundle and see if it > >>> fails: > > >>> ~/rubinius > irb > >>>>> require ''rubygems'' > >>> => false > >>>>> require ''mysql.bundle'' > >>> => true > > >> Hmmm... I compiled that for my dev system, and so my dev system says > >> true, but indeed these Xserves say false -- kinda lame for Apple to > >> have not included the C versions. > > >> I will pursue this line further. Thanks! > > > OK, dumb question, having finally found the right witchcraft for > > installing this on my platform, my question is whether ruby/rails > > will use it automatically? Do I have to do anything in environment.rb > > or elswhere to ensure the C version gets used instead of the Ruby > > version? > > > -- gw > > Yeah it should get used automatically if you have it installed. > > Cheers- > - Ezra Zygmuntowicz > -- Founder & Software Architect > -- e...-NLltGlunAUd/unjJdyJNww@public.gmane.org > -- EngineYard.com--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
>>> Do I have to do anything...to ensure the C version gets used >>> instead of the Ruby >>> version? >> >> Yeah it should get used automatically if you have it installed.Thanks. It looks like this fixed the problem, but I wanted to be sure it''s wasn''t just because it was in a good mood.> Just thought I''d add a note in here that could help, I started getting > this error once when I was adding too much stuff to session. The > thread is here: > > http://groups.google.com/group/rubyonrails-talk/browse_thread/ > thread/320984b2a7f117/dae118da427aa979good to know. Probably not applicable for me as this app has been running fine on another set of servers (setup by someone else), and I''m just trying to relocate it. Thanks guys, -- gw --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---