SUSE Support

Here When You Need Us

crowbarctl backup fails and locks the database

This document (7017857) is provided subject to the disclaimer at the end of this document.

Environment

SUSE OpenStack Cloud 6

Situation

Command 'crowbarctl backup' fails:
root@admin:~ # crowbarctl backup create -U <user> -P <password> test_backup
/usr/lib64/ruby/2.1.0/net/protocol.rb:158:in `rescue in rbuf_fill': Net::ReadTimeout (Net::ReadTimeout)
        from /usr/lib64/ruby/2.1.0/net/protocol.rb:152:in `rbuf_fill'
        from /usr/lib64/ruby/2.1.0/net/protocol.rb:134:in `readuntil'
        from /usr/lib64/ruby/2.1.0/net/protocol.rb:144:in `readline'
        from /usr/lib64/ruby/2.1.0/net/http/response.rb:39:in `read_status_line'
        from /usr/lib64/ruby/2.1.0/net/http/response.rb:28:in `read_new'
        from /usr/lib64/ruby/2.1.0/net/http.rb:1408:in `block in transport_request'
        from /usr/lib64/ruby/2.1.0/net/http.rb:1405:in `catch'
        from /usr/lib64/ruby/2.1.0/net/http.rb:1405:in `transport_request'
        from /usr/lib64/ruby/2.1.0/net/http.rb:1378:in `request'
        from /usr/lib64/ruby/2.1.0/net/http.rb:1371:in `block in request'
        from /usr/lib64/ruby/2.1.0/net/http.rb:853:in `start'
        from /usr/lib64/ruby/2.1.0/net/http.rb:1369:in `request'

Afterwards the database is locked:
E, [2016-04-19T15:25:47.780900 #7229:0x007ff2daa7cc48] ERROR -- SQLite3::BusyException: database is locked: begin transaction
F, [2016-04-19T15:25:47.782003 #7229:0x007ff2daa7cc48] FATAL --
ActiveRecord::StatementInvalid (SQLite3::BusyException: database is locked: begin transaction):

Resolution

Restarting crowbar with 'systemctl restart crowbar' will kill the  background job and allow new backup run. Using 'crowbarctl -t 180 backup' to increase the timeout is also a valid workaround.

Cause

The database is being held by a previous task that is still processed on the server side in the background. At some point this task would have finished and new backup job would be able to run again. It is specific due to use of sqlite and plan is to move to another database.

Disclaimer

This Support Knowledgebase provides a valuable tool for SUSE customers and parties interested in our products and solutions to acquire information, ideas and learn from one another. Materials are provided for informational, personal or non-commercial use within your organization and are presented "AS IS" WITHOUT WARRANTY OF ANY KIND.

  • Document ID:7017857
  • Creation Date: 20-Jul-2016
  • Modified Date:03-Mar-2020
    • SUSE Open Stack Cloud

< Back to Support Search

For questions or concerns with the SUSE Knowledgebase please contact: tidfeedback[at]suse.com

tick icon

SUSE Support Forums

Get your questions answered by experienced Sys Ops or interact with other SUSE community experts.

tick icon

Support Resources

Learn how to get the most from the technical support you receive with your SUSE Subscription, Premium Support, Academic Program, or Partner Program.

tick icon

Open an Incident

Open an incident with SUSE Technical Support, manage your subscriptions, download patches, or manage user access.