Merge "Use systemd-journald instead of log files"
This commit is contained in:
commit
517e3d5c0d
@ -45,7 +45,9 @@ neutron_install_method: "source"
|
|||||||
### Python code details
|
### Python code details
|
||||||
###
|
###
|
||||||
|
|
||||||
neutron_log_dir: "/var/log/neutron"
|
# Neutron logs are collected with systemd-journald by default
|
||||||
|
# neutron_log_dir may be used for complience with old ha-tool
|
||||||
|
#neutron_log_dir: "/var/log/neutron"
|
||||||
|
|
||||||
# Set the package install state for pip_package
|
# Set the package install state for pip_package
|
||||||
# Options are 'present' and 'latest'
|
# Options are 'present' and 'latest'
|
||||||
@ -121,9 +123,10 @@ neutron_dns_domain: "openstacklocal."
|
|||||||
### DNSMasq configuration
|
### DNSMasq configuration
|
||||||
###
|
###
|
||||||
# Dnsmasq doesn't work with config_template override, a deployer
|
# Dnsmasq doesn't work with config_template override, a deployer
|
||||||
# should instead configure its own neutron_dhcp_config key/values
|
# should instead configure its own neutron_dhcp_config key/values like this:
|
||||||
neutron_dhcp_config:
|
#neutron_dhcp_config:
|
||||||
log-facility: "{{ neutron_log_dir }}/neutron-dnsmasq.log"
|
# log-facility: "{{ neutron_log_dir }}/neutron-dnsmasq.log"
|
||||||
|
neutron_dhcp_config: {}
|
||||||
|
|
||||||
# Disable dnsmasq to resolve DNS via local resolv.conf.
|
# Disable dnsmasq to resolve DNS via local resolv.conf.
|
||||||
# When dnsmasq_dns_servers are not set,
|
# When dnsmasq_dns_servers are not set,
|
||||||
|
@ -87,28 +87,23 @@
|
|||||||
mode: "0755"
|
mode: "0755"
|
||||||
- path: "{{ neutron_system_home_folder }}/ha_confs"
|
- path: "{{ neutron_system_home_folder }}/ha_confs"
|
||||||
|
|
||||||
- name: Test for log directory or link
|
- name: Create log directory
|
||||||
shell: |
|
block:
|
||||||
if [ -h "{{ neutron_log_dir }}" ]; then
|
- name: Test for log directory
|
||||||
chown -h {{ neutron_system_user_name }}:{{ neutron_system_group_name }} "{{ neutron_log_dir }}"
|
stat:
|
||||||
chown -R {{ neutron_system_user_name }}:{{ neutron_system_group_name }} "$(readlink {{ neutron_log_dir }})"
|
path: "{{ neutron_log_dir }}"
|
||||||
else
|
register: log_dir
|
||||||
exit 1
|
- name: Create neutron log dir
|
||||||
fi
|
file:
|
||||||
register: log_dir
|
path: "{{ item.path }}"
|
||||||
failed_when: false
|
state: directory
|
||||||
changed_when: log_dir.rc != 0
|
owner: "{{ item.owner|default(neutron_system_user_name) }}"
|
||||||
|
group: "{{ item.group|default(neutron_system_group_name) }}"
|
||||||
- name: Create neutron log dir
|
mode: "{{ item.mode|default('0755') }}"
|
||||||
file:
|
with_items:
|
||||||
path: "{{ item.path }}"
|
- { path: "{{ neutron_log_dir }}" }
|
||||||
state: directory
|
when: log_dir.stat.exists and file_details.stat.isdir
|
||||||
owner: "{{ item.owner|default(neutron_system_user_name) }}"
|
when: neutron_log_dir is defined
|
||||||
group: "{{ item.group|default(neutron_system_group_name) }}"
|
|
||||||
mode: "{{ item.mode|default('0755') }}"
|
|
||||||
with_items:
|
|
||||||
- { path: "{{ neutron_log_dir }}" }
|
|
||||||
when: log_dir.rc != 0
|
|
||||||
|
|
||||||
- name: Drop sudoers file
|
- name: Drop sudoers file
|
||||||
template:
|
template:
|
||||||
|
@ -13,7 +13,6 @@
|
|||||||
use_stderr = False
|
use_stderr = False
|
||||||
debug = {{ debug }}
|
debug = {{ debug }}
|
||||||
fatal_deprecations = {{ neutron_fatal_deprecations }}
|
fatal_deprecations = {{ neutron_fatal_deprecations }}
|
||||||
log_file = {{ neutron_log_dir }}/neutron.log
|
|
||||||
use_journal = True
|
use_journal = True
|
||||||
|
|
||||||
## Rpc all
|
## Rpc all
|
||||||
|
@ -341,7 +341,7 @@ neutron_services:
|
|||||||
service_conf_path: "{{ neutron_conf_dir }}"
|
service_conf_path: "{{ neutron_conf_dir }}"
|
||||||
service_conf: dhcp_agent.ini
|
service_conf: dhcp_agent.ini
|
||||||
service_rootwrap: rootwrap.d/dhcp.filters
|
service_rootwrap: rootwrap.d/dhcp.filters
|
||||||
execstarts: "{{ neutron_bin }}/neutron-dhcp-agent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/dhcp_agent.ini --log-file={{ neutron_log_dir }}/neutron-dhcp-agent.log"
|
execstarts: "{{ neutron_bin }}/neutron-dhcp-agent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/dhcp_agent.ini"
|
||||||
config_overrides: "{{ neutron_dhcp_agent_ini_overrides }}"
|
config_overrides: "{{ neutron_dhcp_agent_ini_overrides }}"
|
||||||
config_type: "ini"
|
config_type: "ini"
|
||||||
init_config_overrides: "{{ neutron_dhcp_agent_init_overrides }}"
|
init_config_overrides: "{{ neutron_dhcp_agent_init_overrides }}"
|
||||||
@ -353,7 +353,7 @@ neutron_services:
|
|||||||
service_conf_path: "{{ neutron_conf_dir }}"
|
service_conf_path: "{{ neutron_conf_dir }}"
|
||||||
service_conf: plugins/ml2/openvswitch_agent.ini
|
service_conf: plugins/ml2/openvswitch_agent.ini
|
||||||
service_rootwrap: rootwrap.d/openvswitch-plugin.filters
|
service_rootwrap: rootwrap.d/openvswitch-plugin.filters
|
||||||
execstarts: "{{ neutron_bin }}/neutron-openvswitch-agent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/plugins/ml2/ml2_conf.ini --config-file {{ neutron_conf_dir }}/plugins/ml2/openvswitch_agent.ini --log-file={{ neutron_log_dir }}/neutron-openvswitch-agent.log"
|
execstarts: "{{ neutron_bin }}/neutron-openvswitch-agent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/plugins/ml2/ml2_conf.ini --config-file {{ neutron_conf_dir }}/plugins/ml2/openvswitch_agent.ini"
|
||||||
config_overrides: "{{ neutron_openvswitch_agent_ini_overrides }}"
|
config_overrides: "{{ neutron_openvswitch_agent_ini_overrides }}"
|
||||||
config_type: "ini"
|
config_type: "ini"
|
||||||
init_config_overrides: "{{ neutron_openvswitch_agent_init_overrides }}"
|
init_config_overrides: "{{ neutron_openvswitch_agent_init_overrides }}"
|
||||||
@ -365,7 +365,7 @@ neutron_services:
|
|||||||
service_conf_path: "{{ neutron_conf_dir }}"
|
service_conf_path: "{{ neutron_conf_dir }}"
|
||||||
service_conf: plugins/ml2/linuxbridge_agent.ini
|
service_conf: plugins/ml2/linuxbridge_agent.ini
|
||||||
service_rootwrap: rootwrap.d/linuxbridge-plugin.filters
|
service_rootwrap: rootwrap.d/linuxbridge-plugin.filters
|
||||||
execstarts: "{{ neutron_bin }}/neutron-linuxbridge-agent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/plugins/ml2/ml2_conf.ini --config-file {{ neutron_conf_dir }}/plugins/ml2/linuxbridge_agent.ini --log-file={{ neutron_log_dir }}/neutron-linuxbridge-agent.log"
|
execstarts: "{{ neutron_bin }}/neutron-linuxbridge-agent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/plugins/ml2/ml2_conf.ini --config-file {{ neutron_conf_dir }}/plugins/ml2/linuxbridge_agent.ini"
|
||||||
config_overrides: "{{ neutron_linuxbridge_agent_ini_overrides }}"
|
config_overrides: "{{ neutron_linuxbridge_agent_ini_overrides }}"
|
||||||
config_type: "ini"
|
config_type: "ini"
|
||||||
init_config_overrides: "{{ neutron_linuxbridge_agent_init_overrides }}"
|
init_config_overrides: "{{ neutron_linuxbridge_agent_init_overrides }}"
|
||||||
@ -376,7 +376,7 @@ neutron_services:
|
|||||||
service_en: "{{ neutron_metadata | bool }}"
|
service_en: "{{ neutron_metadata | bool }}"
|
||||||
service_conf_path: "{{ neutron_conf_dir }}"
|
service_conf_path: "{{ neutron_conf_dir }}"
|
||||||
service_conf: metadata_agent.ini
|
service_conf: metadata_agent.ini
|
||||||
execstarts: "{{ neutron_bin }}/neutron-metadata-agent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/metadata_agent.ini --log-file={{ neutron_log_dir }}/neutron-metadata-agent.log"
|
execstarts: "{{ neutron_bin }}/neutron-metadata-agent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/metadata_agent.ini"
|
||||||
config_overrides: "{{ neutron_metadata_agent_ini_overrides }}"
|
config_overrides: "{{ neutron_metadata_agent_ini_overrides }}"
|
||||||
config_type: "ini"
|
config_type: "ini"
|
||||||
init_config_overrides: "{{ neutron_metadata_agent_init_overrides }}"
|
init_config_overrides: "{{ neutron_metadata_agent_init_overrides }}"
|
||||||
@ -387,7 +387,7 @@ neutron_services:
|
|||||||
service_en: "{{ neutron_metering | bool }}"
|
service_en: "{{ neutron_metering | bool }}"
|
||||||
service_conf_path: "{{ neutron_conf_dir }}"
|
service_conf_path: "{{ neutron_conf_dir }}"
|
||||||
service_conf: metering_agent.ini
|
service_conf: metering_agent.ini
|
||||||
execstarts: "{{ neutron_bin }}/neutron-metering-agent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/metering_agent.ini --log-file={{ neutron_log_dir }}/neutron-metering-agent.log"
|
execstarts: "{{ neutron_bin }}/neutron-metering-agent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/metering_agent.ini"
|
||||||
config_overrides: "{{ neutron_metering_agent_ini_overrides }}"
|
config_overrides: "{{ neutron_metering_agent_ini_overrides }}"
|
||||||
config_type: "ini"
|
config_type: "ini"
|
||||||
init_config_overrides: "{{ neutron_metering_agent_init_overrides }}"
|
init_config_overrides: "{{ neutron_metering_agent_init_overrides }}"
|
||||||
@ -409,7 +409,7 @@ neutron_services:
|
|||||||
service_rootwrap: rootwrap.d/l3.filters
|
service_rootwrap: rootwrap.d/l3.filters
|
||||||
environment:
|
environment:
|
||||||
PATH: "{{ neutron_bin }}:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
|
PATH: "{{ neutron_bin }}:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
|
||||||
execstarts: "{{ neutron_bin }}/neutron-l3-agent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/l3_agent.ini --log-file={{ neutron_log_dir }}/neutron-l3-agent.log"
|
execstarts: "{{ neutron_bin }}/neutron-l3-agent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/l3_agent.ini"
|
||||||
config_overrides: "{{ neutron_l3_agent_ini_overrides }}"
|
config_overrides: "{{ neutron_l3_agent_ini_overrides }}"
|
||||||
config_type: "ini"
|
config_type: "ini"
|
||||||
init_config_overrides: "{{ neutron_l3_agent_init_overrides }}"
|
init_config_overrides: "{{ neutron_l3_agent_init_overrides }}"
|
||||||
@ -420,7 +420,7 @@ neutron_services:
|
|||||||
service_en: "{{ neutron_bgp | bool }}"
|
service_en: "{{ neutron_bgp | bool }}"
|
||||||
service_conf_path: "{{ neutron_conf_dir }}"
|
service_conf_path: "{{ neutron_conf_dir }}"
|
||||||
service_conf: bgp_dragent.ini
|
service_conf: bgp_dragent.ini
|
||||||
execstarts: "{{ neutron_bin }}/neutron-bgp-dragent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/bgp_dragent.ini --log-file={{ neutron_log_dir }}/neutron-bgp-dragent.log"
|
execstarts: "{{ neutron_bin }}/neutron-bgp-dragent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/bgp_dragent.ini"
|
||||||
config_overrides: "{{ neutron_bgp_dragent_ini_overrides }}"
|
config_overrides: "{{ neutron_bgp_dragent_ini_overrides }}"
|
||||||
config_type: "ini"
|
config_type: "ini"
|
||||||
init_config_overrides: "{{ neutron_bgp_dragent_init_overrides }}"
|
init_config_overrides: "{{ neutron_bgp_dragent_init_overrides }}"
|
||||||
@ -436,7 +436,7 @@ neutron_services:
|
|||||||
service_conf_path: "{{ neutron_conf_dir }}"
|
service_conf_path: "{{ neutron_conf_dir }}"
|
||||||
service_conf: vpnaas_agent.ini
|
service_conf: vpnaas_agent.ini
|
||||||
service_rootwrap: rootwrap.d/vpnaas.filters
|
service_rootwrap: rootwrap.d/vpnaas.filters
|
||||||
execstarts: "{{ neutron_bin }}/neutron-vpn-agent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/vpnaas_agent.ini --log-file={{ neutron_log_dir }}/neutron-vpn-agent.log"
|
execstarts: "{{ neutron_bin }}/neutron-vpn-agent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/vpnaas_agent.ini"
|
||||||
config_overrides: "{{ neutron_vpnaas_agent_ini_overrides }}"
|
config_overrides: "{{ neutron_vpnaas_agent_ini_overrides }}"
|
||||||
config_type: "ini"
|
config_type: "ini"
|
||||||
init_config_overrides: "{{ neutron_vpn_agent_init_overrides }}"
|
init_config_overrides: "{{ neutron_vpn_agent_init_overrides }}"
|
||||||
@ -445,7 +445,7 @@ neutron_services:
|
|||||||
group: neutron_server
|
group: neutron_server
|
||||||
service_name: neutron-server
|
service_name: neutron-server
|
||||||
service_en: True
|
service_en: True
|
||||||
execstarts: "{{ neutron_bin }}/neutron-server --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/{{ neutron_plugins[neutron_plugin_type].plugin_ini }} --log-file={{ neutron_log_dir }}/neutron-server.log"
|
execstarts: "{{ neutron_bin }}/neutron-server --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/{{ neutron_plugins[neutron_plugin_type].plugin_ini }}"
|
||||||
init_config_overrides: "{{ neutron_server_init_overrides }}"
|
init_config_overrides: "{{ neutron_server_init_overrides }}"
|
||||||
start_order: 1
|
start_order: 1
|
||||||
calico-felix:
|
calico-felix:
|
||||||
@ -479,7 +479,7 @@ neutron_services:
|
|||||||
service_en: "{{ 'ml2.sriov' in neutron_plugin_types }}"
|
service_en: "{{ 'ml2.sriov' in neutron_plugin_types }}"
|
||||||
service_conf_path: "{{ neutron_conf_dir }}"
|
service_conf_path: "{{ neutron_conf_dir }}"
|
||||||
service_conf: plugins/ml2/sriov_nic_agent.ini
|
service_conf: plugins/ml2/sriov_nic_agent.ini
|
||||||
execstarts: "{{ neutron_bin }}/neutron-sriov-nic-agent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/plugins/ml2/ml2_conf.ini --config-file {{ neutron_conf_dir }}/plugins/ml2/sriov_nic_agent.ini --log-file={{ neutron_log_dir }}/neutron-sriov-nic-agent.log"
|
execstarts: "{{ neutron_bin }}/neutron-sriov-nic-agent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/plugins/ml2/ml2_conf.ini --config-file {{ neutron_conf_dir }}/plugins/ml2/sriov_nic_agent.ini"
|
||||||
config_overrides: "{{ neutron_sriov_nic_agent_ini_overrides }}"
|
config_overrides: "{{ neutron_sriov_nic_agent_ini_overrides }}"
|
||||||
config_type: "ini"
|
config_type: "ini"
|
||||||
init_config_overrides: "{{ neutron_sriov_nic_agent_init_overrides }}"
|
init_config_overrides: "{{ neutron_sriov_nic_agent_init_overrides }}"
|
||||||
@ -499,7 +499,7 @@ neutron_services:
|
|||||||
service_conf_path: "{{ neutron_conf_dir }}"
|
service_conf_path: "{{ neutron_conf_dir }}"
|
||||||
service_conf: networking_ovn_metadata_agent.ini
|
service_conf: networking_ovn_metadata_agent.ini
|
||||||
service_rootwrap: rootwrap.d/ovn-plugin.filters
|
service_rootwrap: rootwrap.d/ovn-plugin.filters
|
||||||
execstarts: "{{ neutron_bin }}/networking-ovn-metadata-agent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/plugins/ml2/ml2_conf.ini --config-file {{ neutron_conf_dir }}/networking_ovn_metadata_agent.ini --log-file=/var/log/neutron/networking-ovn-metadata-agent.log"
|
execstarts: "{{ neutron_bin }}/networking-ovn-metadata-agent --config-file {{ neutron_conf_dir }}/neutron.conf --config-file {{ neutron_conf_dir }}/plugins/ml2/ml2_conf.ini --config-file {{ neutron_conf_dir }}/networking_ovn_metadata_agent.ini"
|
||||||
config_overrides: "{{ neutron_ovn_metadata_agent_ini_overrides }}"
|
config_overrides: "{{ neutron_ovn_metadata_agent_ini_overrides }}"
|
||||||
config_type: "ini"
|
config_type: "ini"
|
||||||
init_config_overrides: "{{ neutron_ovn_metadata_agent_init_overrides }}"
|
init_config_overrides: "{{ neutron_ovn_metadata_agent_init_overrides }}"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user