#603 ✓resolved
kristian

MysqlError:MySQL server has gone away (mysql_error_code=0001)

Reported by kristian | October 18th, 2008 @ 07:31 AM

there is a kind of unmotivated error from time to time. basically the connection gets stale and can not be used anymore. the backtrace looks like this

MysqlError:MySQL server has gone away (mysql_error_code=0001)

/home/.renee/pariruby/downloads.pariyatti.org/vendor/localgems/gems/dm-core-0.9.3/lib/dm-core/adapters/data_objects_adapter.rb:63:in `execute_reader'
/home/.renee/pariruby/downloads.pariyatti.org/vendor/localgems/gems/dm-core-0.9.3/lib/dm-core/adapters/data_objects_adapter.rb:63:in `read_one'
/home/.renee/pariruby/downloads.pariyatti.org/vendor/localgems/gems/dm-core-0.9.3/lib/dm-core/adapters/data_objects_adapter.rb:168:in `with_connection'
/home/.renee/pariruby/downloads.pariyatti.org/vendor/localgems/gems/dm-core-0.9.3/lib/dm-core/adapters/data_objects_adapter.rb:58:in `read_one'
/home/.renee/pariruby/downloads.pariyatti.org/vendor/localgems/gems/dm-core-0.9.3/lib/dm-core/repository.rb:72:in `read_one'
/home/.renee/pariruby/downloads.pariyatti.org/vendor/localgems/gems/dm-core-0.9.3/lib/dm-core/model.rb:227:in `first'
/home/.renee/pariruby/downloads.pariyatti.org/vendor/localgems/gems/dm-core-0.9.3/lib/dm-core/model.rb:208:in `get'
/home/.renee/pariruby/downloads.pariyatti.org/vendor/localgems/gems/dm-core-0.9.3/lib/dm-core/model.rb:212:in `get!'

the sql log gives me: Wed, 15 Oct 2008 18:03:22 GMT ~ debug ~ MySQL server has gone away (mysql_error_ code=0001) Wed, 15 Oct 2008 18:03:22 GMT ~ debug ~ #<DataObjects::Mysql::Connection:0x40ef7 a78 @__pool=#<Extlib::Pooling::Pool<DataObjects::Mysql::Connection> available=0 reserved_count=1>, @uri=#<Addressable::URI:0x20714f42 URI:mysql://paridown:GVjV z-o@mysql.host.pariyatti.org/pariyattidownloads>, @using_socket=false, @concrete _command=DataObjects::Mysql::Command, @__allocated_in_pool=Wed Oct 15 11:03:22 - 0700 2008, @connection=#<Object:0x40ef79b0>> Wed, 15 Oct 2008 18:03:22 GMT ~ error ~ MySQL server has gone away (mysql_error_ code=0001)

my workaround is: http://pastie.org/295236

I do not know how to spec this, but if this patch is wanted and I get a hint, I will provide the spec as well.

Comments and changes to this ticket

  • Dan Kubb (dkubb)

    Dan Kubb (dkubb) December 5th, 2008 @ 05:23 AM

    • State changed from “new” to “unconfirmed”
    • Assigned user changed from “Sam Smoot” to “Dirkjan Bussink”

    Dirkjan, do you think this is related to the other MySQL issues with do_mysql?

  • Dirkjan Bussink

    Dirkjan Bussink December 9th, 2008 @ 03:02 PM

    • State changed from “unconfirmed” to “resolved”

    This problem should have been fixed. We now explicitly specify that we want to keep the connection alive. If this problem still occurs, please let us know!

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

People watching this ticket

Pages