Skip to main content
Share Your Experience: Take the 2024 Developer Survey

Questions tagged [journald]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
0 answers
5 views

journalctl pager breaks after suspend and return to foreground

This has finally annoyed me enough to look and up and I can find nothing. When using journalctl under Ubuntu 22.04 LTS specifically, if I suspend the process using ^Z and then bring it back to the ...
rand'Chris's user avatar
0 votes
0 answers
42 views

systemd-journald for separate log namespace exits after 30s

I am trying to configure an additional systemd-journald / log namespace (on Debian bookworm) for the first time (because it seems to be the only possibility to configure different log storage amounts ...
Hauke Laging's user avatar
  • 5,355
0 votes
0 answers
373 views

How to log systemd output to container logs

I run a rootless container system container with podman, i.e. systemd is running inside the container as entrypoint. I cannot figure out, though, how I can get the logs of the container, i.e. output ...
omgold's user avatar
  • 1
0 votes
1 answer
232 views

How to forward logs from syslog-ng to journald?

journald does everything I need except listen on the UDP port. I want to use syslog-ng as a forwarder from the UDP port to journald. There's a simple program called 'udp514-journal' that can handle ...
avi9526's user avatar
  • 175
1 vote
1 answer
2k views

Issue with sshd logfile using fail2ban on minimal Ubuntu server 22.04

I am working on trying to get fail2ban set up and enabled for sshd on my VPS with Ionos. I am using a minimal Ubuntu 22.04 server install. fail2ban has installed fine, but getting it to run seems a ...
Sorin Orii's user avatar
0 votes
1 answer
152 views

How can I monitor journald to invoke a program on a condition?

Before I reinvent the wheel and start scripting, is there a simple way (or existing tool) that can watch the systemd journal and take actions when certain log entries or conditions are detected? ...
Nick's user avatar
  • 4,636
0 votes
1 answer
322 views

systemd-journal-remote strange behavior

I have systemd v253 running on Fedora 38. My journal-remote.conf file is: [Remote] Seal=True SplitMode=host # .... MaxUse=5G KeepFree=10G MaxFiles=500 and my full journald.conf is: [Journal] Storage=...
Mirimat's user avatar
2 votes
1 answer
519 views

Postfix: How to log to syslog only?

I have Postfix 3.8.1 on Ubuntu 23.10. How do I configure Postfix to log to syslog only? My syslog daemon is journald. According to my understand, Postfix should log to syslog, if maillog_file is not ...
user2690527's user avatar
0 votes
1 answer
777 views

How do I disable logging from systemd when I login

My journald log contains lots of messages of this kind: Jun 03 11:38:37 test1 systemd[225427]: pam_unix(systemd-user:session): session opened for user user(uid=1000) by (uid=0) Jun 03 11:38:37 test1 ...
jurgen's user avatar
  • 139
4 votes
1 answer
1k views

Systemd service not logging

I have a systemd service. No logs appear from it despite my best efforts. This is the service file: [Unit] Description=Load Balancer [Service] WorkingDirectory=/home/lb ExecStart=/usr/lib/jvm/jdk-20/...
jurgen's user avatar
  • 139
0 votes
1 answer
573 views

When logging out to journald, when would you use a library and when would you use systemd config options to pipe StdOut/StdErr to journald

I've found library's that allow logging out to journald which suggests that, yes you should use a library where possible and log to journald from inside your app. But then there are tools like systemd-...
Thermatix's user avatar
  • 115
0 votes
1 answer
48 views

Why python-journald-rsyslog seems to batch/dely log write?

I intend to log a python script output. Here what it looks like : arm@stackoverflow > cat test.py #!/usr/bin/python from time import sleep while True: print("Hello") sleep(...
moutonjr's user avatar
  • 498
0 votes
1 answer
551 views

Rotate Logs of systemd-journal-remote

I am running Ubuntu 22.02 with systemd-journal-remote version 249.11-0ubuntu3.6. The hard drive was full because log rotation was not set-up. To manage file size of journals I updated my config at /...
antonio's user avatar
  • 21
0 votes
1 answer
293 views

define custom fields for systemd-journald

The doc states, it may be possible to define new fields by applications. What does it mean? Can one define arbitrary fields or are only those possible listed in the doc USER JOURNAL FIELDS? If ...
woodz's user avatar
  • 146
1 vote
0 answers
238 views

Systemd service stdout incompletely captured by systemd journal

I have a trivial systemd service (called "testpath") which simply prints some output to be captured by the journal. The journal is intermittently and unpredictably losing part of the output. ...
Dave Hughes's user avatar
0 votes
0 answers
484 views

Redirect systemd service logs to /dev/kmsg for all running services

Currently systemd service files will redirect the logs to journal buffer by default. But I need to get all the userspace services logs as part of /dev/kmsg buffer. I was able to add StandardOutput=...
Rckzz's user avatar
  • 1
2 votes
1 answer
1k views

Systemd service logs twice when it stops & starts. Anyway to disable?

I have a systemd (v249) service (my-script.service) which is run every minute by another systemd timer (my-script.timer). Everything's working fine. But systemd logs (to it's journald & thence to /...
Amandasaurus's user avatar
  • 32.4k
2 votes
1 answer
1k views

How to send a systemd ssh error so that it's picked by fail2ban

I have a setup which uses ansible and vagrant to test a custom role which installs and configures fail2ban. I have written myself a simple test playbook which uses the fail2ban role and applies the ...
tftd's user avatar
  • 1,540
6 votes
3 answers
10k views

systemd StandardOutput to a file _and_ to the journal?

I am regularly doing a long running (~5 day) data processing programme. I'm using Ubuntu and running the command with a systemd transient task via systemd-run --unit data_import /path/to/my-script.sh. ...
Amandasaurus's user avatar
  • 32.4k
0 votes
0 answers
1k views

systemd journal - delete logs belonging to a specified unit?

Like there is a way to show all logs belonging to a unit: journalctl -xu <unit>, Is there a way to clear the logs belonging to a specified unit with journalctl ? Actually, my problem is, one of ...
Ani's user avatar
  • 32
3 votes
1 answer
3k views

Set INFO/ERROR priority for messages logged to journal via stdout and stderr?

We have many production apps (first and third-party) that leave logging up to the process that runs the app and just log to stdout for INFO and stderr for ERROR logs (ie only 2 log priorities: INFO|...
mattpr's user avatar
  • 716
0 votes
1 answer
390 views

How do I stop journald from dropping blank lines?

I have an application which logs to stdout in a format like this: incoming request from x.x.x.x client version is 1.2 authenticated as [email protected] processed 1234 bytes closing connection ...
9072997's user avatar
  • 241
1 vote
0 answers
1k views

stop kernel audit messages logged in syslog without disabling auditing

OS: CentOS 7 I am trying to figure out how audit (kaudit) events are logged in /var/log/messages. I have enabled audit=1 in grub which means when the server boots, kernel auditing is enabled. This is ...
giomanda's user avatar
  • 1,854
0 votes
2 answers
581 views

systemd, journal receiving raw log

one common paradigm on all other syslog implementations (rsyslog, syslog-ng, readlog, etc) is to exchange log entries via UDP514 in plain text format. How do I enable systemd-journal-remote to receive ...
gcb's user avatar
  • 82
0 votes
0 answers
682 views

How to ensure output from "tee" is shown when used in a script run under systemd

I have a script that I'm running under systemd which has some debug logs that I'd like to send to both stdout (which should end up in the system journal, viewable with journalctl) as well as to a log ...
mgalgs's user avatar
  • 345
2 votes
1 answer
1k views

How I can send all logs from journald to GCP Logging?

Don't know what to add more to question, just want to send all logs. My applications write logs to journald, there is no files on disk. UPD. Just to clarify, there are files where journald store logs, ...
Raf's user avatar
  • 173
2 votes
0 answers
7k views

Service not logging to journalctl

I have a user service which is placed under /home/<user>/.config/systemd/user/<service>.service When I perform systemctl --user status <service> I have the desired output, for ...
Daniel's user avatar
  • 21
0 votes
0 answers
157 views

rsyslog seems to be triggering sdhci dumps when writing in external storage

Acording what I read, rsyslog is usually used to process logs and send them to another locations, either local (external storage, specific partition, etc.) or remote (logging server, for example). ...
jfernandz's user avatar
6 votes
1 answer
3k views

Is it safe to disable rsyslog if I have journald?

I am using Debian 10. It seems to me, that both journald and (r)syslogd watch for messages independently from sources such as kmesg() or syslog(). Is there any advantage to running both? Why does ...
markson edwardson's user avatar
3 votes
1 answer
3k views

Is there a way to make samba (smb,nmb) to not log start/stop events as error?

smbd and nmbd services log a lot of things as errors which clutters my journald logs when I filter it with journalctl -p 3. Is there a way to tell samba to not log start/stop/daemon_ready messages as ...
FieryRider's user avatar
1 vote
0 answers
214 views

Delete old SSH session recordings

Recently I've been testing SSH Session recording in Fedora + Cockpit as a method of auditing. This has been working pretty well, but it records too much information, and more importantly, picked up a ...
Alex's user avatar
  • 399
0 votes
0 answers
1k views

Make journalctl keep all logs forever (SystemMaxUse = unlimited)

How do I configure journald so that it never, ever, ever deletes my logs. Yes, what I want to do is tell journald to keep writing until the disk (read: /var partition's filesystem) is full. No, I don'...
Michael Altfield's user avatar
1 vote
0 answers
426 views

Connecting to systemd service's standard output/error

I have a simple systemd service that runs for some time and then exits. It usually gets triggered by a systemd timer but sometimes I want to run it manually (well, from a script). The problem is - I ...
Discussian's user avatar
2 votes
1 answer
1k views

journalctl --list-boots is not listing all boots

I have a Raspberry Pi running a custom Yocto image and it's using systemd-journald for logging. I'm wondering why there is a difference between: root@raspberrypi4:~# journalctl -o verbose | grep -e '...
evading's user avatar
  • 123
1 vote
2 answers
3k views

Best way to archive journald logs in a space-efficient way?

It has been established that journald logs are huge. On this specific system, the logs grow about 3GB per week. For audit purposes I would like to preserve system logs for a longer time than what can ...
liori's user avatar
  • 767
7 votes
0 answers
6k views

How do I specify a fail2ban filter/jail where the log is sourced from systemd/journald?

I've got nginx running and logging to systemd / journald. How do I specify the source of the log to be from a systemd unit? In man jail.conf I see for the backends listed as : systemd ...
Chris Stryczynski's user avatar
1 vote
2 answers
6k views

Podman rootless journald logging

I'm trying to log to the host's systemd-journald from a rootless podman-container. When i run the container as root with the --privileged flag, i can read the logs from the container on the host with ...
PManeCon's user avatar
1 vote
0 answers
111 views

Journal out of order

Trying to figure out what caused one of our servers (Ubuntu 18.04) to become unresponsive, I was looking through the journal ( journalctl -r) and saw strangely out of order timestamps Apr 17 09:20:...
SmoteKerrek's user avatar
1 vote
0 answers
2k views

Disable "Failed password" ssh logs

Bots are tirelessly trying to log into my server using ssh. That does not bother me, because my passwords are good, but I don't like the fact that ssh spam fills journald logs. I'd like to filter out ...
vbezhenar's user avatar
  • 273
6 votes
0 answers
4k views

journald memory usage on CentOS 7

I have an AWS EC2 instance running a CentOS 7.7.1908 (systemd 219) with a server application. The server logs quite a lot of information to the system logs (using syslog). I have recently enabled ...
MikaDo-'s user avatar
  • 61
1 vote
1 answer
4k views

Linux journalctl not synced with systemctl status / Journalctl not updating

I am running my custom service, let's call it "foo.service". It's a gunicorn python process which logs a few things. I used to be able to get a real-time log overview using journalctl -u <service&...
Dubb's user avatar
  • 113
0 votes
1 answer
1k views

RateLimitIntervalSec and RateLimitBurst in journald.conf are not working at all

I am trying to see how log drop count in the journald works. In the /etc/systemd/journald.conf file, I modified RateLimitIntervalSec to 1 second and the RateLimitBurst to 2 so that I can see some logs ...
susenj's user avatar
  • 101
15 votes
3 answers
16k views

Is rsyslog redundant on when using journald?

I have noticed log messages are duplicated in journald and /var/log/messages on my CentOS 7 system. At first I thought it was the journald option ForwardToSyslog (which defaults to 'yes' in the ...
joaerl's user avatar
  • 417
2 votes
1 answer
2k views

rcu_sched self-detected stall on CPU + watchdog: BUG: soft lockup - CPU#3 stuck for 22s

Being unable to ssh into a machine I connected it to a monitor and found the following: The machine is running Ubuntu Server 18.04 LTS and is a first generation 8 core Ryzen 1700. I've restarted the ...
Greg's user avatar
  • 1,687
5 votes
1 answer
5k views

systemd-journal Rate Limit

I have a service set up on CentOS 7 which outputs a lot of log messages, which results in this in the system log / journal: systemd-journal[xxxx]: Suppressed 864 messages from /system.slice/example....
David's user avatar
  • 51
1 vote
0 answers
982 views

journald forwarding to syslog seems to be lagged

I'm seeing an issue on a Ubuntu 16.04 box where the copying/forwarding of journal messages to /var/log/syslog seems to be delayed: theuser@host:/etc/systemd$ sudo journalctl -n 1 && sudo tail ...
Jordan0Day's user avatar
2 votes
0 answers
158 views

sudo log entries don't show username on Debian Stretch

For some reason, the username of the user calling a command with sudo is not shown in the system log: $ journalctl -ef sudo[30160]: pam_unix(sudo:session): session opened for user root by (uid=0) ...
Strayer's user avatar
  • 121
1 vote
1 answer
383 views

`journalctl -f -m` does not interleave remote and local

I currently have a 2-server setup (3 servers in total, one still to be configured for this) with one server using systemd-journal-remote (.socket & .service) to collect all log entries from the ...
Shadowjonathan's user avatar
2 votes
2 answers
5k views

Clearing "/var/log/journal"

I want to clear my "/var/log/journal" directory. I'm using debian 8 root@nyc3-x8:/var/log# uname -a Linux nyc3-x8 3.16.0-4-amd64 #1 SMP Debian 3.16.36-1+deb8u2 (2016-10-19) x86_64 GNU/Linux And my ...
Goktug's user avatar
  • 23
5 votes
3 answers
26k views

System logs are empty (/var/log/messages; /var/log/secure; etc)

I found that rsyslog stopped writing on logs (messages; secure; cron;etc) System information: NAME="Red Hat Enterprise Linux Server" VERSION="7.4 (Maipo)" ID="rhel" ID_LIKE="fedora" VARIANT="Server" ...
BANJOSA's user avatar
  • 398