RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1301579 - Request to add journalctl --disk-usage output in sosreport
Summary: Request to add journalctl --disk-usage output in sosreport
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: sos
Version: 7.2
Hardware: x86_64
OS: Linux
unspecified
low
Target Milestone: rc
: ---
Assignee: Pavel Moravec
QA Contact: BaseOS QE - Apps
URL: https://github.com/sosreport/sos/issu...
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-01-25 12:35 UTC by masanari iida
Modified: 2016-11-11 08:20 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-11-11 08:20:43 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description masanari iida 2016-01-25 12:35:06 UTC
Description of problem:
Request to add "journalctl --disk-usage" output in sosreport

Version-Release number of selected component (if applicable):
sos-3.2-35.el7.noarch

Currently, the sosreport doesn't collect "journalctl --disk-usage".
It would be good to collect the data in sosreport.

Comment 2 Pavel Moravec 2016-01-25 13:09:29 UTC
Could you please elaborate why this information would be valuable to collect?

Can't be the same information extracted from current data, e.g. from size of

sos_commands/logs/journalctl_--all_--this-boot_--no-pager_-o_verbose

(though not sure how --this-boot can affect it - with default journald settings, these values match before and also after reboot)?

Comment 3 Bryn M. Reeves 2016-01-25 13:18:48 UTC
> Can't be the same information extracted from current data, e.g. from size of
> 
> sos_commands/logs/journalctl_--all_--this-boot_--no-pager_-o_verbose

No: that is a text rendering of the journal contents. The journal itself is stored in a binary format with additional metadata. Although the size of journal logs approximates the size of the journal they do not measure the same thing.

  http://www.freedesktop.org/wiki/Software/systemd/journal-files/

This is also useful since it presents a global summary of disk usage rather than piecemeal per-file, e.g. (Fedora 23):

# journalctl --disk-usage
Archived and active journals take up 640.1M on disk.

With all that said on RHEL7 it is slightly less interesting/accurate:

# journalctl --disk-usage
Journals take up 96.0M on disk.

Although it is true that there are 96.0M of journal files present on this system:

# du -ch /run/log/journal/
96M	/run/log/journal/8f1a41c7c31a4575bd21b465748f123c
96M	/run/log/journal/
96M	total

These are all on the non-persistent (in-memory) /run file system - RHEL7 does not use persistent journald logs at all by default so this will only ever measure the size of the logs from the current boot.

That said I don't see any reason to not collect this & it is then available for other distributions (like Fedora) that do already offer persistent journald logs by default.

Comment 4 Pavel Moravec 2016-01-26 09:55:40 UTC
Makes sense. Esp. when cmd execution time and also output size are trivially small.

PR raised in upstream.

Comment 5 Pavel Moravec 2016-05-07 13:47:45 UTC
POSTed to upsetram as:

https://github.com/sosreport/sos/commit/28c87cdb311bafa194a1d2d8df2421b2a80323a7

Comment 6 Pavel Moravec 2016-11-11 08:20:43 UTC
This has been fixed in upstream sos 3.3 we rebased to by [1] in RHEL7.3. Errata [2] should resolve this bug.

Please test [2] and in case it does not address the reported problem properly, reopen this BZ.

[1] https://bugzilla.redhat.com/show_bug.cgi?id=1293044
[2] https://rhn.redhat.com/errata/RHBA-2016-2380.html


Note You need to log in before you can comment on or make changes to this bug.