Only scrub when plugged in on Linux, and TCP optimization.

This commit is contained in:
Tom Alexander
2024-05-16 21:20:30 -04:00
parent ee0fe7eca6
commit f44074ebe7
3 changed files with 53 additions and 11 deletions

View File

@@ -61,3 +61,26 @@
name: "zfs-scrub-weekly@{{ item }}.timer"
daemon_reload: yes
loop: "{{ periodic_scrub_pools }}"
- name: Create directories
when: periodic_scrub_pools is defined
file:
name: "{{ item }}"
state: directory
mode: 0755
owner: root
group: wheel # Normally it is "root"
loop:
- /etc/systemd/system/zfs-scrub-weekly@.timer.d
- name: Install Configuration
when: periodic_scrub_pools is defined
copy:
src: "files/{{ item.src }}"
dest: "{{ item.dest }}"
mode: 0644
owner: root
group: wheel # Normally it is "root"
loop:
- src: linux_scrub_when_plugged_in.conf
dest: /etc/systemd/system/zfs-scrub-weekly@.timer.d/override.conf