From 2f8c408a9047df28e3d1cbd186378ea13d27b81a Mon Sep 17 00:00:00 2001 From: Giulio Fidente Date: Tue, 7 Jul 2020 23:47:12 +0200 Subject: [PATCH] Configure rsyncd without pid file for Swift There are known issues with stale pid file handling in rsyncd [1], which by consequence cause Swift to not start. This change disables use of pid file completely when deployed by the swift-storage conainer and depends on the addition of such a feature in the puppetlabs-rsync module [2] 1. https://www.mail-archive.com/rsync@lists.samba.org/msg32735.html 2. https://github.com/puppetlabs/puppetlabs-rsync/pull/120 Closes-Bug: 1896605 Change-Id: I81ad92793b8f115c046a678f4b2cc51d1014e3b6 (cherry picked from commit 43b5b0875d07bd3db29e83661aa32742dbef3544) (cherry picked from commit af26d0ff3518c53394dad7a9c0349adc132b05f3) --- .../swift/swift-storage-container-puppet.yaml | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) diff --git a/deployment/swift/swift-storage-container-puppet.yaml b/deployment/swift/swift-storage-container-puppet.yaml index ea5cdd55fc..abc805f0a3 100644 --- a/deployment/swift/swift-storage-container-puppet.yaml +++ b/deployment/swift/swift-storage-container-puppet.yaml @@ -163,6 +163,7 @@ outputs: "%{hiera('$NETWORK')}" params: $NETWORK: {get_param: [ServiceNetMap, SwiftStorageNetwork]} + rsync::server::pid_file: 'UNSET' - if: - account_workers_zero @@ -310,16 +311,6 @@ outputs: command: ['chown', '-R', 'swift:', '/srv/node'] volumes: - /srv/node:/srv/node:z - # FIXME (cschwede): remove this once the pid file setting is disabled - swift_rsync_fix: - start_order: 1 - image: {get_param: ContainerSwiftObjectImage} - net: host - user: root - detach: false - command: ['/bin/bash', '-c', 'sed -i "/pid file/d" /var/lib/kolla/config_files/src/etc/rsyncd.conf'] - volumes: - - /var/lib/config-data/puppet-generated/swift:/var/lib/kolla/config_files/src:rw,z step_4: map_merge: - if: @@ -673,10 +664,6 @@ outputs: - rsyslog_config is changed - rsyslog_config.rc == 0 update_tasks: - - name: Ensure rsyncd pid file is absent - file: - path: /var/run/rsyncd.pid - state: absent - name: Check swift containers log folder/symlink exists stat: path: /var/log/containers/swift