Skip to content

systemd log output adds extra newline #9086

Closed

Description

@j-vizcaino

What is the problem you are having with rclone?

Using --log-systemd to send RCLone logs to journald leads to logs having an extra \n

It appears the endline is added intentionally by the code: https://github.com/rclone/rclone/blob/master/fs/log/systemd_unix.go#L19

What is your rclone version (output from rclone version)

rclone v1.72.1
- os/version: ubuntu 24.04 (64 bit)
- os/kernel: 6.14.0-1018-aws (x86_64)
- os/type: linux
- os/arch: amd64
- go/version: go1.25.5
- go/linking: static
- go/tags: none

Which OS you are using and how many bits (e.g. Windows 7, 64 bit)

  • ubuntu 24.04 (64 bit)
  • systemd 255 (255.4-1ubuntu8.12)

The command you were trying to run (e.g. rclone copy /tmp remote:tmp)

rclone --log-systemd mount ...

A log from the command with the -vv flag (e.g. output from rclone -vv copy /tmp remote:tmp)

Extract from journaltctl --grep rclone


Jan 08 12:59:26 cpu rclone[3861757]: DEBUG : rclone: Version "v1.72.1" starting with parameters ["rclone" "-v" "-v" "--log-systemd" "mount" "--daemon" "backup:1234" "a"]

Jan 08 12:59:26 cpu rclone[3861757]: DEBUG : rclone: systemd logging support activated

Jan 08 12:59:26 cpu rclone[3861757]: DEBUG : Using config file from "/home/jerome/.config/rclone/rclone.conf"

How to use GitHub

  • Please use the 👍 reaction to show that you are affected by the same issue.
  • Please don't comment if you have no relevant information to add. It's just extra noise for everyone subscribed to this issue.
  • Subscribe to receive notifications on status change and new comments.

Activity

  1. changed the title [-]systemd-log output adds extra newline[/-] [+]systemd log output adds extra newline[/+] on Jan 8, 2026
  2. added a commit that references this issue on Jan 9, 2026
    820c8a0
  3. roucc commented on Jan 9, 2026

    @roucc
    Member

    Thanks for spotting this! I sent a pull request and will merge once the CI goes green. It seems ncw added the newline by mistake when refactoring this part of the code in commit 3cae373.

  4. added a commit that references this issue on Jan 9, 2026
    e51a059
  5. added 2 commits that reference this issue on Jan 21, 2026
    8245ef0
    3326969
  6. added a commit that references this issue on Feb 14, 2026
    d9de6c5
  7. added a commit that references this issue on Jul 20, 2026
    b65c97d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions