diff --git a/tasks/swift_storage_hosts_account.yml b/tasks/swift_storage_hosts_account.yml index a2073b89..a1efe8d5 100644 --- a/tasks/swift_storage_hosts_account.yml +++ b/tasks/swift_storage_hosts_account.yml @@ -35,9 +35,9 @@ system_user: "{{ swift_system_user_name }}" system_group: "{{ swift_system_group_name }}" service_home: "{{ swift_system_home_folder }}" - when: > - swift.replication_network is defined and - swift.replication_network != swift.storage_network + when: + - swift.replication_network is defined + - swift.replication_network != swift.storage_network # When using a replication network use a second server for dedicated replicator configuration # This will be a blank file if not using dedicated replication network to prevent errors @@ -61,6 +61,8 @@ system_group: "{{ swift_system_group_name }}" service_home: "{{ swift_system_home_folder }}" +# The auditor needs to point at the replicator configuration. +# When using a dedicated replication network that means the dedicated conf file. - include: swift_init_common.yml vars: program_name: "swift-account-auditor" @@ -69,6 +71,21 @@ system_user: "{{ swift_system_user_name }}" system_group: "{{ swift_system_group_name }}" service_home: "{{ swift_system_home_folder }}" + when: > + swift.replication_network is not defined or + swift.replication_network == swift.storage_network + +- include: swift_init_common.yml + vars: + program_name: "swift-account-auditor" + program_config_options: "{{ swift_account_replicator_program_config_options }}" + service_name: "{{ swift_service_name }}" + system_user: "{{ swift_system_user_name }}" + system_group: "{{ swift_system_group_name }}" + service_home: "{{ swift_system_home_folder }}" + when: + - swift.replication_network is defined + - swift.replication_network != swift.storage_network - include: swift_init_common.yml vars: @@ -100,9 +117,9 @@ mode: "0644" config_overrides: "{{ swift_account_server_replicator_conf_overrides }}" config_type: "ini" - when: > - swift.replication_network is defined and - swift.replication_network != swift.storage_network + when: + - swift.replication_network is defined + - swift.replication_network != swift.storage_network notify: Restart swift account services # Remove the dedicated replicator configuration when no dedicated replication network in use diff --git a/tasks/swift_storage_hosts_container.yml b/tasks/swift_storage_hosts_container.yml index ce4c1e60..953943df 100644 --- a/tasks/swift_storage_hosts_container.yml +++ b/tasks/swift_storage_hosts_container.yml @@ -35,9 +35,9 @@ system_user: "{{ swift_system_user_name }}" system_group: "{{ swift_system_group_name }}" service_home: "{{ swift_system_home_folder }}" - when: > - swift.replication_network is defined and - swift.replication_network != swift.storage_network + when: + - swift.replication_network is defined + - swift.replication_network != swift.storage_network # When using a replication network create a second server for dedicated replicator configuration # This will be a blank file if not using dedicated replication network to prevent errors @@ -61,6 +61,8 @@ system_group: "{{ swift_system_group_name }}" service_home: "{{ swift_system_home_folder }}" +# The auditor needs to point at the replicator configuration. +# # When using a dedicated replication network that means the dedicated conf file. - include: swift_init_common.yml vars: program_name: "swift-container-auditor" @@ -69,6 +71,21 @@ system_user: "{{ swift_system_user_name }}" system_group: "{{ swift_system_group_name }}" service_home: "{{ swift_system_home_folder }}" + when: > + swift.replication_network is not defined or + swift.replication_network == swift.storage_network + +- include: swift_init_common.yml + vars: + program_name: "swift-container-auditor" + program_config_options: "{{ swift_container_replicator_program_config_options }}" + service_name: "{{ swift_service_name }}" + system_user: "{{ swift_system_user_name }}" + system_group: "{{ swift_system_group_name }}" + service_home: "{{ swift_system_home_folder }}" + when: + - swift.replication_network is defined + - swift.replication_network != swift.storage_network - include: swift_init_common.yml vars: @@ -127,8 +144,8 @@ mode: "0644" config_overrides: "{{ swift_container_sync_realms_conf_overrides }}" config_type: "ini" - when: > - swift_container_sync_realms is defined + when: + - swift_container_sync_realms is defined notify: Restart swift container services # We only create the dedicated replicator configuration when using a dedicated replication_network @@ -141,9 +158,9 @@ mode: "0644" config_overrides: "{{ swift_container_server_replicator_conf_overrides }}" config_type: "ini" - when: > - swift.replication_network is defined and - swift.replication_network != swift.storage_network + when: + - swift.replication_network is defined + - swift.replication_network != swift.storage_network notify: Restart swift container services # Remove the dedicated replicator configuration when no dedicated replication network in use diff --git a/tasks/swift_storage_hosts_object.yml b/tasks/swift_storage_hosts_object.yml index 6d7b915d..5b9a250c 100644 --- a/tasks/swift_storage_hosts_object.yml +++ b/tasks/swift_storage_hosts_object.yml @@ -35,9 +35,9 @@ system_user: "{{ swift_system_user_name }}" system_group: "{{ swift_system_group_name }}" service_home: "{{ swift_system_home_folder }}" - when: > - swift.replication_network is defined and - swift.replication_network != swift.storage_network + when: + - swift.replication_network is defined + - swift.replication_network != swift.storage_network # When using a replication network use a second server for dedicated replicator configuration # This will be a blank file if not using dedicated replication network to prevent errors @@ -61,6 +61,8 @@ system_group: "{{ swift_system_group_name }}" service_home: "{{ swift_system_home_folder }}" +# The auditor needs to point at the replicator configuration. +# # When using a dedicated replication network that means the dedicated conf file. - include: swift_init_common.yml vars: program_name: "swift-object-auditor" @@ -69,6 +71,21 @@ system_user: "{{ swift_system_user_name }}" system_group: "{{ swift_system_group_name }}" service_home: "{{ swift_system_home_folder }}" + when: > + swift.replication_network is not defined or + swift.replication_network == swift.storage_network + +- include: swift_init_common.yml + vars: + program_name: "swift-object-auditor" + program_config_options: "{{ swift_object_replicator_program_config_options }}" + service_name: "{{ swift_service_name }}" + system_user: "{{ swift_system_user_name }}" + system_group: "{{ swift_system_group_name }}" + service_home: "{{ swift_system_home_folder }}" + when: + - swift.replication_network is defined + - swift.replication_network != swift.storage_network - include: swift_init_common.yml vars: @@ -118,9 +135,9 @@ mode: "0644" config_overrides: "{{ swift_object_server_replicator_conf_overrides }}" config_type: "ini" - when: > - swift.replication_network is defined and - swift.replication_network != swift.storage_network + when: + - swift.replication_network is defined + - swift.replication_network != swift.storage_network notify: Restart swift object services # Remove the dedicated replicator configuration when no dedicated replication network in use diff --git a/templates/account-server-replicator.conf.j2 b/templates/account-server-replicator.conf.j2 index f13af8bc..c974ade9 100644 --- a/templates/account-server-replicator.conf.j2 +++ b/templates/account-server-replicator.conf.j2 @@ -25,3 +25,6 @@ replication_server = True log_facility = LOG_LOCAL2 per_diff = 10000 reclaim_age = {{ reclaim_age | default(604800) }} + +[account-auditor] +log_facility = LOG_LOCAL2 diff --git a/templates/account-server.conf.j2 b/templates/account-server.conf.j2 index 2cbccba1..367ac54f 100644 --- a/templates/account-server.conf.j2 +++ b/templates/account-server.conf.j2 @@ -39,10 +39,10 @@ recon_lock_path = /var/lock log_facility = LOG_LOCAL2 per_diff = 10000 reclaim_age = {{ reclaim_age | default(604800) }} -{% endif %} [account-auditor] log_facility = LOG_LOCAL2 +{% endif %} [account-reaper] log_facility = LOG_LOCAL2 diff --git a/templates/container-server-replicator.conf.j2 b/templates/container-server-replicator.conf.j2 index 012c2d75..1222fa49 100644 --- a/templates/container-server-replicator.conf.j2 +++ b/templates/container-server-replicator.conf.j2 @@ -24,3 +24,6 @@ replication_server = True [container-replicator] log_facility = LOG_LOCAL3 reclaim_age = {{ reclaim_age | default(604800) }} + +[container-auditor] +log_facility = LOG_LOCAL3 diff --git a/templates/container-server.conf.j2 b/templates/container-server.conf.j2 index 65391092..5f8161a8 100644 --- a/templates/container-server.conf.j2 +++ b/templates/container-server.conf.j2 @@ -39,6 +39,9 @@ recon_lock_path = /var/lock [container-replicator] log_facility = LOG_LOCAL3 reclaim_age = {{ reclaim_age | default(604800) }} + +[container-auditor] +log_facility = LOG_LOCAL3 {% endif %} [container-updater] @@ -46,9 +49,6 @@ log_facility = LOG_LOCAL3 node_timeout = 15 conn_timeout = 5 -[container-auditor] -log_facility = LOG_LOCAL3 - [container-sync] [filter:xprofile] diff --git a/templates/object-server-replicator.conf.j2 b/templates/object-server-replicator.conf.j2 index fddce396..a6508ce1 100644 --- a/templates/object-server-replicator.conf.j2 +++ b/templates/object-server-replicator.conf.j2 @@ -28,3 +28,6 @@ reclaim_age = {{ reclaim_age | default(604800) }} {% if swift_rsync_module_per_drive %} rsync_module = {replication_ip}::object_{device} {% endif %} + +[object-auditor] +log_facility = LOG_LOCAL4 diff --git a/templates/object-server.conf.j2 b/templates/object-server.conf.j2 index be07c99d..65017531 100644 --- a/templates/object-server.conf.j2 +++ b/templates/object-server.conf.j2 @@ -44,6 +44,9 @@ reclaim_age = {{ reclaim_age | default(604800) }} {% if swift_rsync_module_per_drive %} rsync_module = {replication_ip}::object_{device} {% endif %} + +[object-auditor] +log_facility = LOG_LOCAL4 {% endif %} [object-updater] @@ -53,8 +56,5 @@ concurrency = 3 node_timeout = 60 conn_timeout = 5 -[object-auditor] -log_facility = LOG_LOCAL4 - [filter:xprofile] use = egg:swift#xprofile