File tree Expand file tree Collapse file tree 3 files changed +13
-19
lines changed Expand file tree Collapse file tree 3 files changed +13
-19
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change 15
15
- name : reload systemd
16
16
shell : systemctl daemon-reload
17
17
when : systemd.stat.exists == true and mongodb_manage_service
18
+
19
+ - name : restart sysfsutils
20
+ service : name=sysfsutils state=restarted
Original file line number Diff line number Diff line change 75
75
template : src=mongod.conf.j2 dest=/etc/mongod.conf backup=yes owner=root group=root mode=0644
76
76
register : config_result
77
77
78
- - name : Install disable_thp script
79
- copy : src=disable_thp.sh dest=/usr/local/bin/disable_thp.sh mode='u=rwx,g=rx,o=rx'
78
+ - name : Install sysfsutils package
79
+ apt : name=sysfsutils state=present
80
80
when : ansible_os_family == 'Debian' and mongodb_disable_thp
81
81
82
- - name : Disable Linux transparent hugepages now
83
- command : /usr/local/bin/disable_thp.sh
84
- when : ansible_os_family == 'Debian' and mongodb_disable_thp
85
-
86
- - name : Disable Linux transparent hugepages on boot
87
- lineinfile : dest=/etc/rc.local regexp='/usr/local/bin/disable_thp.sh' line='if test -f '/usr/local/bin/disable_thp.sh'; /usr/local/bin/disable_thp.sh; fi'
82
+ - name : Create sysfs config
83
+ copy :
84
+ src : hugepages.conf
85
+ dest : /etc/sysfs.d/hugepages.conf
86
+ owner : root
87
+ group : root
88
+ mode : 0644
88
89
when : ansible_os_family == 'Debian' and mongodb_disable_thp
90
+ notify : restart sysfsutils
89
91
90
92
- name : get pid of mongod
91
93
command : pidof mongod
You can’t perform that action at this time.
0 commit comments