Skip to content

Commit c41cbef

Browse files
Zuulopenstack-gerrit
authored andcommitted
Merge "Fix permission denied errors with ping on c8s" into stable/wallaby
2 parents 8d50d7b + 735b094 commit c41cbef

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

ansible/roles/baremetal/tasks/pre-install.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,15 @@
4141
- inventory_hostname not in groups['bifrost'] or
4242
hostvars[inventory_hostname]['api_interface'] | replace('-', '_') in hostvars[inventory_hostname].ansible_facts
4343

44+
- name: Ensure unprivileged users can use ping
45+
become: true
46+
sysctl:
47+
name: net.ipv4.ping_group_range
48+
value: '0 2147483647'
49+
state: present
50+
sysctl_file: "{{ kolla_sysctl_conf_path }}"
51+
when: ansible_facts.os_family == 'RedHat'
52+
4453
# NOTE(osmanlicilegi): The distribution might come with cloud-init installed, and manage_etc_hosts
4554
# configuration enabled. If so, it will override the file /etc/hosts from cloud-init templates at
4655
# every boot, which will break RabbitMQ. To prevent this happens, first we check whether cloud-init

roles/multi-node-managed-addressing/tasks/main.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@
6666
- managed_network_address_family == 'ipv6'
6767

6868
- name: Ping across the managed network
69+
become: true
6970
vars:
7071
ping_command: "{{ 'ping' if managed_network_address_family == 'ipv4' else 'ping6' }}"
7172
command: "{{ ping_command }} -c1 {{ hostvars[item].managed_interface_address }}"

0 commit comments

Comments
 (0)