From: Daan De Meyer Date: Mon, 8 Apr 2024 16:00:35 +0000 (+0200) Subject: Log when we can't rename in move_tree() X-Git-Tag: v23~19 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3f61cdb81d579d92612253fb2d8ed464745e77ec;p=thirdparty%2Fmkosi.git Log when we can't rename in move_tree() Can help explain why mkosi is slower than it should be. --- diff --git a/mkosi/tree.py b/mkosi/tree.py index 53a8ae550..73dfca645 100644 --- a/mkosi/tree.py +++ b/mkosi/tree.py @@ -2,6 +2,7 @@ import contextlib import errno +import logging import shutil import subprocess import tempfile @@ -187,6 +188,9 @@ def move_tree( if e.errno != errno.EXDEV: raise e + logging.info( + f"Could not rename {src} to {dst} as they are located on different devices, falling back to copying" + ) copy_tree(src, dst, use_subvolumes=use_subvolumes, tools=tools, sandbox=sandbox) rmtree(src, tools=tools, sandbox=sandbox)