Closed roalyr closed 2 years ago
Can confirm this bug on Ubuntu 20.04.3 LTS. The log seem to be the same as above.
Someone on discord commented that this may be related to swap not being properly stopped on shutdow. I am not sure. Maybe it has something to do with poor timing during boot since the issue is appearing at random?
I just restart a bunch of times to see if it failed, and it failed everytime. So maybe on Ubuntu 20.04.3 LTS it is a different problem? Anyway, I make a wild guess that maybe the zram module somehow not loaded on time (?), so I added the zram module to initramfs module list, and now it seem to successfully create the swap. Note that I have no idea what I'm doing, so please do not consider this as a solution without some (or a lot) more investigation.
I've forked this repo and found that https://github.com/britishbadger/zram-swap/commit/3adea21997fc0acc40a807f868576ff6a58665ec the following options seem to result in everything starting correctly from boot.
Thank you, will test ASAP.
I've forked this repo and found that britishbadger@3adea21 the following options seem to result in everything starting correctly from boot.
@britishbadger it fails to start still, but the frequency is much lower now, around 1 in 10-15 boots.
-- Boot 730c7bfada7148d69467d7375ca7ec19 --
січ 01 13:19:41 roalyr-Lenovo-V14-ADA systemd[1]: Starting zram swap service...
січ 01 13:19:42 roalyr-Lenovo-V14-ADA zram-swap.sh[672]: zramctl: /dev/zram0: failed to reset: Device or resource busy
січ 01 13:19:42 roalyr-Lenovo-V14-ADA zram-swap.sh[748]: zramctl: /dev/zram0: failed to reset: Device or resource busy
січ 01 13:19:42 roalyr-Lenovo-V14-ADA zram-swap.sh[813]: zramctl: /dev/zram0: failed to reset: Device or resource busy
січ 01 13:19:42 roalyr-Lenovo-V14-ADA zram-swap.sh[615]: Err init: Failed to initialize zram device
січ 01 13:19:42 roalyr-Lenovo-V14-ADA systemd[1]: zram-swap.service: Main process exited, code=exited, status=1/FAILURE
січ 01 13:19:42 roalyr-Lenovo-V14-ADA systemd[1]: zram-swap.service: Failed with result 'exit-code'.
січ 01 13:19:42 roalyr-Lenovo-V14-ADA systemd[1]: Failed to start zram swap service.
So far no more, it seems.
No more failures since last report.
Lenovo-V14-ADA 5.11.0-40-generic #44-Ubuntu SMP Wed Oct 20 16:16:42 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux Xubuntu 21.04
Every now and then service fails to start when computer boots up. I have started noticing it around this month only. Roughly 1 in 5-10 boots, without any apparent pattern.