[PKG-OpenRC-Debian] Bug#765070: openrc: [kfreebsd] segfault in loopsolver

Steven Chamberlain steven at pyro.eu.org
Mon Oct 13 10:58:07 UTC 2014


Package: openrc
Version: 0.12.4+20131230-9
Severity: grave

Hi,

Installing openrc segfaults in postinst and subsequently at boot.
(Though it gave me a login shell, so I was at least able to bring
up the system manually and recover it).

I rebuilt without optimisations to get the attached backtrace.

This was in a fresh kfreebsd-amd64 sid/jessie test-install.

Thanks.

-- System Information:
Debian Release: jessie/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (500, 'stable')
Architecture: kfreebsd-amd64 (x86_64)

Kernel: kFreeBSD 9.0-2-amd64-xenhvm-ipsec
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
-------------- next part --------------
# gdb openrc/sbin/openrc
GNU gdb (Debian 7.7.1+dfsg-3) 7.7.1
Copyright (C) 2014 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 "x86_64-kfreebsd-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from openrc/sbin/openrc...done.
(gdb) run
Starting program: /root/openrc-0.12.4+20131230/debian/openrc/sbin/openrc 
 * Caching service dependencies ...
 * Found a solvable dependency loop: checkfs.sh p> checkfs n> mountall.sh p> mountall u> hwclock.sh a> checkroot n> checkfs.sh.

Program received signal SIGSEGV, Segmentation fault.
0x00007fffffffdccd in ?? ()
(gdb) bt full
#0  0x00007fffffffdccd in ?? ()
No symbol table info available.
#1  0x0000000800a503ee in rc_deptree_solve_loop (unap_matrix=0x7fffffffde70, 
    service_id=4, svc_id2depinfo_bt=0x6384f0, end_dep_num=26, 
    flags=(RCDTFLAGS_LOOPSOLVER | RCDTFLAGS_LOOPSOLVER_WARNINGS))
    at librc-depend.c:1270
        btree = 0x637290
        idid_to_break = 0x65b7e0
        idid_count = 1
        idid_to_break_count = 8
        chain_strs = 0x65b8d0
        chains = 0x65b270
        deptypes = 0x65b880
        minimal_cost = UNAPM_USE
        chains_size = 66
        chain_count = 1
        printerr = 1 '\001'
        printwarn = 1 '\001'
        idid_counters = 0x6372c0
        idid_count2 = 0
        depinfo_from = 0x80064a358
        depinfo_to = 0x0
#2  0x0000000800a51fd6 in __RC_rc_deptree_update (
    flags=(RCDTFLAGS_LOOPSOLVER | RCDTFLAGS_LOOPSOLVER_WARNINGS))
    at librc-depend.c:1806
        dep_num = 26
        dep_count = 26
        unapm_type = UNAPM_MAX
        loopsolver_counter = 0
        loopfound = 0
        unap_matrix = {0x637440, 0x637660, 0x637880, 0x637aa0, 0x637cc0, 
          0x637ee0}
        service_id = 4
        svc_id2depinfo_bt = 0x6384f0
        fp = 0x6246d0
        deptree = 0x6247e0
        providers = 0x6246d0
        depinfo = 0x0
        depinfo_np = 0x7fffffffe150
        di = 0x630be0
        deptype = 0x0
        dt_np = 0x0
        dt = 0x630c30
        provide = 0x0
        config = 0x624800
        types = 0x6367d0
        sorted = 0x6368b0
        visited = 0x6374d0
        s = 0x0
        s2 = 0x0
        s2_np = 0x0
        s3 = 0x0
        s4 = 0x0
        line = 0x625f00 "0_b"
        len = 8192
        depend = 0x0
        depends = 0x0
        service = 0x625f00 "0_b"
        type = 0x625f08 "`rb"
        nosys = 0x1 <error: Cannot access memory at address 0x1>
        onosys = 0x80062f467 <_dl_fixup+247> "H\211\305d\213\004%\030"
        i = 5
        k = 1
        retval = true
        sys = 0x0
        uts = {
          sysname = "GNU/kFreeBSD\000\000\000\000`\335&\001\b\000\000\000\304-\023\034\000\000\000", 
          nodename = "\000\000\000\000\000\000\000\000\n\000\000\000\000\000\000\000\300\304d\000\b\000\000\000\276\255b\000\b\000\000", 
          release = "10.1-0-amd64\000\000\000\000\320s\244\000\b\000\000\000\350\177\244\000\b\000\000", 
          version = "#0 Sat, 20 Sep 2014 22:02:28 +0100\000\000\000\000\000\000X\305d\000\b\000\000\000\000\240d\000\b\000\000\000\f\034@\000\000\000\000\000\250\200\244\000\b\000\000\000\310\005@\000\000\000\000\000\000\000\000\000\001\000\000\000\201\000\000\000\001", '\000' <repeats 11 times>, "X\305d\000\b\000\000\000\340\340\377\377\377\177\000\000\340\064\204\000\b\000\000\000\b\341\377\377\377\177\000\000\210\061\204\000\b\000\000\000\001\000\000\000\000\000\000\000m\257b\000\b", '\000' <repeats 11 times>, "X\305d\000\b\000\000\000\001", '\000' <repeats 15 times>, "\001\000\000\000\377\177\000\000"..., 
          machine = "x86_64\000\000@\340\377\377\377\177\000\000\304-\023\034\000\000\000\000\f\034@\000\000\000\000"}
        useneedafter_count = 65
#3  0x000000000040bc9f in _rc_deptree_load (force=0, regen=0x7fffffffe67c)
    at rc-depend.c:80
        fd = -1
        retval = 4283343
        serrno = 2
        merrno = 2
        t = 0
        file = "\300\304d\000\b\000\000\000\276\255b\000\b\000\000\000\006\000\000\000\000\000\000\000L\244b\000\b\000\000\000`\335&\001\b\000\000\000\207\360\226|\000\000\000\000\006\000\000\000\000\000\000\000L\244b\000\b\000\000\000\300\304d\000\b\000\000\000\207\360\226|\000\000\000\000\006\000\000\000\000\000\000\000\n\000\000\000\000\000\000\000\300\304d\000\b\000\000\000L\244b\000\b\000\000\000\300\343\377\377\377\177\000\000\067\303\362z\000\000\000\000\006\000\000\000\000\000\000\000\n\000\000\000\000\000\000\000\300\304d\000\b\000\000\000\276\255b\000\b\000\000\000\006\000\000\000\000\000\000\000L\244b\000\b\000\000\000`\335&\001\b\000\000\000\373uu\204\000\000\000\000\006\000\000\000\000\000\000\000"...
        st = {st_dev = 0, st_ino = 0, st_mode = 21760, __pad_mode = 295, 
          st_nlink = 8, __pad_nlink = 0, st_uid = 0, st_gid = 0, 
          st_rdev = 4294960720, st_atim = {tv_sec = 4212064, 
            tv_nsec = 34366249669}, st_mtim = {tv_sec = 0, 
            tv_nsec = 34379943239}, st_ctim = {tv_sec = 0, 
            tv_nsec = 140737488348720}, st_size = 4309956, st_blocks = 0, 
          st_blksize = 4294960720, st_flags = 32767, st_gen = 4212064, 
          __unused1 = {140737488350152, 4252419}}
        ut = {actime = 140733193388033, modtime = 0}
        fp = 0x415a00 <get_krunlevel+33>
#4  0x0000000000416fa8 in main (argc=1, argv=0x7fffffffebd0) at rc.c:966
        bootlevel = 0x6243dd "boot"
        newlevel = 0x0
        hotplugged_services = 0x0
        stop_services = 0x0
        start_services = 0x0
        types_n = 0x0
        types_nua = 0x0
        deptree = 0x0
        deporder = 0x0
        tmplist = 0x1
        service = 0x7fffffffebc8
        going_down = false
        depoptions = 3
        krunlevel = "\350\271d\000\b\000\000\000(\264d\000\b", '\000' <repeats 19 times>, "\t\320\bQ\212@\025\000L\244b\000\b\000\000\000\024\064\317V\351q\332\063\207\360\226|\000\000\000\000\006\000\000\000\000\000\000\000\n\000\000\000\000\000\000\000\300\304d\000\b\000\000\000\276\255b\000\b\000\000\000\206\035@\000\000\000\000\000\060\347\377\377\377\177\000\000`\335&\001\b\000\000\000?'\001\b\000\000\000@\350\377\377\377\177\000\000\302[\362\001\000\000\000\000\060\350\377\377\377\177\000\000\260\351\377\377\377\177\000\000\000\000\000\000\000\000\000\000\210\313d\000\b\000\000\000(\264d\000\b\000\000\000T'b\000\b\000\000\000\000\257'\001\b\000\000\000\020"...
        pidstr = "1680\000\000\000\000", <incomplete sequence \336>
        opt = -1
        parallel = false
        regen = 1
        nostop = false
(gdb) quit
A debugging session is active.

    Inferior 1 [process 1680] will be killed.

Quit anyway? (y or n) y


More information about the OpenRC-devel mailing list