puppet-nova/releasenotes/notes/nova-manage-user-16e7145d0c10bf57.yaml
Diana Clarke e128ba6538 Correct permissions on the nova logfiles
When you execute nova-manage commands, oslo logs to the following
location (file name is dynamically created based on command name).

    /var/log/nova/nova-manage.log

Because puppet-nova is executing these commands as root,
nova-manage.log is owned by root, preventing the 'nova-manage
db archive_deleted_rows' entry in nova's crontab from executing.

    Permission denied: '/var/log/nova/nova-manage.log'

This log file is also an outlier, as all other log files in
/var/log/nova/ are owned by nova:nova.

Similar issues are possible for other nova logs, if for example
a nova services is initially started manually as root, so the
ownership of all nova logs is corrected before configuring nova.

Co-Authored-By: Oliver Walsh <owalsh@redhat.com>
Co-Authored-By: Diana Clarke <diana.joan.clarke@gmail.com>
Co-Authored-By: Maciej Kucia <maciej@kucia.net>
Closes-Bug: #1671681
Change-Id: I0ca0110cbf9139c79074cf603dcab9135f96e765
2017-12-19 20:24:52 +00:00

18 lines
709 B
YAML

---
fixes:
- |
Correct permissions on the nova logfiles.
If the ``nova-manage`` commands (such as dbsync) were initially run as
root then subsequent runs as the nova user would fail as the logfile is
owned by root (see `bug 1671681`_).
The ownership of all nova logfiles is now checked before configuring
nova, as a similar issue could prevent a service starting, and the
nova-manage command is now run as the correct user.
Adds nova::params::nova_user and nova::params::nova_group.
nova::cron::archive_deleted_rows::user now defaults to
nova::params::nova_user instead of hardcoding 'nova'
.. _bug 1671681: https://bugs.launchpad.net/puppet-nova/+bug/1671681