From: Lennart Poettering Date: Mon, 18 Sep 2023 08:41:50 +0000 (+0200) Subject: logind: slightly tweak error message about not enough swap for hibernation X-Git-Tag: v255-rc1~514 X-Git-Url: http://git-history.diyao.me/?a=commitdiff_plain;h=43cb0f3e46882500bc6d7866868456d7388f7437;p=systemd%2F.git logind: slightly tweak error message about not enough swap for hibernation Let's tweak the message if not enough swap is around slightly: systems might have plenty swap backed by incompatible storage (specifically: swap files on btrfs), but we (currently) do not support hibernating to that. Hence let's say *suitable* swap space and talk about *compatibility* of backing storage. Hopefully this will make things a bit clearer to users. Prompted by: #29189 --- diff --git a/src/login/logind-dbus.c b/src/login/logind-dbus.c index e35005e262..23bf4b8c20 100644 --- a/src/login/logind-dbus.c +++ b/src/login/logind-dbus.c @@ -1926,7 +1926,7 @@ static int method_do_shutdown_or_sleep( r = can_sleep(a->sleep_operation); if (r == -ENOSPC) return sd_bus_error_set(error, BUS_ERROR_SLEEP_VERB_NOT_SUPPORTED, - "Not enough swap space for hibernation"); + "Not enough suitable swap space for hibernation available on compatible block devices and file systems"); if (r == 0) return sd_bus_error_setf(error, BUS_ERROR_SLEEP_VERB_NOT_SUPPORTED, "Sleep verb \"%s\" not supported",