resolv/tst-resolv-res_init fails with unshare (CLONE_NEWUTS) failed: Operation not permitted

John Lumby johnlumby@hotmail.com
Tue Mar 1 19:16:20 GMT 2022


Apologies if this has been answered elsewhere.

under linux-5.16.9 I am building and testing glibc-2.35 and get one FAIL in the test suite :   glibc-build/resolv/tst-resolv-res_init.out contains :

warning: could not become root outside namespace (Operation not permitted)
warning: unshare (CLONE_NEWUTS) failed: Operation not permitted
warning: could not enter network namespace

I think the cause if that is this code in support/support_become_root.c

       unshare (CLONE_NEWUSER | CLONE_NEWNS)

is getting EPERM.

After reading the man page for unshare() I am none the wiser about whether  :
    .   the userid running the test is missing some capability that is needed in order to run the test  -  if so ,   what?
    .   there is some environmental problem   -  if so ,   how can I find out what?
    .  or is this test supposed to be run by root? (I think not but unclear)

I am sure the answer is buried somewhere in some doc but if anyone can help me get there I would be grateful.

Cheers,   John Lumby


More information about the Libc-help mailing list