Skip to content

cockpit.service fails in LXC: Failed to set up mount namespacing #17364

Answered by martinpitt
LuisCane asked this question in Q&A
Discussion options

You must be logged in to vote

cockpit.service: Failed to set up mount namespacing: /run/systemd/unit-root/proc: Permission denied

This smells like your LXC container does not have enough privileges to set up systemd's isolation options? cockpit.service has these:

NoNewPrivileges=true
ProtectSystem=strict
ProtectHome=true
PrivateTmp=true
PrivateDevices=true
ProtectKernelTunables=true
RestrictAddressFamilies=AF_UNIX AF_INET AF_INET6
MemoryDenyWriteExecute=true

These make cockpit.service safer (due to having much reduced capabilities) on ordinary systems, but being able to set that up requires additional privileges on the host. If you can't/don't want to grant these privileges to the LXC container, you can try and dro…

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
2 replies
@LuisCane
Comment options

@0xalen
Comment options

Answer selected by martinpitt
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
4 participants
Converted from issue

This discussion was converted from issue #17357 on May 20, 2022 15:38.