From 10937c93d42dc8feec0930681d910ab0282e47ff Mon Sep 17 00:00:00 2001 From: colin Date: Sun, 12 Jun 2022 15:26:33 -0700 Subject: [PATCH] duplicity: attempt to limit bandwidth --- modules/services/duplicity.nix | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/modules/services/duplicity.nix b/modules/services/duplicity.nix index af1e99bc..7c6c2d78 100644 --- a/modules/services/duplicity.nix +++ b/modules/services/duplicity.nix @@ -58,5 +58,15 @@ in # set this for the FIRST backup, then remove it to enable incremental backups # (that the first backup *isn't* full i think is a defect) # services.duplicity.fullIfOlderThan = "always"; + + systemd.services.duplicity.serviceConfig = { + # rate-limit the read bandwidth in an effort to thereby prevent net upload saturation + # this could perhaps be done better by adding a duplicity config option to replace the binary with `trickle` + IOReadBandwidthMax = [ + "/dev/sda1 5M" + "/dev/nvme0n1 5M" + "/dev/mmc0 5M" + ]; + }; }; }