diff options
author | Peter Hoeg <peter@hoeg.com> | 2017-10-14 14:42:22 +0800 |
---|---|---|
committer | Peter Hoeg <peter@hoeg.com> | 2017-10-14 14:42:49 +0800 |
commit | e01bb0c0d05e29b764fa090d85ec5babd03c84b8 (patch) | |
tree | 570b169b0d2f569702920aaa6162d4352085ba99 /nixos/modules/services/monitoring/smartd.nix | |
parent | f22ce20ec0ecb29e8b1f1b08170276f6fe54c589 (diff) | |
download | nixpkgs-e01bb0c0d05e29b764fa090d85ec5babd03c84b8.tar nixpkgs-e01bb0c0d05e29b764fa090d85ec5babd03c84b8.tar.gz nixpkgs-e01bb0c0d05e29b764fa090d85ec5babd03c84b8.tar.bz2 nixpkgs-e01bb0c0d05e29b764fa090d85ec5babd03c84b8.tar.lz nixpkgs-e01bb0c0d05e29b764fa090d85ec5babd03c84b8.tar.xz nixpkgs-e01bb0c0d05e29b764fa090d85ec5babd03c84b8.tar.zst nixpkgs-e01bb0c0d05e29b764fa090d85ec5babd03c84b8.zip |
Revert "smartd: set drive timeout"
This reverts commit 41306ca50580d66591058211676c463fcb30a2fd.
Diffstat (limited to 'nixos/modules/services/monitoring/smartd.nix')
-rw-r--r-- | nixos/modules/services/monitoring/smartd.nix | 31 |
1 files changed, 3 insertions, 28 deletions
diff --git a/nixos/modules/services/monitoring/smartd.nix b/nixos/modules/services/monitoring/smartd.nix index 5dcd99a1e71..4d10299a987 100644 --- a/nixos/modules/services/monitoring/smartd.nix +++ b/nixos/modules/services/monitoring/smartd.nix @@ -81,32 +81,13 @@ let description = "Options that determine how smartd monitors the device."; }; - timeout = mkOption { - default = -1; - example = "70"; - type = types.int; - description = '' - Set SCT Error Recovery Control timeout in deciseconds for use in raid configurations. - - Values are as follows: - -1 = do not touch, leave at default - 0 = disable SCT ERT - 70 = default in consumer drives (7 seconds) - - Maximum is disk dependant but probably 60 seconds. - ''; - }; - }; }; - deviceTimeout = d: - lib.optionalString (d.timeout > -1) '' - ${pkgs.smartmontools}/bin/smartctl -l scterc,${d.timeout},${d.timeout} --silent errorsonly ${d.device} - ''; +in -in { +{ ###### interface options = { @@ -241,13 +222,7 @@ in { path = [ pkgs.nettools ]; # for hostname and dnsdomanname calls in smartd - serviceConfig = { - ExecStartPre = '' - ${concatMapStringsSep "\n" deviceTimeout cfg.devices} - ''; - ExecStart = "${pkgs.smartmontools}/sbin/smartd --no-fork --configfile=${smartdConf}"; - }; - + serviceConfig.ExecStart = "${pkgs.smartmontools}/sbin/smartd --no-fork --configfile=${smartdConf}"; }; }; |