about summary refs log tree commit diff
path: root/nixos/modules/config/zram.nix
Commit message (Collapse)AuthorAge
* zram: revert "change default algorithm to zstd" (#56856)Danylo Hlynskyi2019-03-07
| | | | 19.03 default kernel is still 4.14, which doesn't support zstd. So, zramSwap in current fasion fails on default kernel.
* zramSwap: remove basic.target for zram devicesdanbst2019-01-17
| | | | | | | | | This creates a dependency cycle when used with boot.tmpOnTmpfs: basic.target <- tmp.mount <- swap.target <- zram-init-dev0 <- basic.target This same fix is done already for tmp.mount Fixes https://github.com/NixOS/nixpkgs/issues/47474
* zramSwap: allow configure compression algorithm + cleanupsdanbst2019-01-17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - add `zramSwap.algorithm` option, which allows to change compressor declaratively. zstd as default - add `zramSwap.swapDevices` option, which allows to define how many zram devices will be used as swap. Rest devices can be managed freely - simpler floating calculations - fix udev race condition - some documentation changes - replaced `/sys/block/zram*` handling with `zramctl`, because I had occasional "Device is busy" error (looks like zram has to be configured in predefined order) - added `memoryPercent` and `algorithm` as restart triggers. I think, it was a bug that changing `memoryPercent` in configuration wasn't applied immediately. - removed a bind to .swap device. While it looks natural (when swap device goes off, so should zram device), it wasn't implemented properly. This caused problems with swapon/swapoff: ``` $ cat /proc/swaps Filename Type Size Used Priority /dev/zram0 partition 8166024 0 -2 /var/swapfile file 5119996 5120 1 $ sudo swapoff -a $ sudo swapon -a swapon: /dev/zram0: read swap header failed $ cat /proc/swaps Filename Type Size Used Priority /var/swapfile file 5119996 0 1 ```
* zramSwap: remove mentions of old kernelsWout Mertens2018-04-19
|
* zramSwap: default to 1 deviceWout Mertens2018-04-19
| | | One device per cpu is only needed for kernel 3.14
* nixos: Move uses of stdenv.shell to runtimeShell.Shea Levy2018-03-01
|
* modprobe service: drop kmod wrapperNikolay Amiantov2016-08-19
|
* Revert "Merge branch 'modprobe-fix' of git://github.com/abbradar/nixpkgs"Shea Levy2016-08-15
| | | | | | | Was meant to go into staging, sorry This reverts commit 57b2d1e9b0dcdd1d25bd2d450174764b9417ffc1, reversing changes made to 760b2b9048ea775c319cb348d74447a20dea513e.
* modprobe service: drop kmod wrapperNikolay Amiantov2016-08-16
|
* zram: simplified totalmem calculation for zram.nixRoger Qiu2016-01-29
|
* nixos: Add zram swap moduleRicardo M. Correia2014-05-06
This allows you to use the Linux kernel's built-in compressed memory as swap space functionality. It is recommended to enable only for kernel 3.14 (which is when zram came out of the staging drivers area) or higher.