lucavallin / barco

Linux containers from scratch in C.
https://lucavall.in
MIT License
1.49k stars 89 forks source link

Unable to enter the container as expected #5

Closed yowayimono closed 1 year ago

yowayimono commented 1 year ago

Hi ,lucavallin!

I am currently learning your container project and have cloned the code repository. Following your provided examples, I attempted to run the container but encountered an issue. Specifically, when I executed the code as instructed, the container did not enter as expected and exited immediately.

I have made multiple attempts and reviewed the code and relevant configurations, but the problem persists. My assumption is that I might have missed certain steps or configurations, but I am unsure about the specific cause.

My example of running it is like this:

image

image

My cgroups are already enabled,I hope you can answer this question!

yowayimono commented 1 year ago

Here is the detailed output information. image

ghost commented 1 year ago

Seems you are using zsh, try sudo ./bin/barco -u 0 -m / -c $(which zsh)

yowayimono commented 1 year ago

The problem is solved, and this project is fantastic! Thank you for your assistance.

lucavallin commented 1 year ago

@yowayimono Thanks for reporting the issue and glad to hear the problem is fixed and that you enjoy the project. @swordli-dev thanks for the quick help provided!