Repository navigation
Open
Description
I have done the following
- I have searched the existing issues
- If possible, I've reproduced the issue using the 'main' branch of this project
Steps to reproduce
@jglogan I tried to reproduce the issue, but I'm unsure how to fully describe the problem, so I've copied all my command operations.
koala@MacBook-Pro ~ % uninstall-container.sh -d
Password:
Removed `container` tool and helpers
Removing `container` user data
koala@MacBook-Pro ~ % brew remove container
==> Uninstalling Cask container
==> Uninstalling packages with `sudo` (which may request your password)...
==> Purging files for version 0.4.1 of Cask container
koala@MacBook-Pro ~ % container --version
zsh: command not found: container
At this point, I have completely uninstalled container. After downloading and successfully installing the 0.4.1 package, I proceeded to attempt reproducing the issue:
koala@MacBook-Pro ~ % container --version
container CLI version 0.4.1 (build: release, commit: 4ac18b5)
koala@MacBook-Pro ~ % container system start
Verifying apiserver is running...
No default kernel configured.
Install the recommended default kernel from [https://github.com/kata-containers/kata-containers/releases/download/3.17.0/kata-static-3.17.0-arm64.tar.xz]? [Y/n]: y
Installing kernel...
koala@MacBook-Pro ~ % container iamges
Error: failed to find plugin named container-iamges
Usage: container [--debug] <subcommand>
See 'container --help' for more information.
koala@MacBook-Pro ~ % container iamges ls
Error: failed to find plugin named container-iamges
Usage: container [--debug] <subcommand>
See 'container --help' for more information.
koala@MacBook-Pro ~ % container images ls
NAME TAG DIGEST
koala@MacBook-Pro ~ % container images list
NAME TAG DIGEST
koala@MacBook-Pro ~ % brew install --casks container
==> Downloading https://formulae.brew.sh/api/cask.jws.json
==> Downloading https://github.com/apple/container/releases/download/0.4.1/container-0.4.1-installer-signed.pkg
Already downloaded: /Users/koala/Library/Caches/Homebrew/downloads/9a6d34905ad7b16cedcc4d3268afd6d4d6042da528f56bb466e8fb9a410288d9--container-0.4.1-installer-signed.pkg
==> Installing Cask container
==> Running installer for container with `sudo` (which may request your password)...
Password:
installer: Package name is container-0.4.1-installer-signed
installer: Upgrading at base path /
installer: The upgrade was successful.
🍺 container was successfully installed!
Warning: You are using macOS 26.
We do not provide support for this pre-release version.
This is a Tier 2 configuration:
https://docs.brew.sh/Support-Tiers#tier-2
You can report Tier 2 unrelated issues to Homebrew/* repositories!
Read the above document instead before opening any issues or PRs.
==> No outdated dependents to upgrade!
koala@MacBook-Pro ~ % container iamges ls
Error: failed to find plugin named container-iamges
Usage: container [--debug] <subcommand>
See 'container --help' for more information.
koala@MacBook-Pro ~ % container images ls
NAME TAG DIGEST
koala@MacBook-Pro ~ % container create --name openwrt --arch amd64 -c 4 -m 8G ubuntu:24.04
openwrt
koala@MacBook-Pro ~ % container list -a
ID IMAGE OS ARCH STATE ADDR
openwrt docker.io/library/ubuntu:24.04 linux amd64 stopped
koala@MacBook-Pro ~ % container start openwrt
openwrt
koala@MacBook-Pro ~ % container list -a
ID IMAGE OS ARCH STATE ADDR
openwrt docker.io/library/ubuntu:24.04 linux amd64 stopped
koala@MacBook-Pro ~ % container logs --boot openwrt
[ 0.130066] random: crng init done
[ 0.131969] brd: module loaded
[ 0.132814] loop: module loaded
[ 0.132935] virtio_blk virtio2: 1/0/0 default/read/poll queues
[ 0.133173] virtio_blk virtio2: [vda] 1048576 512-byte logical blocks (537 MB/512 MiB)
[ 0.133500] virtio_blk virtio3: 1/0/0 default/read/poll queues
[ 0.133725] virtio_blk virtio3: [vdb] 1073741824 512-byte logical blocks (550 GB/512 GiB)
[ 0.134638] VFIO - User Level meta-driver version: 0.3
[ 0.134972] rtc-pl031 20050000.pl031: registered as rtc0
[ 0.135019] rtc-pl031 20050000.pl031: setting system clock to 2025-08-30T02:46:44 UTC (1756522004)
[ 0.136389] xt_time: kernel timezone is -0000
[ 0.136492] IPVS: Registered protocols (TCP, UDP, SCTP, AH, ESP)
[ 0.136535] IPVS: Connection hash table configured (size=4096, memory=32Kbytes)
[ 0.136654] IPVS: ipvs loaded.
[ 0.136687] IPVS: [rr] scheduler registered.
[ 0.136728] IPVS: [wrr] scheduler registered.
[ 0.136791] IPVS: [lc] scheduler registered.
[ 0.136813] IPVS: [wlc] scheduler registered.
[ 0.136852] IPVS: [fo] scheduler registered.
[ 0.136893] IPVS: [ovf] scheduler registered.
[ 0.136912] IPVS: [lblc] scheduler registered.
[ 0.136951] IPVS: [lblcr] scheduler registered.
[ 0.136990] IPVS: [dh] scheduler registered.
[ 0.137032] IPVS: [sh] scheduler registered.
[ 0.137054] IPVS: [sed] scheduler registered.
[ 0.137096] IPVS: [nq] scheduler registered.
[ 0.137138] IPVS: [sip] pe registered.
[ 0.137232] Initializing XFRM netlink socket
[ 0.137286] NET: Registered PF_INET6 protocol family
[ 0.137637] Segment Routing with IPv6
[ 0.137681] In-situ OAM (IOAM) with IPv6
[ 0.137745] NET: Registered PF_PACKET protocol family
[ 0.137797] 9pnet: Installing 9P2000 support
[ 0.137914] NET: Registered PF_VSOCK protocol family
[ 0.139233] registered taskstats version 1
[ 0.141271] alg: No test for fips(ansi_cprng) (fips_ansi_cprng)
[ 0.142254] clk: Disabling unused clocks
[ 0.143495] EXT4-fs (vda): mounted filesystem 27a8ddcf-f805-4a14-949b-31b12025f930 ro without journal. Quota mode: disabled.
[ 0.143628] VFS: Mounted root (ext4 filesystem) readonly on device 254:0.
[ 0.143874] devtmpfs: mounted
[ 0.144054] Freeing unused kernel memory: 1856K
[ 0.144162] Run /sbin/vminitd as init process
2025-08-30T02:46:44+0000 info vminitd : [vminitd] checking for shim var FOREGROUND=nil
2025-08-30T02:46:44+0000 info vminitd : [vminitd] running vminitd under pid1
2025-08-30T02:46:44+0000 info vminitd : [vminitd] checking for shim var FOREGROUND=Optional("1")
2025-08-30T02:46:44+0000 info vminitd : [vminitd] vminitd booting...
2025-08-30T02:46:44+0000 info vminitd : [vminitd] serve vminitd api
2025-08-30T02:46:44+0000 debug vminitd : [vminitd] starting process supervisor
2025-08-30T02:46:44+0000 debug vminitd : port=1024 [vminitd] booting grpc server on vsock
2025-08-30T02:46:44+0000 info vminitd : port=1024 [vminitd] grpc api serving on vsock
2025-08-30T02:46:44+0000 debug vminitd : destination=/run/rosetta source=rosetta type=virtiofs [vminitd] mount
2025-08-30T02:46:44+0000 debug vminitd : request=Containerization.Com_Apple_Containerization_Sandbox_V3_SetupEmulatorRequest:
binary_path: "/run/rosetta/rosetta"
name: "x86_64"
type: "M"
magic: "\\x7fELF\\x02\\x01\\x01\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x00\\x02\\x00\\x3e\\x00"
mask: "\\xff\\xff\\xff\\xff\\xff\\xfe\\xfe\\x00\\xff\\xff\\xff\\xff\\xff\\xff\\xff\\xff\\xfe\\xff\\xff\\xff"
flags: "CF"
[vminitd] setupEmulator
2025-08-30T02:46:44+0000 debug vminitd : interface=lo up=true [vminitd] ip-link-set
2025-08-30T02:46:44+0000 debug vminitd : key=PATH value=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin [vminitd] setenv
2025-08-30T02:46:44+0000 debug vminitd : destination=/sys source=sysfs type=sysfs [vminitd] mount
2025-08-30T02:46:44+0000 debug vminitd : destination=/tmp source=tmpfs type=tmpfs [vminitd] mount
2025-08-30T02:46:44+0000 debug vminitd : destination=/dev/pts source=devpts type=devpts [vminitd] mount
2025-08-30T02:46:44+0000 debug vminitd : destination=/sys/fs/cgroup source=none type=cgroup2 [vminitd] mount
2025-08-30T02:46:44+0000 debug vminitd : dataSize=39 mode=0 path=/sys/fs/cgroup/cgroup.subtree_control [vminitd] writeFile
2025-08-30T02:46:44+0000 debug vminitd : destination=/run/container/openwrt/rootfs source=/dev/vdb type=ext4 [vminitd] mount
[ 0.297750] EXT4-fs (vdb): mounted filesystem 2bae5dc2-a921-45f9-8389-399c5fd71477 r/w without journal. Quota mode: disabled.
2025-08-30T02:46:44+0000 debug vminitd : addr=192.168.64.2/24 interface=eth0 [vminitd] ip-addr-add
2025-08-30T02:46:44+0000 debug vminitd : interface=eth0 up=true [vminitd] ip-link-set
2025-08-30T02:46:44+0000 debug vminitd : gateway=192.168.64.1 interface=eth0 [vminitd] ip-route-add-default
2025-08-30T02:46:44+0000 debug vminitd : domain= location=/run/container/openwrt/rootfs nameservers=["192.168.64.1"] [vminitd] configure-dns
2025-08-30T02:46:44+0000 debug vminitd : [vminitd] writing to path /run/container/openwrt/rootfs/etc/resolv.conf nameserver 192.168.64.1
2025-08-30T02:46:44+0000 debug vminitd : path=/run/container/openwrt/rootfs/etc/resolv.conf [vminitd] wrote resolver configuration
2025-08-30T02:46:44+0000 debug vminitd : location=/run/container/openwrt/rootfs [vminitd] configureHosts
2025-08-30T02:46:44+0000 debug vminitd : path=/run/container/openwrt/rootfs/etc/hosts [vminitd] wrote /etc/hosts configuration
2025-08-30T02:46:44+0000 debug vminitd : containerID=openwrt id=openwrt stderr=Port: 268435457 stdin=Port: 0 stdout=Port: 268435456 [vminitd] createProcess
2025-08-30T02:46:44+0000 debug vminitd : [vminitd] created bundle with spec Spec(version: "", hooks: nil, process: Optional(ContainerizationOCI.Process(cwd: "/", env: ["PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin", "HOME=/root"], consoleSize: nil, selinuxLabel: "", noNewPrivileges: false, commandLine: "", oomScoreAdj: nil, capabilities: nil, apparmorProfile: "", user: ContainerizationOCI.User(uid: 0, gid: 0, umask: nil, additionalGids: [0], username: ""), rlimits: [], args: ["/bin/bash"], terminal: false)), hostname: "openwrt", domainname: "", mounts: [ContainerizationOCI.Mount(type: "proc", source: "proc", destination: "/proc", options: ["nosuid", "noexec", "nodev"], uidMappings: [], gidMappings: []), ContainerizationOCI.Mount(type: "sysfs", source: "sysfs", destination: "/sys", options: ["nosuid", "noexec", "nodev"], uidMappings: [], gidMappings: []), ContainerizationOCI.Mount(type: "devtmpfs", source: "none", destination: "/dev", options: ["nosuid", "mode=755"], uidMappings: [], gidMappings: []), ContainerizationOCI.Mount(type: "mqueue", source: "mqueue", destination: "/dev/mqueue", options: ["nosuid", "noexec", "nodev"], uidMappings: [], gidMappings: []), ContainerizationOCI.Mount(type: "tmpfs", source: "tmpfs", destination: "/dev/shm", options: ["nosuid", "noexec", "nodev", "mode=1777", "size=65536k"], uidMappings: [], gidMappings: []), ContainerizationOCI.Mount(type: "cgroup2", source: "none", destination: "/sys/fs/cgroup", options: ["nosuid", "noexec", "nodev"], uidMappings: [], gidMappings: []), ContainerizationOCI.Mount(type: "devpts", source: "devpts", destination: "/dev/pts", options: ["nosuid", "noexec", "gid=5", "mode=620", "ptmxmode=666"], uidMappings: [], gidMappings: [])], annotations: nil, root: Optional(ContainerizationOCI.Root(path: "/run/container/openwrt/rootfs", readonly: false)), linux: Optional(ContainerizationOCI.Linux(uidMappings: [], gidMappings: [], sysctl: Optional([:]), resources: Optional(ContainerizationOCI.LinuxResources(devices: [], memory: nil, cpu: nil, pids: nil, blockIO: nil, hugepageLimits: [], network: nil, rdma: nil, unified: Optional([:]))), cgroupsPath: "/container/openwrt", namespaces: [], devices: [], seccomp: nil, rootfsPropagation: "", maskedPaths: [], readonlyPaths: [], mountLabel: "", personality: nil)))
2025-08-30T02:46:44+0000 info vminitd : mountpoint=/sys/fs/cgroup path=/sys/fs/cgroup/container/openwrt [vminitd] creating cgroup manager
2025-08-30T02:46:44+0000 info vminitd : id=openwrt [vminitd] starting io
2025-08-30T02:46:44+0000 info vminitd : id=openwrt [vminitd] setting up relay for StandardIO stdout
2025-08-30T02:46:44+0000 info vminitd : id=openwrt [vminitd] setting up relay for StandardIO stderr
2025-08-30T02:46:44+0000 info vminitd : [vminitd] created managed init process
2025-08-30T02:46:44+0000 debug vminitd : containerID=openwrt id=openwrt [vminitd] startProcess
2025-08-30T02:46:44+0000 debug vminitd : [vminitd] in supervisor lock to start process
2025-08-30T02:46:44+0000 info vminitd : id=openwrt [vminitd] starting managed process
2025-08-30T02:46:44+0000 info vminitd : id=89 [vminitd] got back pid data
2025-08-30T02:46:44+0000 debug vminitd : mountpoint=/sys/fs/cgroup path=/sys/fs/cgroup/container/openwrt [vminitd] adding new proc to cgroup
2025-08-30T02:46:44+0000 debug vminitd : [vminitd] received SIGCHLD, reaping processes
2025-08-30T02:46:44+0000 debug vminitd : [vminitd] starting to wait4 processes
2025-08-30T02:46:44+0000 debug vminitd : [vminitd] finished wait4 of 1 processes
2025-08-30T02:46:44+0000 debug vminitd : exits=[88: 0] processes=1 [vminitd] checking for exit of managed process
2025-08-30T02:46:44+0000 info vminitd : id=openwrt pid=89 [vminitd] sending pid acknowledgement
2025-08-30T02:46:44+0000 info vminitd : id=openwrt pid=89 [vminitd] started managed process
2025-08-30T02:46:44+0000 debug vminitd : [vminitd] out of supervisor lock to start process
2025-08-30T02:46:44+0000 debug vminitd : containerID=openwrt id=openwrt [vminitd] waitProcess
2025-08-30T02:46:44+0000 debug vminitd : id=openwrt [vminitd] received EPOLLHUP with no EPOLLIN
2025-08-30T02:46:44+0000 debug vminitd : id=openwrt [vminitd] received EPOLLHUP with no EPOLLIN
2025-08-30T02:46:44+0000 debug vminitd : [vminitd] received SIGCHLD, reaping processes
2025-08-30T02:46:44+0000 debug vminitd : [vminitd] starting to wait4 processes
2025-08-30T02:46:44+0000 debug vminitd : [vminitd] finished wait4 of 1 processes
2025-08-30T02:46:44+0000 debug vminitd : exits=[89: 0] processes=1 [vminitd] checking for exit of managed process
2025-08-30T02:46:44+0000 debug vminitd : count=0 pid=89 status=0 [vminitd] managed process exited
2025-08-30T02:46:44+0000 info vminitd : id=openwrt status=0 [vminitd] managed process exit
2025-08-30T02:46:44+0000 info vminitd : id=openwrt [vminitd] closing relay for StandardIO stdout
2025-08-30T02:46:44+0000 info vminitd : id=openwrt [vminitd] closing relay for StandardIO stderr
2025-08-30T02:46:44+0000 debug vminitd : id=openwrt [vminitd] 1 managed process waiters signaled
2025-08-30T02:46:44+0000 debug vminitd : pid=-1 signal=9 [vminitd] kill
2025-08-30T02:46:44+0000 debug vminitd : containerID=openwrt id=openwrt [vminitd] waitProcess
2025-08-30T02:46:44+0000 debug vminitd : flags=0 path=/run/container/openwrt/rootfs [vminitd] umount
[ 0.557634] EXT4-fs (vdb): unmounting filesystem 2bae5dc2-a921-45f9-8389-399c5fd71477.
2025-08-30T02:46:44+0000 debug vminitd : containerID=openwrt id=openwrt [vminitd] deleteProcess
koala@MacBook-Pro ~ % container list -a
ID IMAGE OS ARCH STATE ADDR
openwrt docker.io/library/ubuntu:24.04 linux amd64 stopped
koala@MacBook-Pro ~ % container start openwrt
openwrt
koala@MacBook-Pro ~ % container list -a
ID IMAGE OS ARCH STATE ADDR
openwrt docker.io/library/ubuntu:24.04 linux amd64 stopped
Current behavior
After using the container start command, the container fails to start.
Expected behavior
The container start command successfully runs a container.
Environment
- OS: Version 26.0 Beta (25A5346a)
- Xcode:
- Container: container CLI version 0.4.1 (build: release, commit: 4ac18b5)Relevant log output
Code of Conduct
- I agree to follow this project's Code of Conduct
Activity
minsvip commentedon Sep 2, 2025
It same to me.
jglogan commentedon Sep 2, 2025
Could you try running in one terminal:
and then in another:
Then copy the system logs and upload them here.
PunkFleet commentedon Sep 3, 2025
@jglogan lol, this method is awesome. I can view the entire activity log.
I noticed it's an AMD64 image issue?
2025-09-03 17:06:04.702630+0800 0x3adf Error 0x0 1099 0 container-core-images: [com.apple.container:ImagesHelper] handler for snapshotGet threw error notFound: "image snapshot for docker.io/library/ubuntu:24.04 with platform linux/amd64"I lack knowledge in this area, but checking the image source seems to pull normally. https://hub.docker.com/_/ubuntu/tags?name=24
jglogan commentedon Sep 9, 2025
The "image snapshot" is most likely not important. That it's logged as an error is misleading. I filed #589 for it.
It looks like your container process is exiting with status 0 almost as soon as the container starts. There's an error message right after that as well, but I'm not sure whether that's the real problem as your container is shutting down before it:
Are you building this container image from a Dockerfile, or are you getting it from a registry somewhere?
PunkFleet commentedon Sep 9, 2025
I am using standard commands.
container create --name openwrt -c 4 -m 8G ubuntu:24.04The source of this image is:jglogan commentedon Sep 9, 2025
I just noticed something; could you clarify something about the reproductions steps after the point where you fully uninstalled container?
It looks like you said you installed 0.4.1 from the package, and I see you running
container lsandcontainer image ls.Then it looks like you install the homebrew package for container as well? Is this really the case? I have no idea offhand what's going to happen with that sort of setup.
PunkFleet commentedon Sep 29, 2025
Sorry for the late reply. After completely uninstalling the brew package and the installer package, I first installed it via the installer package and then launched it. Immediately after that, I installed it from brew. That's how it went.
The earliest issue occurred in version 0.3.0. To be honest, this happened because I forgot to install it using the installer package. On macOS, I usually install things via brew, so that's how the problem arose. When I tried reinstalling via brew, it proceeded to install directly (overwrite?)
Perhaps we could add a duplicate installation detection method? To check if the container already exists on the target machine?
fix(xpc): improve timeout handling and error messages (apple#561)
fix(xpc): improve timeout handling and error messages (apple#561)
fix(xpc): improve timeout handling and error messages (apple#561)
fix(xpc): improve timeout handling and error messages (apple#561)
fix(xpc): prevent startup hangs with proper timeout handling (apple#561)
fix(xpc): prevent startup hangs with proper timeout handling (apple#561)