thom311 / libnl

Netlink Library Suite
GNU Lesser General Public License v2.1
419 stars 311 forks source link

Test failure on 3.9.0: `tests/nl-test-util.c:128:S:Core:test_create_iface:0: assert(r == 0) failed (errno=1, Operation not permitted)` #393

Closed Zopolis4 closed 1 month ago

Zopolis4 commented 1 month ago

Tested on 3.9.0 and main, the log here is from main:

chronos@ff17437e4ca9 ~/libnl $ 
===================================
   libnl 3.9.0: ./test-suite.log
===================================

# TOTAL: 2
# PASS:  1
# SKIP:  0
# XFAIL: 0
# FAIL:  1
# XPASS: 0
# ERROR: 0

.. contents:: :depth: 2

FAIL: tests/check-all
=====================

Running suite(s): main
 Abstract addresses
 Netlink attributes
 Clone ematch tree
runs with NLTST_SEED_RAND=0
 netns
38%: Checks: 31, Failures: 19, Errors: 0
tests/nl-test-util.c:128:S:Core:cache_and_clone:0: assert(r == 0) failed (errno=1, Operation not permitted)
tests/nl-test-util.c:128:S:Core:test_create_iface:0: assert(r == 0) failed (errno=1, Operation not permitted)
tests/nl-test-util.c:128:S:Core:test_create_iface:1: assert(r == 0) failed (errno=1, Operation not permitted)
tests/nl-test-util.c:128:S:Core:test_create_iface:2: assert(r == 0) failed (errno=1, Operation not permitted)
tests/nl-test-util.c:128:S:Core:test_create_iface:3: assert(r == 0) failed (errno=1, Operation not permitted)
tests/nl-test-util.c:128:S:Core:test_create_iface:4: assert(r == 0) failed (errno=1, Operation not permitted)
tests/nl-test-util.c:128:S:Core:test_create_iface:5: assert(r == 0) failed (errno=1, Operation not permitted)
tests/nl-test-util.c:128:S:Core:test_create_iface:6: assert(r == 0) failed (errno=1, Operation not permitted)
tests/nl-test-util.c:128:S:Core:test_create_iface:7: assert(r == 0) failed (errno=1, Operation not permitted)
tests/nl-test-util.c:128:S:Core:test_create_iface:8: assert(r == 0) failed (errno=1, Operation not permitted)
tests/nl-test-util.c:128:S:Core:test_create_iface:9: assert(r == 0) failed (errno=1, Operation not permitted)
tests/nl-test-util.c:128:S:Core:test_create_iface:10: assert(r == 0) failed (errno=1, Operation not permitted)
tests/nl-test-util.c:128:S:Core:test_create_iface:11: assert(r == 0) failed (errno=1, Operation not permitted)
tests/nl-test-util.c:128:S:Core:test_create_iface:12: assert(r == 0) failed (errno=1, Operation not permitted)
tests/nl-test-util.c:128:S:Core:test_create_iface:13: assert(r == 0) failed (errno=1, Operation not permitted)
tests/nl-test-util.c:128:S:Core:test_create_iface:14: assert(r == 0) failed (errno=1, Operation not permitted)
tests/nl-test-util.c:128:S:Core:test_create_iface:15: assert(r == 0) failed (errno=1, Operation not permitted)
tests/nl-test-util.c:128:S:Core:test_create_iface:16: assert(r == 0) failed (errno=1, Operation not permitted)
tests/nl-test-util.c:128:S:Core:route_1:0: assert(r == 0) failed (errno=1, Operation not permitted)
FAIL tests/check-all (exit status: 1)

Configured with CFLAGS="-O2 -pipe -ffat-lto-objects -fPIC -fuse-ld=mold -flto=auto" CXXFLAGS="-O2 -pipe -ffat-lto-objects -fPIC -fuse-ld=mold -flto=auto" FCFLAGS="-O2 -pipe -ffat-lto-objects -fPIC -fuse-ld=mold -flto=auto" FFLAGS="-O2 -pipe -ffat-lto-objects -fPIC -fuse-ld=mold -flto=auto" LD_LIBRARY_PATH="/usr/local/lib64" LDFLAGS="-flto=auto " ./configure --prefix=/usr/local --libdir=/usr/local/lib64 --mandir=/usr/local/share/man --disable-dependency-tracking --build=x86_64-cros-linux-gnu --host=x86_64-cros-linux-gnu --target=x86_64-cros-linux-gnu --program-prefix='' --program-suffix='' --disable-debug

thom311 commented 1 month ago

unshare(CLONE_NEWUSER) fails with EPERM.

This is basically a duplicate of https://github.com/thom311/libnl/issues/361 , although, on 361 unshare() fails with EINVAL.

The verdict is still the same:

https://github.com/thom311/libnl/issues/361#issuecomment-1835763010

Closing with ^^ reasons.

(Patch welcome).