Merge lp:~james-page/ubuntu/oneiric/nova/fix-new-installs into lp:~ubuntu-server-dev/nova/diablo

Proposed by James Page
Status: Merged
Merge reported by: James Page
Merged at revision: not available
Proposed branch: lp:~james-page/ubuntu/oneiric/nova/fix-new-installs
Merge into: lp:~ubuntu-server-dev/nova/diablo
Diff against target: 33 lines (+13/-1)
2 files modified
debian/changelog (+8/-0)
debian/nova-common.postinst (+5/-1)
To merge this branch: bzr merge lp:~james-page/ubuntu/oneiric/nova/fix-new-installs
Reviewer Review Type Date Requested Status
Scott Moser Approve
Review via email: mp+77899@code.launchpad.net

Description of the change

This should fix the case of a NEW nova installation - where the permissions on /var/lib/nova should always be set to nova:nova as it won't contain any running instances.

I've tested this:

1) as an upgrade to a fixed install of -0ubuntu4
2) as a fresh install

Both now work.

To post a comment you must log in.
Revision history for this message
Scott Moser (smoser) wrote :

seems reasonable.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'debian/changelog'
2--- debian/changelog 2011-09-30 19:22:13 +0000
3+++ debian/changelog 2011-10-03 10:59:17 +0000
4@@ -1,3 +1,11 @@
5+nova (2011.3-0ubuntu5) oneiric; urgency=low
6+
7+ * debian/nova-common.postinst:
8+ - Set permissions recursively on /var/lib/nova to nova:nova for new
9+ installations (LP: #865169).
10+
11+ -- James Page <james.page@ubuntu.com> Mon, 03 Oct 2011 11:02:34 +0100
12+
13 nova (2011.3-0ubuntu4) oneiric; urgency=low
14
15 [James Page]
16
17=== modified file 'debian/nova-common.postinst'
18--- debian/nova-common.postinst 2011-09-30 19:18:10 +0000
19+++ debian/nova-common.postinst 2011-10-03 10:59:17 +0000
20@@ -11,8 +11,12 @@
21 usermod -g nova nova
22 fi
23 chown -R nova:nova /var/log/nova/ /etc/nova/nova.conf
24- if dpkg --compare-versions "$2" lt "2011.3-0ubuntu4"; then
25+ if [ -z "$2" ]; then
26+ # New install - blanket permissions
27+ chown -R nova:nova /var/lib/nova/
28+ elif dpkg --compare-versions "$2" lt "2011.3-0ubuntu4"; then
29 # Make sure the LXC rootfs mount points are excluded
30+ # during upgrades from previous versions
31 find /var/lib/nova/ -name 'rootfs' -prune -o \
32 -group root -a -user nova -exec chown nova:nova {} \;
33 find /var/lib/nova/ -name 'rootfs' -prune -o \

Subscribers

People subscribed via source and target branches