From 7c8d38f91e7bd4aed106aacc78eb454789538c31 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Thu, 6 Jun 2024 23:25:55 +0200 Subject: services: Never throw when stopping mount-may-fail file systems. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is a followup to 7c27bd115b14afd142da7684cc349369965f9eab. * gnu/services/base.scm (file-system-shepherd-service): Catch 'system-error from ‘umount’ call when FILE-SYSTEM is marked as mount-may-fail. Change-Id: I2234f8da320b43089f4ee058cad8608ce9c078f8 --- gnu/services/base.scm | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'gnu/services') diff --git a/gnu/services/base.scm b/gnu/services/base.scm index 2d6b0f00e0..c7a14c7ed4 100644 --- a/gnu/services/base.scm +++ b/gnu/services/base.scm @@ -448,7 +448,11 @@ upon boot." ;; Make sure PID 1 doesn't keep TARGET busy. (chdir "/") - (umount #$target) + #$(if (file-system-mount-may-fail? file-system) + #~(catch 'system-error + (lambda () (umount #$target)) + (const #f)) + #~(umount #$target)) #f)) ;; We need additional modules. -- cgit v1.2.3