Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot run useradd command in a container created by nerdctl+kata. #2921

Open
zibinpan opened this issue Apr 7, 2024 · 2 comments
Open

Cannot run useradd command in a container created by nerdctl+kata. #2921

zibinpan opened this issue Apr 7, 2024 · 2 comments
Labels
kind/external question Further information is requested status/needs-more-information Needs more information from OP

Comments

@zibinpan
Copy link

zibinpan commented Apr 7, 2024

Description

I cannot run the command useradd in my host, as seen below:
image

For the purpose of learning, I want to create new user in my server. Hence, I use nerdctl + kata container to create a container in rootfull mode. However, in this container, I still cannot run the useradd command, as seen below:
image

So how to fix it? Thank you very much!

Steps to reproduce the issue

  1. run nerdctl run -it --runtime io.containerd.kata.v2 ubuntu:20.04 sh to enter a container.
  2. run su to enter the root mode in the container.
  3. execute useradd, and then it raises the problem.

Describe the results you received and expected

I want to have the totally full root authority in my container created by nerdctl + kata.

What version of nerdctl are you using?

nerdctl: 1.7.5
kata: 3.3.0

Are you using a variant of nerdctl? (e.g., Rancher Desktop)

None

Host information

No response

@zibinpan zibinpan added the kind/unconfirmed-bug-claim Unconfirmed bug claim label Apr 7, 2024
@AkihiroSuda
Copy link
Member

I cannot run the command useradd in my host, as seen below:
image

What is printing this error? Some third-party security software?

@AkihiroSuda AkihiroSuda added the status/needs-more-information Needs more information from OP label Apr 8, 2024
@zibinpan
Copy link
Author

zibinpan commented Apr 8, 2024

I cannot run the command useradd in my host, as seen below:
image

What is printing this error? Some third-party security software?

Yeah, it is printed by a higher level tower management system, which limits my host to run some commands like useradd. Therefore, I created a container with kata technique and I thought I could have a full control of my container. However, in the created container, I still cannot execute the commands that are forbidden in my host.

@AkihiroSuda AkihiroSuda added question Further information is requested kind/external and removed kind/unconfirmed-bug-claim Unconfirmed bug claim labels Apr 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/external question Further information is requested status/needs-more-information Needs more information from OP
Projects
None yet
Development

No branches or pull requests

2 participants