Skip to content

[Bug]: On first container build, XPC timeout for request to com.apple.container.apiserver/containerCreate #857

Open

Description

@aoberoi

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

Follow the steps in docs/tutorial.md, until and including running the command container build --tag web-test --file Dockerfile .

Current behavior

On the terminal, I receive the following error:

Error: internalError: "failed to create container" (cause: "internalError: "XPC timeout for request to com.apple.container.apiserver/containerCreate"")

Expected behavior

Container to build successfully, and for it to be ready to run.

NOTE: Running the build command again did succeed. Maybe the timeout value is not appropriate, or maybe there's some other race condition at play.

Environment

- OS: macOS 26.0.1 (25A362)
- Xcode: 26.0.1
- Container: container CLI version 0.6.0 (build: release, commit: unspeci)

Relevant log output

Code of Conduct

  • I agree to follow this project's Code of Conduct

Activity

  1. added theissue type on Nov 6, 2025
  2. boychoi commented on Nov 12, 2025

    @boychoi

    you should try this

    Image

    the document says it is optional
    but i think it is nessasary

    so when you follow that step you will get build success result ^ _ ^

  3. katiewasnothere commented on Nov 25, 2025

    @katiewasnothere
    Contributor

    @aoberoi Hi! Thanks for the report! Can you confirm if this happens consistently when you try starting a container build for the first time? And just to confirm, is this happening with the main branch or with the package installed with the 0.6.0 installer?

    If this is happening consistently, I'd say let's first try to collect container system logs and boot logs. The steps would be like:

    1. container system start (if it was already running, do a container system stop first)
    2. container system logs --debug --follow
    3. In a new terminal, run your build command above.
    4. When that is done, see if you can get the container's bootlogs by running container logs --boot builder
    5. Provide the output from 2 and 4 here

    Let me know if there's any issues with these instructions! Thanks!

  4. aledbrown commented on Nov 28, 2025

    @aledbrown

    I also cannot complete the tutorial with the 0.6.0 installer version (container CLI version 0.6.0 (build: release, commit: a23bcf0)) - macOS 26.1 - M3 Max

    Output from 2:
    Filtering the log data using "subsystem ==[cd] "com.apple.container"" Timestamp Thread Type Activity PID TTL 2025-11-28 16:27:47.158452+0000 0x6aaa9c Error 0x0 49106 0 container-apiserver: [com.apple.container:APIServer] handler for containerDial threw error invalidState: "no sandbox client exists: container is stopped" 2025-11-28 16:27:47.212047+0000 0x6aaaa2 Info 0x0 49511 0 container-runtime-linux: [com.apple.container:RuntimeLinuxHelper] starting start [uuid=buildkit] 2025-11-28 16:27:47.213737+0000 0x6aaaa2 Info 0x0 49511 0 container-runtime-linux: [com.apple.container:RuntimeLinuxHelper] configuring XPC server [uuid=buildkit] 2025-11-28 16:27:47.213909+0000 0x6aaaa2 Info 0x0 49511 0 container-runtime-linux: [com.apple.container:RuntimeLinuxHelper] starting XPC server [uuid=buildkit] 2025-11-28 16:27:47.214137+0000 0x6aaab3 Info 0x0 49511 0 container-runtime-linux: [com.apple.container:RuntimeLinuxHelper] createEndpointxpc handler [uuid=buildkit] 2025-11-28 16:27:47.214614+0000 0x6aaaa2 Info 0x0 49511 0 container-runtime-linux: [com.apple.container:RuntimeLinuxHelper]bootstrapxpc handler [uuid=buildkit] 2025-11-28 16:27:47.218878+0000 0x6aa0d4 Info 0x0 49113 0 container-network-vmnet: [com.apple.container:NetworkVmnetHelper] allocated attachment [hostname=buildkit] [gateway=192.168.64.1] [id=default] [address=192.168.64.2/24] 2025-11-28 16:27:47.221267+0000 0x6aaab3 Info 0x0 49511 0 container-runtime-linux: [com.apple.container:RuntimeLinuxHelper] creating NATNetworkInterface with network reference [uuid=buildkit] 2025-11-28 16:27:47.601575+0000 0x6aaab4 Info 0x0 49511 0 container-runtime-linux: [com.apple.container:RuntimeLinuxHelper]startProcessxpc handler [uuid=buildkit] 2025-11-28 16:27:47.680485+0000 0x6aa001 Info 0x0 49106 0 container-apiserver: [com.apple.container:APIServer] registering container buildkit with exit monitor 2025-11-28 16:27:47.680607+0000 0x6aab52 Info 0x0 49511 0 container-runtime-linux: [com.apple.container:RuntimeLinuxHelper]statexpc handler [uuid=buildkit] 2025-11-28 16:27:47.681420+0000 0x6aaab3 Info 0x0 49511 0 container-runtime-linux: [com.apple.container:RuntimeLinuxHelper]waitxpc handler [uuid=buildkit] 2025-11-28 16:27:52.687979+0000 0x6aab52 Info 0x0 49511 0 container-runtime-linux: [com.apple.container:RuntimeLinuxHelper]dialxpc handler [uuid=buildkit] 2025-11-28 16:27:52.864636+0000 0x6aa0d7 Info 0x0 49114 0 container-core-images: [com.apple.container:ImagesHelper] ImagesService: pull(reference:platform:insecure:progressUpdate:) - ref: docker.io/library/python:alpine, platform: Optional(ContainerizationOCI.Platform(osVersion: nil, osFeatures: nil, variant: Optional("v8"), _rawOS: "linux", _rawArch: "arm64")), insecure: false

    Output from 4.
    container logs --boot builder
    Error: invalidArgument: "failed to fetch container logs for builder: notFound: "get failed: container builder not found""

    I did setup the DNS step as "container" instead of "test" as I wanted to have .container as the domain.

  5. aoberoi commented on Dec 4, 2025

    @aoberoi
    Author

    @katiewasnothere thanks for providing a procedure to gather logs. Unfortunately (or fortunately) I can't gather logs related to that issue anymore because I've since updated to the 0.7.0 release, and I was able to follow the tutorial successfully.

    As far as the other suggestions:

    • Rosetta 2: I already had it installed when I ran into the error a few weeks ago. This is not likely part of the cause.
    • local DNS domain: I did not follow those optional steps when I had the error, but I also didn't after updating to 0.7.0 and I did not have the error. So I don't think this is related either.

    Leaving the issue open for @aledbrown, who might still want to get to the bottom of it.

  6. katiewasnothere commented on Dec 5, 2025

    @katiewasnothere
    Contributor

    @aledbrown what steps did you take to install container? Did you already have a container installation before updating to 0.6.0?

  7. aledbrown commented on Dec 8, 2025

    @aledbrown

    @katiewasnothere it was a fresh install of 0.6.0. I will uninstall that and grab the 0.7.0 version and try again when I get a chance. As @aoberoi got it to work with the new version it'll likely be fine for me as well. Thanks.

  8. blimey74 commented on Jan 8, 2026

    @blimey74

    I have just installed container CLI version 0.7.1 (build: release, commit: 420be74) and I got the same error on my first execution on one of my own Dockerfiles. On the subsequent run the error did not occur.

  9. 0xpr03 commented on Feb 1, 2026

    @0xpr03

    Had the same just now - even with the test dns domain.
    Re-ran the command and it worked.

    $ container build --tagmariadb --file Dockerfile .
    Error: internalError: "failed to create container" (cause: "internalError: "XPC timeout for request to com.apple.container.apiserver/containerCreate"")
    
  10. JaewonHur commented on Feb 13, 2026

    @JaewonHur
    Contributor

    Hi @0xpr03, thank you for reporting this issue.
    Is it initial install of v0.9.0?

    Could you share the system log? You can get one by container system logs after running that command.

  11. 0xpr03 commented on Feb 16, 2026

    @0xpr03

    Hey, I upgraded my OS in the meantime and had stopped the engine.

    Filtering the log data using "subsystem ==[cd] "com.apple.container""
    Timestamp                       Thread     Type        Activity             PID    TTL  
    --------------------------------------------------------------------------------------------------------------------
    Log      - Default:          0, Info:                0, Debug:             0, Error:          0, Fault:          0
    Activity - Create:           0, Transition:          0, Actions:           0
    
  12. paulcdejean commented on Aug 1, 2026

    @paulcdejean

    Is it possible this is related to this issue? #2051

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions