Files
poky/meta/recipes-devtools/dnf/dnf/0001-dnf-write-the-log-lock-to-root.patch
Alexander Kanavin d197957750 dnf: upgrade 4.18.2 -> 4.19.0
(From OE-Core rev: f6241428aaf54e540795efc64844cab5acd9629b)

Signed-off-by: Alexander Kanavin <alex@linutronix.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2024-03-07 17:25:02 +00:00

30 lines
1.2 KiB
Diff

From 049e2832284ab883e185d9020c881518a68e6c38 Mon Sep 17 00:00:00 2001
From: Alexander Kanavin <alex.kanavin@gmail.com>
Date: Tue, 28 Apr 2020 15:55:00 +0200
Subject: [PATCH] dnf: write the log lock to root
Writing it to /var/log appears to be racing with installation
of base-files, and if lock is created first, base-files
will refuse to install (due to the target directory
already existing, and base-files creating it as a symlink).
Upstream-Status: Inappropriate [oe-core specific]
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
---
dnf/logging.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dnf/logging.py b/dnf/logging.py
index ef0b25f3..94610af6 100644
--- a/dnf/logging.py
+++ b/dnf/logging.py
@@ -118,7 +118,7 @@ class MultiprocessRotatingFileHandler(logging.handlers.RotatingFileHandler):
def __init__(self, filename, mode='a', maxBytes=0, backupCount=0, encoding=None, delay=False):
super(MultiprocessRotatingFileHandler, self).__init__(
filename, mode, maxBytes, backupCount, encoding, delay)
- self.rotate_lock = dnf.lock.build_log_lock("/var/log/", True)
+ self.rotate_lock = dnf.lock.build_log_lock("/", True)
def emit(self, record):
while True: