[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Segmentation faults with aptitude and apt-get on some packages



> On 28 Nov 2016, at 22:07, rod <r.schnell@mythos.freeddns.org> wrote:
>> On 11/18/2016 4:32 PM, John Paul Adrian Glaubitz wrote:
>>> On 11/16/2016 06:13 PM, rod wrote:
>>> The current problem I'm having is this:
>>> 
>>> root@mw-monitor:/home/rod# aptitude
>>> Ouch!  Got SIGSEGV, dying..
>>> Segmentation fault
>> 
>> This has turned out to be an issue with libstdc++6 which comes from the gcc-6
>> package which was built with a broken version of binutils. The buildds are
>> currently building a fresh gcc-6 package which is being built with a fixed
>> version of binutils which should mitigate the problem.
>> 
>> For anyone experiencing the issue, here is a quick workaround to fix apt
>> for the time being until the buildds have finished building the new gcc-6
>> package (which should be in around 2-3 hours).
>> 
>> Fix:
>> 
>> $ wget http://snapshot.debian.org/archive/debian-ports/20161022T004918Z/pool-sparc64/main/g/gcc-6/gcc-6-base_6.2.0-9_sparc64.deb \
>>       http://snapshot.debian.org/archive/debian-ports/20161022T004918Z/pool-sparc64/main/g/gcc-6/libstdc%2B%2B6_6.2.0-9_sparc64.deb
>> $ dpkg -i gcc-6-base_6.2.0-9_sparc64.deb libstdc++6_6.2.0-9_sparc64.deb
>> 
>> Once gcc-6_6.2.1-3 has finished building on sparc64 here [1], it should be
>> safe to dist-upgrade the machine again.
>> 
>> Please let us know when you encounter any other issues.
>> 
>> Adrian
>> 
>>> [1] https://buildd.debian.org/status/package.php?p=gcc-6&suite=sid
>> 
> Using the above thread and after installing several packages (apache2,
> mariadb, phpmyadmin, webmin, & shellinabox and their associated
> requirement packages);  I got the following crash and had to reboot.
> 
> [ 2983.405916] systemd[1]: apt-daily.timer: Adding 10h 21min 29.083051s
> random time.
> [ 2987.766873] systemd[1]: apt-daily.timer: Adding 4h 3min 23.373286s
> random time.
> [ 3049.054254]               \|/ ____ \|/
> [ 3049.054254]               "@'/ .. \`@"
> [ 3049.054254]               /_| \__/ |_\
> [ 3049.054254]                  \__U_/
> [ 3049.247708] systemd(1): Kernel illegal instruction [#1]
> [ 3049.316397] CPU: 0 PID: 1 Comm: systemd Not tainted
> 4.8.0-1-sparc64-smp #1 Debian 4.8.5-1
> [ 3049.424029] task: fff000123e14f620 task.stack: fff000123e158000
> [ 3049.501869] TSTATE: 0000004411001603 TPC: 00000000005ca4a8 TNPC:
> 00000000005ca4ac Y: 00000000    Not tainted
> [ 3049.631240] TPC: <__kmalloc_track_caller+0x128/0x200>
> [ 3049.697661] g0: 0000000000000000 g1: 0000000000400000 g2:
> 0000000000000000 g3: 0000000000000001
> [ 3049.812168] g4: fff000123e14f620 g5: fff000123ebc6000 g6:
> fff000123e158000 g7: 0000000000636500
> [ 3049.926669] o0: 0000000000000000 o1: 00000000024000c0 o2:
> 0000000000000000 o3: 0000000000000000
> [ 3050.041113] o4: 0000000000000000 o5: 0000000000000000 sp:
> fff000123e15af01 ret_pc: 00000000005ca4a0
> [ 3050.160172] RPC: <__kmalloc_track_caller+0x120/0x200>
> [ 3050.226606] l0: fff000123e0032e0 l1: 0000000040000000 l2:
> fff000123e004898 l3: 000c000028fb0d68
> [ 3050.341088] l4: ffffffffffffffff l5: fff000123f80f328 l6:
> 000c000028fb0d88 l7: fff0000100e9a000
> [ 3050.455564] i0: fff000123e0032e0 i1: 00000000024000c0 i2:
> 000000000058c47c i3: 00000000024000c0
> [ 3050.570055] i4: 000000000000000b i5: 00000000024000c0 i6:
> fff000123e15afb1 i7: 000000000058c408
> [ 3050.635685]               \|/ ____ \|/
> [ 3050.635685]               "@'/ .. \`@"
> [ 3050.635685]               /_| \__/ |_\
> [ 3050.635685]                  \__U_/
> [ 3050.635690] systemd-journal(209): Kernel illegal instruction [#2]
> [ 3050.635698] CPU: 1 PID: 209 Comm: systemd-journal Not tainted
> 4.8.0-1-sparc64-smp #1 Debian 4.8.5-1
> [ 3050.635701] task: fff00012049dc080 task.stack: fff000123d1dc000
> [ 3050.635705] TSTATE: 0000004411001604 TPC: 00000000005ca4a8 TNPC:
> 00000000005ca4ac Y: 00000000    Not tainted
> [ 3050.635718] TPC: <__kmalloc_track_caller+0x128/0x200>
> [ 3050.635720] g0: fff000123d1dee71 g1: 0000000000400000 g2:
> 0000000000000000 g3: 00000000c0000000
> [ 3050.635723] g4: fff00012049dc080 g5: fff000123edc6000 g6:
> fff000123d1dc000 g7: fff000123edc6000
> [ 3050.635725] o0: 0000000000000000 o1: 00000000025106c0 o2:
> fff000123de2dc20 o3: 0000000000b15c00
> [ 3050.635727] o4: 0000000000000000 o5: 0000000000000000 sp:
> fff000123d1deed1 ret_pc: 00000000005ca4a0
> [ 3050.635731] RPC: <__kmalloc_track_caller+0x120/0x200>
> [ 3050.635734] l0: fff000123e003220 l1: 0000000040000000 l2:
> 00000000f0000000 l3: fff0001204c54e40
> [ 3050.635736] l4: 0000000000000000 l5: 0000000000000000 l6:
> 0000000000000000 l7: fff0000100327e90
> [ 3050.635738] i0: fff000123e003220 i1: 00000000025106c0 i2:
> 0000000000862a1c i3: 00000000025106c0
> [ 3050.635740] i4: 0000000000000180 i5: 00000000025106c0 i6:
> fff000123d1def81 i7: 0000000000862960
> [ 3050.635751] I7: <__kmalloc_reserve.isra.5+0x20/0x80>
> [ 3050.635752] Call Trace:
> [ 3050.635757]  [0000000000862960] __kmalloc_reserve.isra.5+0x20/0x80
> [ 3050.635760]  [0000000000862a1c] __alloc_skb+0x5c/0x180
> [ 3050.635764]  [0000000000862b84] alloc_skb_with_frags+0x44/0x1e0
> [ 3050.635768]  [000000000085d02c] sock_alloc_send_pskb+0x1ec/0x220
> [ 3050.635775]  [00000000009329ec] unix_dgram_sendmsg+0x12c/0x600
> [ 3050.635778]  [00000000008577bc] sock_sendmsg+0x3c/0x80
> [ 3050.635781]  [0000000000858d80] SyS_sendto+0xa0/0x120
> [ 3050.635785]  [0000000000859acc] SyS_socketcall+0x26c/0x320
> [ 3050.635793]  [00000000004061f4] linux_sparc_syscall+0x34/0x44
> [ 3050.635795] Disabling lock debugging due to kernel taint
> [ 3050.635799] Caller[0000000000862960]: __kmalloc_reserve.isra.5+0x20/0x80
> [ 3050.635803] Caller[0000000000862a1c]: __alloc_skb+0x5c/0x180
> [ 3050.635807] Caller[0000000000862b84]: alloc_skb_with_frags+0x44/0x1e0
> [ 3050.635810] Caller[000000000085d02c]: sock_alloc_send_pskb+0x1ec/0x220
> [ 3050.635813] Caller[00000000009329ec]: unix_dgram_sendmsg+0x12c/0x600
> [ 3050.635816] Caller[00000000008577bc]: sock_sendmsg+0x3c/0x80
> [ 3050.635819] Caller[0000000000858d80]: SyS_sendto+0xa0/0x120
> [ 3050.635822] Caller[0000000000859acc]: SyS_socketcall+0x26c/0x320
> [ 3050.635826] Caller[00000000004061f4]: linux_sparc_syscall+0x34/0x44
> [ 3050.635829] Caller[fff0000100692910]: 0xfff0000100692910
> [ 3050.635840] Instruction DUMP: b6100008  400f17d8  01000000 <3ffffff2>
> 01000000  106fffc8  01000000  c611a036  05002c46
> [ 3054.103670] I7: <kstrdup+0x28/0x60>
> [ 3054.149508] Call Trace:
> [ 3054.181533]  [000000000058c408] kstrdup+0x28/0x60
> [ 3054.243298]  [000000000058c47c] kstrdup_const+0x3c/0x60
> [ 3054.311942]  [00000000006630d0] __kernfs_new_node+0x10/0xc0
> [ 3054.385233]  [0000000000664324] kernfs_new_node+0x24/0x60
> [ 3054.456146]  [00000000006646fc] kernfs_create_dir_ns+0x1c/0x80
> [ 3054.532776]  [00000000004fdb44] cgroup_mkdir+0x1c4/0x2c0
> [ 3054.602542]  [000000000066427c] kernfs_iop_mkdir+0x5c/0xa0
> [ 3054.674603]  [00000000005f1ad8] vfs_mkdir+0x118/0x1a0
> [ 3054.740944]  [00000000005f735c] SyS_mkdirat+0xdc/0x160
> [ 3054.741177]               \|/ ____ \|/
> [ 3054.741177]               "@'/ .. \`@"
> [ 3054.741177]               /_| \__/ |_\
> [ 3054.741177]                  \__U_/
> [ 3054.741182] irqbalance(336): Kernel illegal instruction [#3]
> [ 3054.741189] CPU: 1 PID: 336 Comm: irqbalance Tainted: G      D
> 4.8.0-1-sparc64-smp #1 Debian 4.8.5-1
> [ 3054.741193] task: fff0001236c2f6c0 task.stack: fff0001204de0000
> [ 3054.741196] TSTATE: 0000004411001606 TPC: 00000000005caa6c TNPC:
> 00000000005caa70 Y: 00000000    Tainted: G      D
> [ 3054.741207] TPC: <__kmalloc+0x12c/0x200>
> [ 3054.741209] g0: 0000000000000000 g1: 0000000000400000 g2:
> 0000000000000000 g3: 00000000c0000000
> [ 3054.741211] g4: fff0001236c2f6c0 g5: fff000123edc6000 g6:
> fff0001204de0000 g7: 0000000000000001
> [ 3054.741213] o0: 0000000000000000 o1: 00000000024000c0 o2:
> 0000000000000400 o3: 0000000000000000
> [ 3054.741216] o4: 000000000020ce43 o5: fff00001008779f8 sp:
> fff0001204de31b1 ret_pc: 00000000005caa64
> [ 3054.741219] RPC: <__kmalloc+0x124/0x200>
> [ 3054.741222] l0: fff000123e0030a0 l1: 0000000000000000 l2:
> 0000000000000001 l3: fff000010087b620
> [ 3054.741224] l4: fff000010087b620 l5: 0000000000000080 l6:
> fff000010087b5c8 l7: fff000010087a000
> [ 3054.741226] i0: fff000123e0030a0 i1: 00000000024000c0 i2:
> 000000000060c144 i3: 00000000024000c0
> [ 3054.741228] i4: 0000000000002000 i5: 00000000024000c0 i6:
> fff0001204de3261 i7: 000000000060c144
> [ 3054.741234] I7: <seq_buf_alloc+0x44/0x60>
> [ 3054.741235] Call Trace:
> [ 3054.741238]  [000000000060c144] seq_buf_alloc+0x44/0x60
> [ 3054.741242]  [000000000060c6c4] seq_read+0x2a4/0x440
> [ 3054.741250]  [0000000000652c28] proc_reg_read+0x48/0xa0
> [ 3054.741254]  [00000000005e4a84] __vfs_read+0x24/0x60
> [ 3054.741257]  [00000000005e5898] vfs_read+0x58/0x120
> [ 3054.741261]  [00000000005e6c18] SyS_read+0x38/0xa0
> [ 3054.741268]  [00000000004061f4] linux_sparc_syscall+0x34/0x44
> [ 3054.741272] Caller[000000000060c144]: seq_buf_alloc+0x44/0x60
> [ 3054.741275] Caller[000000000060c6c4]: seq_read+0x2a4/0x440
> [ 3054.741278] Caller[0000000000652c28]: proc_reg_read+0x48/0xa0
> [ 3054.741281] Caller[00000000005e4a84]: __vfs_read+0x24/0x60
> [ 3054.741284] Caller[00000000005e5898]: vfs_read+0x58/0x120
> [ 3054.741287] Caller[00000000005e6c18]: SyS_read+0x38/0xa0
> [ 3054.741291] Caller[00000000004061f4]: linux_sparc_syscall+0x34/0x44
> [ 3054.741293] Caller[fff00001006923b4]: 0xfff00001006923b4
> [ 3054.741304] Instruction DUMP: b6100008  400f1667  01000000 <3ffffff2>
> 01000000  106fffc8  01000000  c611a036  05002c46
> [ 3057.735755]  [00000000005f73f8] SyS_mkdir+0x18/0x40
> [ 3057.799914]  [00000000004061f4] linux_sparc_syscall+0x34/0x44
> [ 3057.875490] Caller[000000000058c408]: kstrdup+0x28/0x60
> [ 3057.944118] Caller[000000000058c47c]: kstrdup_const+0x3c/0x60
> [ 3058.019602] Caller[00000000006630d0]: __kernfs_new_node+0x10/0xc0
> [ 3058.099672] Caller[0000000000664324]: kernfs_new_node+0x24/0x60
> [ 3058.177446] Caller[00000000006646fc]: kernfs_create_dir_ns+0x1c/0x80
> [ 3058.260941] Caller[00000000004fdb44]: cgroup_mkdir+0x1c4/0x2c0
> [ 3058.337570] Caller[000000000066427c]: kernfs_iop_mkdir+0x5c/0xa0
> [ 3058.416493] Caller[00000000005f1ad8]: vfs_mkdir+0x118/0x1a0
> [ 3058.489697] Caller[00000000005f735c]: SyS_mkdirat+0xdc/0x160
> [ 3058.564048] Caller[00000000005f73f8]: SyS_mkdir+0x18/0x40
> [ 3058.635053] Caller[00000000004061f4]: linux_sparc_syscall+0x34/0x44
> [ 3058.717409] Caller[fff00001001ef870]: 0xfff00001001ef870
> [ 3058.787172] Instruction DUMP: b6100008  400f17d8  01000000 <3ffffff2>
> 01000000  106fffc8  01000000  c611a036  05002c46
> [ 3058.929102]               \|/ ____ \|/
> [ 3058.929102]               "@'/ .. \`@"
> [ 3058.929102]               /_| \__/ |_\
> [ 3058.929102]                  \__U_/
> [ 3059.122466] kworker/0:1(37): Kernel illegal instruction [#4]
> [ 3059.197017] CPU: 0 PID: 37 Comm: kworker/0:1 Tainted: G      D
> 4.8.0-1-sparc64-smp #1 Debian 4.8.5-1
> [ 3059.326344] Workqueue: events_freezable_power_ disk_events_workfn
> [ 3059.406459] task: fff0001236c2dbc0 task.stack: fff0001236c54000
> [ 3059.484251] TSTATE: 0000004480001607 TPC: 00000000005caa6c TNPC:
> 00000000005caa70 Y: 00000000    Tainted: G      D
> [ 3059.629520] TPC: <__kmalloc+0x12c/0x200>
> [ 3059.681075] g0: 0000000010096108 g1: 0000000000400000 g2:
> 0000000000000000 g3: 0000000000b0a000
> [ 3059.795466] g4: fff0001236c2dbc0 g5: fff000123ebc6000 g6:
> fff0001236c54000 g7: 0000000000000001
> [ 3059.909841] o0: 0000000000000000 o1: 0000000002400000 o2:
> 0000000000000001 o3: 0000000000000000
> [ 3060.024222] o4: 0000000000000004 o5: fff0001236e29800 sp:
> fff0001236c56c11 ret_pc: 00000000005caa64
> [ 3060.143205] RPC: <__kmalloc+0x124/0x200>
> [ 3060.194739] l0: fff000123e002860 l1: fff0001236e299b0 l2:
> 0000000000a96c98 l3: 0000000000a97568
> [ 3060.309131] l4: 0000000000000000 l5: 0000000000000001 l6:
> 0000000000000000 l7: fff0000100327e90
> [ 3060.423650] i0: fff000123e002860 i1: 0000000002400000 i2:
> 00000000006dd9b8 i3: 0000000002400000
> [ 3060.538100] i4: 0000000000000098 i5: 0000000002400000 i6:
> fff0001236c56cc1 i7: 00000000006dd9b8
> [ 3060.652599] I7: <bio_alloc_bioset+0x1b8/0x220>
> [ 3060.710997] Call Trace:
> [ 3060.743036]  [00000000006dd9b8] bio_alloc_bioset+0x1b8/0x220
> [ 3060.817471]  [00000000006de95c] bio_copy_kern+0x3c/0x1c0
> [ 3060.887259]  [00000000006ecd68] blk_rq_map_kern+0xa8/0x160
> [ 3060.959464]  [000000001007c77c] scsi_execute+0x5c/0x140 [scsi_mod]
> [ 3061.040726]  [000000001007c920] scsi_execute_req_flags+0x60/0xe0
> [scsi_mod]
> [ 3061.132332]  [00000000103527d4] sr_check_events+0x74/0x320 [sr_mod]
> [ 3061.214810]  [000000001033c420] cdrom_check_events+0x20/0x60 [cdrom]
> [ 3061.298382]  [0000000010352ccc] sr_block_check_events+0x2c/0x40 [sr_mod]
> [ 3061.386544]  [00000000006f806c] disk_check_events+0x2c/0x120
> [ 3061.460896]  [00000000006f8170] disk_events_workfn+0x10/0x20
> [ 3061.535247]  [0000000000481c78] process_one_work+0x158/0x460
> [ 3061.609691]  [00000000004820a0] worker_thread+0x120/0x520
> [ 3061.611384]               \|/ ____ \|/
> [ 3061.611384]               "@'/ .. \`@"
> [ 3061.611384]               /_| \__/ |_\
> [ 3061.611384]                  \__U_/
> [ 3061.611390] dbus-daemon(315): Kernel illegal instruction [#5]
> [ 3061.611398] CPU: 1 PID: 315 Comm: dbus-daemon Tainted: G      D
>  4.8.0-1-sparc64-smp #1 Debian 4.8.5-1
> [ 3061.611402] task: fff00012049564c0 task.stack: fff00012049d0000
> [ 3061.611406] TSTATE: 0000004411001606 TPC: 00000000005ca4a8 TNPC:
> 00000000005ca4ac Y: 00000000    Tainted: G      D
> [ 3061.611418] TPC: <__kmalloc_track_caller+0x128/0x200>
> [ 3061.611421] g0: fff000123d154648 g1: 0000000000400000 g2:
> 0000000000000000 g3: 00000000c0000000
> [ 3061.611423] g4: fff00012049564c0 g5: fff000123edc6000 g6:
> fff00012049d0000 g7: fff000123edc6000

That's a bug I fixed, but it didn’t make it into the 4.8 branch until
4.8.10[1]. Unfortunately that’s not yet been packaged for Debian. There
is 4.9~rc5-1~exp1 in experimental, but I haven’t tried that build, and I
don’t know if the serious regression of not being able to load kernel
modules has been fixed. My suggestion would be to try the experimental
package, but that may fail with a whole load of missing memcpy etc
symbols, in which case I recommend compiling an upstream version from
the 4.8 branch (currently 4.8.11[2] is the latest stable release).

Regards,
James

[1] https://git.kernel.org/cgit/linux/kernel/git/stable/linux-stable.git/commit/?h=linux-4.8.y&id=51915c6d90704046600414e117d80e6a76ba13e6
[2] https://git.kernel.org/cgit/linux/kernel/git/stable/linux-stable.git/tag/?h=v4.8.11


Reply to: