Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,10 @@ ssh commands for your existing nodes that store the {object_storage} data:
$ oc extract --confirm cm/swift-ring-files
$ $CONTROLLER1_SSH "tar -C /var/lib/config-data/puppet-generated/swift/etc/swift/ -xzf -" < swiftrings.tar.gz
$ $CONTROLLER1_SSH "systemctl restart tripleo_swift_*"
$ $CONTROLLER2_SSH "tar -C /var/lib/config-data/puppet-generated/swift/etc/swift/ -xzf -" < swiftrings.tar.gz
$ $CONTROLLER2_SSH "systemctl restart tripleo_swift_*"
$ $CONTROLLER3_SSH "tar -C /var/lib/config-data/puppet-generated/swift/etc/swift/ -xzf -" < swiftrings.tar.gz
$ $CONTROLLER3_SSH "systemctl restart tripleo_swift_*"
----

. Track the replication progress by using the `swift-dispersion-report` tool:
Expand Down
2 changes: 1 addition & 1 deletion tests/roles/swift_migration/tasks/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@
ansible.builtin.shell: |
{{ shell_header }}
CONTROLLER1_SSH="{{ controller1_ssh }}"
$CONTROLLER1_SSH "timeout 900s bash -c 'while \$(find /srv/node/ -type f -name \"*.db\" -o -name \"*.data\" | grep -q \".\"); do sleep 5; done'"
$CONTROLLER1_SSH "timeout 900s bash -c 'while \$(find /srv/node/ -ignore_readdir_race -type f -name \"*.db\" -o -name \"*.data\" | grep -q \".\"); do sleep 5; done'"

- name: remove standalone node from rings
ansible.builtin.shell: |
Expand Down
15 changes: 12 additions & 3 deletions tests/roles/swift_migration/tasks/rebalance_and_wait.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,23 @@
swift-ring-tool forced_rebalance
swift-ring-tool push'

- name: push rings to standalone and restart swift services
- name: push rings to controller nodes and restart swift services
ansible.builtin.shell: |
{{ shell_header }}
{{ oc_header }}
CONTROLLER1_SSH="{{ controller1_ssh }}"
CONTROLLER2_SSH="{{ controller2_ssh }}"
CONTROLLER3_SSH="{{ controller3_ssh }}"

oc extract --confirm cm/swift-ring-files
$CONTROLLER1_SSH "tar -C /var/lib/config-data/puppet-generated/swift/etc/swift/ -xzf -" < swiftrings.tar.gz
$CONTROLLER1_SSH "systemctl restart tripleo_swift_*"

for i in {1..3}; do
SSH_CMD="CONTROLLER${i}_SSH"
if [ ! -z "${!SSH_CMD}" ]; then
${!SSH_CMD} "tar -C /var/lib/config-data/puppet-generated/swift/etc/swift/ -xzf -" < swiftrings.tar.gz
${!SSH_CMD} "systemctl restart tripleo_swift_*"
fi
done

- name: wait until all replicas are 100% available after rebalance
ansible.builtin.shell: |
Expand Down