diff options
| -rw-r--r-- | custom/lvm-snapshots.nix | 4 | ||||
| -rw-r--r-- | hel.nix | 16 | ||||
| -rw-r--r-- | odin.nix | 8 |
3 files changed, 15 insertions, 13 deletions
diff --git a/custom/lvm-snapshots.nix b/custom/lvm-snapshots.nix index 29156988..04ab06f0 100644 --- a/custom/lvm-snapshots.nix +++ b/custom/lvm-snapshots.nix | |||
| @@ -82,7 +82,7 @@ in { | |||
| 82 | 82 | ||
| 83 | script = '' | 83 | script = '' |
| 84 | ( | 84 | ( |
| 85 | flock -xn 9 || exit 1 | 85 | flock -xn 9 -E 4 || exit 1 |
| 86 | 86 | ||
| 87 | lvcreate -s ${scfg.cowSize} --name ${snapshotName name} ${scfg.VG}/${scfg.LV} | 87 | lvcreate -s ${scfg.cowSize} --name ${snapshotName name} ${scfg.VG}/${scfg.LV} |
| 88 | 88 | ||
| @@ -96,6 +96,8 @@ in { | |||
| 96 | 96 | ||
| 97 | serviceConfig = with pkgs; { | 97 | serviceConfig = with pkgs; { |
| 98 | Type = "forking"; | 98 | Type = "forking"; |
| 99 | RestartForceExitStatus = [ "4" ]; | ||
| 100 | RestartSec = "5min"; | ||
| 99 | }; | 101 | }; |
| 100 | }) cfg.snapshots; | 102 | }) cfg.snapshots; |
| 101 | 103 | ||
| @@ -525,10 +525,10 @@ | |||
| 525 | paths = [ "/home/gkleen" ]; | 525 | paths = [ "/home/gkleen" ]; |
| 526 | prune = { | 526 | prune = { |
| 527 | "/home/gkleen" = | 527 | "/home/gkleen" = |
| 528 | [ "--keep-within 24H" | 528 | [ "--keep-within" "24H" |
| 529 | "--keep-daily 31" | 529 | "--keep-daily" "31" |
| 530 | "--keep-monthly 12" | 530 | "--keep-monthly" "12" |
| 531 | "--keep-yearly -1" | 531 | "--keep-yearly" "-1" |
| 532 | ]; | 532 | ]; |
| 533 | }; | 533 | }; |
| 534 | }; | 534 | }; |
| @@ -537,10 +537,10 @@ | |||
| 537 | paths = [ "/home/gkleen" ]; | 537 | paths = [ "/home/gkleen" ]; |
| 538 | prune = { | 538 | prune = { |
| 539 | "/home/gkleen" = | 539 | "/home/gkleen" = |
| 540 | [ "--keep-within 24H" | 540 | [ "--keep-within" "24H" |
| 541 | "--keep-daily 31" | 541 | "--keep-daily" "31" |
| 542 | "--keep-monthly 12" | 542 | "--keep-monthly" "12" |
| 543 | "--keep-yearly -1" | 543 | "--keep-yearly" "-1" |
| 544 | ]; | 544 | ]; |
| 545 | }; | 545 | }; |
| 546 | }; | 546 | }; |
| @@ -165,10 +165,10 @@ | |||
| 165 | prune = lib.genAttrs | 165 | prune = lib.genAttrs |
| 166 | ["raid6/mail" "raid6/home" "raid6/media" "raid6/root" "ssd-raid1/root"] | 166 | ["raid6/mail" "raid6/home" "raid6/media" "raid6/root" "ssd-raid1/root"] |
| 167 | (name: [ | 167 | (name: [ |
| 168 | "--keep-within 24H" | 168 | "--keep-within" "24H" |
| 169 | "--keep-daily 31" | 169 | "--keep-daily" "31" |
| 170 | "--keep-monthly 12" | 170 | "--keep-monthly" "12" |
| 171 | "--keep-yearly -1" | 171 | "--keep-yearly" "-1" |
| 172 | ]); | 172 | ]); |
| 173 | }; | 173 | }; |
| 174 | }; | 174 | }; |
