Linux

Chef-zero Is Broken in Ubuntu 14.04

I was playing a bit with applying chef cookbooks locally, without a chef server and found that version of Chef from Ubuntu repo is way too low for normal operation in local mode.

# apt-cache policy chef
chef:
  Installed: 11.8.2-2
date = ""
  Version table:
 *** 11.8.2-2 0
        500 http://us.archive.ubuntu.com/ubuntu/ trusty/universe amd64 Packages

There is a bug resolved in recent versions of Chef related to the way in which chef-zero parses json files. If there is metadata.json file instead of metadata.rb in a cookbook chef-zero fails to parse this file expecting just a filename instead of full file content.

OpenStack Icehouse Reset Incorrect Quota Count for Nova

Sometimes when VM is deleted in not-so-correct way quota counters displayed in Dashboard => Project => Overview may not update correctly as well.

You may see that number of VMs/vcpus/RAM for tenant displayed on this page does not match actual values. For example it may display “Instances used 8 of 10” while you have only 5 VMs in this tenant.

Some Library Cookbooks Already Rely on ‘Sensitive’ Method

Recently participated in Chef cookbook upgrades. One of cookbooks depends on library rabbitmq cookbook => 3.1

The problem is that recent versions of rabbitmq cookbook (after 3.3.0) rely on newer chef-cient functionality and if you have chef-clients version < 11.14.0 installed on nodes chef-client run will fail and you will see the following error in the log:

undefined method `sensitive' for Chef::Resource::Template

OpenStack Glance Authentication and Changed Swift Password

Input data: OpenStack Icehouse, glance with swift backend. Admin username and password for swift service were changed. After this requests to download some images started to fail.

# glance --debug image-download <image_id> --file image_store_to --progress

returns 500 error for some image_ids and works for other.

in glance-api service log I see that for some reason previous user/password is still in use:

...
[glance.registry.client.v1.client]: 2014-12-31 02:49:47,235 DEBUG client.do_requ
est Registry request GET /images/<image_id> HTTP 200 r
equest id req-71062b81-963a-41c9-b6a6-3120f2f6f60b
[keystoneclient.session]: 2014-12-31 02:49:47,236 DEBUG session.request REQ: cur
l -i -X POST http://<keystone_node>:5000/v2.0/tokens -H "Content-Type
: application/json" -H "User-Agent: python-keystoneclient"
[keystoneclient.session]: 2014-12-31 02:49:47,236 DEBUG session.request REQ BODY
: {"auth": {"tenantName": "service", "passwordCredentials": {"username": "<previous_user>"
, "password": "<previous_password>"}}}
...