Subject: Mbuffer segfaults

From: Vittorio Mori <[email-masked]>
Date: Sat, 9 May 2020 00:10:41 +0200

I'm trying to use mbuffer to speed up ZFS send on my servers.

The package present in edge/testing segfaults.

I tried to compile it from source, same result: segfault.

There's a way to make it work ? Any pointers ?

---

From: Konstantin Kulikov <[email-masked]>
Date: Sat, 9 May 2020 14:36:00 +0300

> There's a way to make it work ? Any pointers ?

Can't help you with mbuffer, but netcat-openbsd has flags to adjust tcp send/receive buffers.
See https://man.openbsd.org/nc

---

From: Natanael Copa <[email-masked]>
Date: Sat, 9 May 2020 13:03:27 +0200

On Sat, 9 May 2020 00:10:41 +0200

> There's a way to make it work ? Any pointers ?

Seems like there is a new version (20200505). Have you tried that?

Otherwise I'd recommend to build it with debugging symbols, run it in
gdb (or generate core dump) and use gdb to generate a backtrace. This
should be reported upstream to mbuffer developer(s).

Common cases for segfaults are threading applications assumes that
thread stack size is huge, so thats where I'd start.

Alternatively, you could file an issue with all the details
(architecture, exact version, and how to reproduce) on our bugtracker
and someone with the know how and time can help you.

https://gitlab.alpinelinux.org/alpine/aports/-/issues

-nc

---

From: Vittorio Mori <[email-masked]>
Date: Sun, 10 May 2020 10:10:37 +0200

Thanks a lot.

The fix was the same as ZPAQ, I added this linker flag line (as per your
previous instructions w ZPAQ) to the makefile and it worked:

LDFLAGS=-Wl,-z,stack-size=1048576