[systemd-bugs] [Bug 82894] New: journalctl: Assertion caused by journalctl --list-boots

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Thu Aug 21 00:33:45 PDT 2014


https://bugs.freedesktop.org/show_bug.cgi?id=82894

          Priority: medium
            Bug ID: 82894
          Assignee: systemd-bugs at lists.freedesktop.org
           Summary: journalctl: Assertion caused by journalctl
                    --list-boots
        QA Contact: systemd-bugs at lists.freedesktop.org
          Severity: normal
    Classification: Unclassified
                OS: Linux (All)
          Reporter: toff.tillman at gmail.com
          Hardware: PowerPC
            Status: NEW
           Version: unspecified
         Component: general
           Product: systemd

As reported in Debian bug #758392

> Package: systemd
> Version: 208-6
> Severity: normal
>
> Dear Maintainer,
>
>    * What led up to the situation? journalctl --list-boots
>    * What was the outcome of this action?
>
> Assertion 'size > 0' failed at ../src/journal/mmap-cache.c:543, function mmap_cache_get(). Aborting.
>
>    * What outcome did you expect instead? listing of boots as documented
>

- Is this problem reproducible (after a reboot
Yes 
- Did you run the command as root or regular user?
As root. I haven't been able to boot into the graphic environment as yet, I've
been booting single-user. If that's important, I'll disable X so I can get on
another console. 

- Do you have a /var/log/journal directory? If so, what does it contain
(ls -Rla /var/log/journal/)?
I did create one after reading another bug about multiple session journalctl.
In that bug, you thought all that should be necessary was to create the dir.
That did work, and here is ls -Rla. The journal file is being appended on each
boot, so the backup files are the same size as the main file.
/var/log/journal:
total 12
drwxr-sr-x  3 root systemd-journal 4096 Aug 17 16:39 .
drwxr-xr-x 11 root root            4096 Aug 21 17:00 ..
drwxr-sr-x  2 root systemd-journal 4096 Aug 21 16:59
42bc3423441b4065acbfbf085d5741df

/var/log/journal/42bc3423441b4065acbfbf085d5741df:
total 24596
drwxr-sr-x 2 root systemd-journal    4096 Aug 21 16:59 .
drwxr-sr-x 3 root systemd-journal    4096 Aug 17 16:39 ..
-rwxr-xr-x 1 root systemd-journal 8388608 Aug 18 19:36
system at 000500e26f9ab124-86721527ee2de970.journal~
-rwxr-xr-x 1 root systemd-journal 8388608 Aug 21 16:59
system at 0005011c967a9cb6-f1afda7b33407034.journal~
-rw-r----- 1 root systemd-journal 8388608 Aug 21 17:04 system.journal

- If you move the journal directory away and create a new one, is the
problem gone?
After moving it out of the way, it returns No journal files found. Same after
re-creating /var/log/journal. After moving the directory back, the assertion
returns.
- Can you install systemd-dbg and create a backtrace using gdb, please.

Output:
 Script started on Thu 21 Aug 2014 17:29:51 NZST
root at debian:~# gdb --args journalctl --list-boots
GNU gdb (GDB) 7.6.2 (Debian 7.6.2-1.1+b1)
Copyright (C) 2013 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "powerpc-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /bin/journalctl...Reading symbols from
/usr/lib/debug/.build-id/5a/b4971c9db1d4f7674ee6c7b37a6e160f89796c.debug...done.
done.
(gdb) run
Starting program: /bin/journalctl --list-boots
Can't read symbols from system-supplied DSO at 0x100000: File truncated
warning: Could not load shared library symbols for linux-vdso32.so.1.
Do you need "set solib-search-path" or "set sysroot"?
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/powerpc-linux-gnu/libthread_db.so.1".

Assertion 'size > 0' failed at ../src/journal/mmap-cache.c:543, function
mmap_cache_get(). Aborting.

Program received signal SIGABRT, Aborted.
0x0fd5a168 in __GI_raise (sig=sig at entry=6) at
../nptl/sysdeps/unix/sysv/linux/raise.c:56
56    ../nptl/sysdeps/unix/sysv/linux/raise.c: No such file or directory.
(gdb) bt
#0  0x0fd5a168 in __GI_raise (sig=sig at entry=6) at
../nptl/sysdeps/unix/sysv/linux/raise.c:56
#1  0x0fd5bd50 in __GI_abort () at abort.c:89
#2  0x1000f1bc in log_assert (text=text at entry=0x1003965c "size > 0",
file=file at entry=0x100394a0 "../src/journal/mmap-cache.c", 
    line=line at entry=543, func=func at entry=0x10039450 <__PRETTY_FUNCTION__.8083>
"mmap_cache_get", 
    format=format at entry=0x10035b8c "Assertion '%s' failed at %s:%u, function
%s(). Aborting.") at ../src/shared/log.c:702
#3  0x1000f798 in log_assert_failed (text=text at entry=0x1003965c "size > 0", 
    file=file at entry=0x100394a0 "../src/journal/mmap-cache.c",
line=line at entry=543, 
    func=func at entry=0x10039450 <__PRETTY_FUNCTION__.8083> "mmap_cache_get") at
../src/shared/log.c:707
#4  0x10026d54 in mmap_cache_get (m=0x1004f918, fd=9, prot=<optimized out>,
context=context at entry=1, 
    keep_always=keep_always at entry=true, offset=<optimized out>, size=0,
st=0x10060a90, ret=ret at entry=0x0)
    at ../src/journal/mmap-cache.c:543
#5  0x10018c74 in journal_file_object_keep (offset=<optimized out>,
o=<optimized out>, f=<optimized out>)
    at ../src/journal/journal-file.h:215
#6  sd_journal_enumerate_unique (j=j at entry=0x1004e850,
data=data at entry=0xbffff96c, l=l at entry=0xbffff970)
    at ../src/journal/sd-journal.c:2593
#7  0x100039c8 in list_boots (j=0x1004e850) at ../src/journal/journalctl.c:781
#8  main (argc=<optimized out>, argv=<optimized out>) at
../src/journal/journalctl.c:1520
(gdb) quit
A debugging session is active.

    Inferior 1 [process 1339] will be killed.

Quit anyway? (y or n) y
root at debian:~# less typescript 
root at debian:~# gdb --args journalctl --list-boots ^C
root at debian:~# exit
Script done on Thu 21 Aug 2014 17:31:15 NZST

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/systemd-bugs/attachments/20140821/a30376df/attachment.html>


More information about the systemd-bugs mailing list