glance-api.conf contains incorrect sqlite connection string path

Bug #1028711 reported by Byron McCollum on 2012-07-25
This bug affects 1 person
Affects Status Importance Assigned to Milestone
glance (Ubuntu)

Bug Description

1) Release

Ubuntu 12.04 LTS Server

2) Package Version

2012.2+git201207241232~precise-0ubuntu1 (via ppa:openstack-ubuntu-testing/folsom-trunk-testing)

3) Expected

$ sudo apt-get install -y glance=2012.2*
$ pgrep -l glance
1111 glance-api
2222 glance-registry
$ sudo grep 'sql_connection' /etc/glance/glance-api.conf
sql_connection = sqlite:////var/lib/glance/glance.sqlite

4) Happened Instead

$ sudo apt-get install -y glance=2012.2*
$ pgrep -l glance
2222 glance-registry
$ sudo tail /var/log/glance/api.log
2012-07-24 21:27:45 ERROR glance.db.sqlalchemy.api [-] Error configuring registry database with supplied sql_connection 'sqlite:///glance.sqlite'. Got error:(OperationalError) unable to open database file None None
$ sudo grep 'sql_connection' /etc/glance/glance-api.conf
sql_connection = sqlite:///glance.sqlite

5) Workaround

$ sudo sed -i /etc/glance/glance-api.conf -e 's|sql_connection = sqlite:///glance.sqlite|sql_connection = sqlite:////var/lib/glance/glance.sqlite|'
$ sudo service glance-api restart
$ pgrep -l glance
1111 glance-api
2222 glance-registry

Adam Gandelman (gandelman-a) wrote :

Thanks Byron, I've included glance-api.conf in the sql_conn.patch to also set the path there. New packages building in PPA, should be fixed in Quantal with the next upload.

Changed in glance (Ubuntu):
status: New → Fix Committed
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package glance - 2012.2~f3-0ubuntu1

glance (2012.2~f3-0ubuntu1) quantal; urgency=low

  [ Adam Gandleman ]
  * debian/patches/sql_conn.patch: Also set default sqlite path for
    in glance-api.conf. (LP: #1028711)
  * debian/patches/fix-docs-build.patch: Fix docs build

  [ Chuck Short ]
  * New upstream version.
  * debian/control: python-xattr is no longer a required depends.
    (LP: #1031396)
  * debian/control: Move python-jsonschema to glance.
    (LP: #1030152)
  * debian/control: Start the slow transition to python-glanceclient.
 -- Chuck Short <email address hidden> Thu, 16 Aug 2012 13:58:32 -0500

Changed in glance (Ubuntu):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers