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

Mac M1 Function Not Implemented Error #5328

Closed
JacobT14 opened this issue Feb 10, 2021 · 2 comments
Closed

Mac M1 Function Not Implemented Error #5328

JacobT14 opened this issue Feb 10, 2021 · 2 comments
Labels
area/m1 M1 preview builds area/multiarch Multi-arch tooling or images lifecycle/locked

Comments

@JacobT14
Copy link

JacobT14 commented Feb 10, 2021

Hey all! I have the following docker-compose.yml file

version: "3.4"

services:
  eventstore.db:
    image: eventstore/eventstore:20.10.0-bionic
    environment:
      - EVENTSTORE_CLUSTER_SIZE=1
      - EVENTSTORE_RUN_PROJECTIONS=All
      - EVENTSTORE_START_STANDARD_PROJECTIONS=true
      - EVENTSTORE_EXT_TCP_PORT=1113
      - EVENTSTORE_EXT_HTTP_PORT=2113
      - EVENTSTORE_INSECURE=true
      - EVENTSTORE_ENABLE_EXTERNAL_TCP=true
      - EVENTSTORE_ENABLE_ATOM_PUB_OVER_HTTP=true
    ports:
      - "1113:1113"
      - "2113:2113"
    volumes:
      - type: volume
        source: eventstore-volume-data
        target: /var/lib/eventstore
      - type: volume
        source: eventstore-volume-logs
        target: /var/log/eventstore
    networks:
      shared:
        aliases:
          - eventstore
volumes:
  eventstore-volume-data:
  eventstore-volume-logs:
  database-data: # named volumes can be managed easier using docker-compose
  
networks:
  shared:
    driver: bridge

After running docker-compose up, I get the following error


eventstore.db_1     | [    1, 1,17:38:58.368,FTL] Host terminated unexpectedly.
eventstore.db_1     | System.IO.IOException: Function not implemented
eventstore.db_1     |    at System.IO.FileSystemWatcher.StartRaisingEvents()
eventstore.db_1     |    at System.IO.FileSystemWatcher.StartRaisingEventsIfNotDisposed()
eventstore.db_1     |    at System.IO.FileSystemWatcher.set_EnableRaisingEvents(Boolean value)
eventstore.db_1     |    at Microsoft.Extensions.FileProviders.Physical.PhysicalFilesWatcher.TryEnableFileSystemWatcher()
eventstore.db_1     |    at Microsoft.Extensions.FileProviders.Physical.PhysicalFilesWatcher.CreateFileChangeToken(String filter)
eventstore.db_1     |    at Microsoft.Extensions.FileProviders.PhysicalFileProvider.Watch(String filter)
eventstore.db_1     |    at Microsoft.Extensions.Configuration.FileConfigurationProvider.<.ctor>b__1_0()
eventstore.db_1     |    at Microsoft.Extensions.Primitives.ChangeToken.ChangeTokenRegistration`1..ctor(Func`1 changeTokenProducer, Action`1 changeTokenConsumer, TState state)
eventstore.db_1     |    at Microsoft.Extensions.Primitives.ChangeToken.OnChange(Func`1 changeTokenProducer, Action changeTokenConsumer)
eventstore.db_1     |    at Microsoft.Extensions.Configuration.FileConfigurationProvider..ctor(FileConfigurationSource source)
eventstore.db_1     |    at Microsoft.Extensions.Configuration.Json.JsonConfigurationSource.Build(IConfigurationBuilder builder)
eventstore.db_1     |    at Microsoft.Extensions.Configuration.ConfigurationBuilder.Build()
eventstore.db_1     |    at EventStore.Common.Log.EventStoreLoggerConfiguration.Initialize(String logsDirectory, String componentName, String logConfig) in /build/src/EventStore.Common/Log/EventStoreLoggerConfiguration.cs:line 58
eventstore.db_1     |    at EventStore.Core.EventStoreHostedService`1.Init(TOptions options) in /build/src/EventStore.Core/EventStoreHostedService.cs:line 89
eventstore.db_1     |    at EventStore.ClusterNode.ClusterVNodeHostedService.Init(ClusterNodeOptions options) in /build/src/EventStore.ClusterNode/ClusterVNodeHostedService.cs:line 44
eventstore.db_1     |    at EventStore.Core.EventStoreHostedService`1..ctor(String[] args) in /build/src/EventStore.Core/EventStoreHostedService.cs:line 45
eventstore.db_1     |    at EventStore.ClusterNode.ClusterVNodeHostedService..ctor(String[] args) in /build/src/EventStore.ClusterNode/ClusterVNodeHostedService.cs:line 35
eventstore.db_1     |    at EventStore.ClusterNode.Program.Main(String[] args) in /build/src/EventStore.ClusterNode/Program.cs:line 22
src_eventstore.db_1 exited with code 1

Normally, I would say that the image is messed up, but this compose file works on any other machine, except for the new Macbook Air. I tried restarting docker etc, but no luck.

I also find it interesting, because at this point, the docker image is running, and should therefore be disconnected from my host arch. But, I'm not going to pretend I understand the inner workings of Docker at this point.

Any ideas on a quick fix, or is this a bug due to the new chip?

EDIT:

A one-liner for testing is here:
docker run --name esdb-node -it -p 2113:2113 -p 1113:1113 \ eventstore/eventstore:latest --insecure --run-projections=All

@stephen-turner stephen-turner added the area/m1 M1 preview builds label Feb 10, 2021
@djs55
Copy link
Contributor

djs55 commented Feb 12, 2021

@JacobT14 thanks for the one-liner repro -- I confirm that it reproduces for me locally too.

When running x86/amd64 code in a container on M1 the binaries are emulated with qemu. The emulation is not perfect and it can go wrong -- I believe this is one of those times.

The ideal solution in terms of reliability and performance would be to have a native arm64 image. I notice this was requested before: EventStore/EventStore#2380 . Perhaps now that the new Apple hardware is so popular it's worth commenting on that issue to bring this topic up again.

I'm sorry I couldn't help more directly. Let me know if you encounter any other issues on M1.

@djs55 djs55 closed this as completed Feb 12, 2021
@djs55 djs55 added the area/multiarch Multi-arch tooling or images label Feb 12, 2021
@docker-robott
Copy link
Collaborator

Closed issues are locked after 30 days of inactivity.
This helps our team focus on active issues.

If you have found a problem that seems similar to this, please open a new issue.

Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows.
/lifecycle locked

@docker docker locked and limited conversation to collaborators Mar 14, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area/m1 M1 preview builds area/multiarch Multi-arch tooling or images lifecycle/locked
Projects
None yet
Development

No branches or pull requests

4 participants