Public bug reported:
Bcache and suspend do not really go hand in hand. See
http://bcache.evilpiepirate.org/FAQ/ for more details.
It boils down to simply disable caching mode before suspend and re-
enable it after suspend. I wrote the following script and it should be
part of bcache-tools since installing bcache-tools implies bcache might
be in use.
The only really 'big' downside is, we always restore to writethrough
mode, I guess we could store the state on suspend in /tmp and restore on
resume if this is really needed.
cat /lib/systemd/system-sleep/bcache.sh
#!/bin/sh
if [ "$1" = "pre" ]; then
for cache in /sys/block/bcache*; do
echo "none" > ${cache}/bcache/cache_mode
done
fi
if [ "$1" = "post" ]; then
for cache in /sys/block/bcache*; do
echo "writethrough" > ${cache}/bcache/cache_mode
done
fi
** Affects: bcache-tools (Ubuntu)
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1515780
Title:
bcache does not work with suspend
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/bcache-tools/+bug/1515780/+subscriptions
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs