sd_journal does not handle journal moving to persistent logging

Open
#8,262 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
35/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
c, linux

Research direction

Reproduce the transition with journalctl -f, mkdir /var/log/journal/, journalctl --flush, and logger foo. Start at the sd_journal API behavior while journald moves from runtime to persistent logging; done means API consumers receive the new logs after the move.

Written by the indexing model from the issue text.

Description

downstream/rhel journal
Submission type
  • Bug report
systemd version the issue has been seen with

latest upstream, but it never worked

In case of bug report: Expected behaviour you didn't see

When we have a runtime journal, and we create /var/log/journal/, journald will start to log there, but anything that uses sd_journal api will not get the new logs.

In case of bug report: Steps to reproduce the problem

journalctl -f
mkdir /var/log/journal/ ; journalctl --flush ; logger foo

Dominant language
C
Stars
16.7k
Forks
4.7k
Avg merge
1d 6h
Merged PRs (30d)
140

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from systemd/systemd

All issues in systemd/systemd

Similar issues

More C issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.