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

Fails to load in Ubuntu VM Docker on Mac M1 #9241

Closed
reubano opened this issue Dec 31, 2021 · 6 comments
Closed

Fails to load in Ubuntu VM Docker on Mac M1 #9241

reubano opened this issue Dec 31, 2021 · 6 comments
Labels

Comments

@reubano
Copy link

reubano commented Dec 31, 2021

Environment

$python --version
Python 3.9.9
  • Airbyte version
$ git show --format="%h" --no-patch
99a2ae608
  • OS Version / Instance
$ sw_vers
ProductName:	macOS
ProductVersion:	12.0.1
BuildVersion:	21A559

Parallels Desktop for Mac
Version 17.1.1 (51537)

ubuntu-20.04.3-live-server-arm64.iso

  • Deployment
$ docker --version
Docker version 20.10.12, build e91ed57

$ docker-compose --version
Docker Compose version v2.2.2
  • Severity: High
  • Step where error happened

docker-compose up

Current Behavior

https://docs.airbyte.io/deploying-airbyte/local-deployment

$ sudo docker-compose up
[+] Running 8/8
 ⠿ Container airbyte-db          Recreated                                                                   0.1s
 ⠿ Container airbyte-worker      Recreated                                                                   0.1s
 ⠿ Container airbyte-temporal    Recreated                                                                   0.1s
 ⠿ Container airbyte-server      Recreated                                                                   0.1s
 ⠿ Container airbyte-webapp      Recreated                                                                   0.1s
 ⠿ Container airbyte-scheduler   Recreated                                                                   0.1s
 ⠿ Container init                Recreated                                                                   0.1s
 ⠿ Container airbyte-bootloader  Recreated                                                                   0.1s
Attaching to airbyte-bootloader, airbyte-db, airbyte-scheduler, airbyte-server, airbyte-temporal, airbyte-webapp, airbyte-worker, init
init                | standard_init_linux.go:228: exec user process caused: exec format error
airbyte-scheduler   | standard_init_linux.go:228: exec user process caused: exec format error
init exited with code 1
airbyte-worker      | standard_init_linux.go:228: exec user process caused: exec format error
airbyte-webapp      | standard_init_linux.go:228: exec user process caused: exec format error
airbyte-bootloader  | standard_init_linux.go:228: exec user process caused: exec format error
airbyte-db          | standard_init_linux.go:228: exec user process caused: exec format error
airbyte-temporal    | standard_init_linux.go:228: exec user process caused: exec format error
airbyte-server      | standard_init_linux.go:228: exec user process caused: exec format error
airbyte-scheduler exited with code 0
airbyte-worker exited with code 1
...

Expected Behavior

No error

CR #2017

@alafanechere
Copy link
Contributor

Hi @reubano, I run on Airbyte on M1 with docker-compose without this problem.
Could you explain the motivation behind running Airbyte in an Ubuntu VM on M1?

@alafanechere alafanechere added area/platform issues related to the platform and removed needs-triage labels Jan 3, 2022
@reubano
Copy link
Author

reubano commented Jan 3, 2022

I've read that performance for docker on M1 wasn't great. Plus I've had very negative experiences using docker on mac in the past.

@reubano
Copy link
Author

reubano commented Jan 4, 2022

Switched to Docker Desktop for Mac and now get the following error when adding a source:

2022-01-04 07:01:39 �[32mINFO�[m i.a.w.t.TemporalAttemptExecution(get):118 - Docker volume job log path: /tmp/workspace/2acf41a5-5766-45cf-88fb-69734191b92a/0/logs.log
2022-01-04 07:01:39 �[32mINFO�[m i.a.w.t.TemporalAttemptExecution(get):123 - Executing worker wrapper. Airbyte version: 0.35.2-alpha
2022-01-04 07:01:40 �[32mINFO�[m i.a.w.t.TemporalAttemptExecution(lambda$getWorkerThread$2):177 - Completing future exceptionally...
io.airbyte.workers.WorkerException: Error while getting checking connection.
	at io.airbyte.workers.DefaultCheckConnectionWorker.run(DefaultCheckConnectionWorker.java:84) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.DefaultCheckConnectionWorker.run(DefaultCheckConnectionWorker.java:27) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.temporal.TemporalAttemptExecution.lambda$getWorkerThread$2(TemporalAttemptExecution.java:174) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at java.lang.Thread.run(Thread.java:833) [?:?]
Caused by: java.lang.RuntimeException: java.io.IOException: Cannot run program "/tmp/scripts16768339422251865990/image_exists.sh": error=0, Failed to exec spawn helper: pid: 162, exit value: 1
	at io.airbyte.workers.process.DockerProcessFactory.checkImageExists(DockerProcessFactory.java:199) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.process.DockerProcessFactory.create(DockerProcessFactory.java:96) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.process.AirbyteIntegrationLauncher.check(AirbyteIntegrationLauncher.java:60) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.DefaultCheckConnectionWorker.run(DefaultCheckConnectionWorker.java:53) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	... 3 more
Caused by: java.io.IOException: Cannot run program "/tmp/scripts16768339422251865990/image_exists.sh": error=0, Failed to exec spawn helper: pid: 162, exit value: 1
	at java.lang.ProcessBuilder.start(ProcessBuilder.java:1143) ~[?:?]
	at java.lang.ProcessBuilder.start(ProcessBuilder.java:1073) ~[?:?]
	at io.airbyte.workers.process.DockerProcessFactory.checkImageExists(DockerProcessFactory.java:187) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.process.DockerProcessFactory.create(DockerProcessFactory.java:96) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.process.AirbyteIntegrationLauncher.check(AirbyteIntegrationLauncher.java:60) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.DefaultCheckConnectionWorker.run(DefaultCheckConnectionWorker.java:53) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	... 3 more
Caused by: java.io.IOException: error=0, Failed to exec spawn helper: pid: 162, exit value: 1
	at java.lang.ProcessImpl.forkAndExec(Native Method) ~[?:?]
	at java.lang.ProcessImpl.<init>(ProcessImpl.java:314) ~[?:?]
	at java.lang.ProcessImpl.start(ProcessImpl.java:244) ~[?:?]
	at java.lang.ProcessBuilder.start(ProcessBuilder.java:1110) ~[?:?]
	at java.lang.ProcessBuilder.start(ProcessBuilder.java:1073) ~[?:?]
	at io.airbyte.workers.process.DockerProcessFactory.checkImageExists(DockerProcessFactory.java:187) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.process.DockerProcessFactory.create(DockerProcessFactory.java:96) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.process.AirbyteIntegrationLauncher.check(AirbyteIntegrationLauncher.java:60) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.DefaultCheckConnectionWorker.run(DefaultCheckConnectionWorker.java:53) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	... 3 more
2022-01-04 07:01:40 �[32mINFO�[m i.a.w.t.TemporalAttemptExecution(get):144 - Stopping cancellation check scheduling...
2022-01-04 07:01:40 �[33mWARN�[m i.t.i.s.POJOActivityTaskHandler(activityFailureToResult):363 - Activity failure. ActivityId=75af2092-3788-3f93-bf88-a4a5c78136f3, activityType=Run, attempt=1
java.util.concurrent.ExecutionException: io.airbyte.workers.WorkerException: Error while getting checking connection.
	at java.util.concurrent.CompletableFuture.reportGet(CompletableFuture.java:396) ~[?:?]
	at java.util.concurrent.CompletableFuture.get(CompletableFuture.java:2073) ~[?:?]
	at io.airbyte.workers.temporal.TemporalAttemptExecution.get(TemporalAttemptExecution.java:142) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.temporal.check.connection.CheckConnectionActivityImpl.run(CheckConnectionActivityImpl.java:81) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?]
	at jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77) ~[?:?]
	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
	at io.temporal.internal.sync.POJOActivityTaskHandler$POJOActivityInboundCallsInterceptor.execute(POJOActivityTaskHandler.java:286) ~[temporal-sdk-1.6.0.jar:?]
	at io.temporal.internal.sync.POJOActivityTaskHandler$POJOActivityImplementation.execute(POJOActivityTaskHandler.java:252) ~[temporal-sdk-1.6.0.jar:?]
	at io.temporal.internal.sync.POJOActivityTaskHandler.handle(POJOActivityTaskHandler.java:209) ~[temporal-sdk-1.6.0.jar:?]
	at io.temporal.internal.worker.ActivityWorker$TaskHandlerImpl.handle(ActivityWorker.java:193) ~[temporal-sdk-1.6.0.jar:?]
	at io.temporal.internal.worker.ActivityWorker$TaskHandlerImpl.handle(ActivityWorker.java:151) ~[temporal-sdk-1.6.0.jar:?]
	at io.temporal.internal.worker.PollTaskExecutor.lambda$process$0(PollTaskExecutor.java:73) ~[temporal-sdk-1.6.0.jar:?]
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) [?:?]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) [?:?]
	at java.lang.Thread.run(Thread.java:833) [?:?]
Caused by: io.airbyte.workers.WorkerException: Error while getting checking connection.
	at io.airbyte.workers.DefaultCheckConnectionWorker.run(DefaultCheckConnectionWorker.java:84) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.DefaultCheckConnectionWorker.run(DefaultCheckConnectionWorker.java:27) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.temporal.TemporalAttemptExecution.lambda$getWorkerThread$2(TemporalAttemptExecution.java:174) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	... 1 more
Caused by: java.lang.RuntimeException: java.io.IOException: Cannot run program "/tmp/scripts16768339422251865990/image_exists.sh": error=0, Failed to exec spawn helper: pid: 162, exit value: 1
	at io.airbyte.workers.process.DockerProcessFactory.checkImageExists(DockerProcessFactory.java:199) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.process.DockerProcessFactory.create(DockerProcessFactory.java:96) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.process.AirbyteIntegrationLauncher.check(AirbyteIntegrationLauncher.java:60) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.DefaultCheckConnectionWorker.run(DefaultCheckConnectionWorker.java:53) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.DefaultCheckConnectionWorker.run(DefaultCheckConnectionWorker.java:27) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.temporal.TemporalAttemptExecution.lambda$getWorkerThread$2(TemporalAttemptExecution.java:174) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	... 1 more
Caused by: java.io.IOException: Cannot run program "/tmp/scripts16768339422251865990/image_exists.sh": error=0, Failed to exec spawn helper: pid: 162, exit value: 1
	at java.lang.ProcessBuilder.start(ProcessBuilder.java:1143) ~[?:?]
	at java.lang.ProcessBuilder.start(ProcessBuilder.java:1073) ~[?:?]
	at io.airbyte.workers.process.DockerProcessFactory.checkImageExists(DockerProcessFactory.java:187) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.process.DockerProcessFactory.create(DockerProcessFactory.java:96) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.process.AirbyteIntegrationLauncher.check(AirbyteIntegrationLauncher.java:60) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.DefaultCheckConnectionWorker.run(DefaultCheckConnectionWorker.java:53) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.DefaultCheckConnectionWorker.run(DefaultCheckConnectionWorker.java:27) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.temporal.TemporalAttemptExecution.lambda$getWorkerThread$2(TemporalAttemptExecution.java:174) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	... 1 more
Caused by: java.io.IOException: error=0, Failed to exec spawn helper: pid: 162, exit value: 1
	at java.lang.ProcessImpl.forkAndExec(Native Method) ~[?:?]
	at java.lang.ProcessImpl.<init>(ProcessImpl.java:314) ~[?:?]
	at java.lang.ProcessImpl.start(ProcessImpl.java:244) ~[?:?]
	at java.lang.ProcessBuilder.start(ProcessBuilder.java:1110) ~[?:?]
	at java.lang.ProcessBuilder.start(ProcessBuilder.java:1073) ~[?:?]
	at io.airbyte.workers.process.DockerProcessFactory.checkImageExists(DockerProcessFactory.java:187) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.process.DockerProcessFactory.create(DockerProcessFactory.java:96) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.process.AirbyteIntegrationLauncher.check(AirbyteIntegrationLauncher.java:60) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.DefaultCheckConnectionWorker.run(DefaultCheckConnectionWorker.java:53) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.DefaultCheckConnectionWorker.run(DefaultCheckConnectionWorker.java:27) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	at io.airbyte.workers.temporal.TemporalAttemptExecution.lambda$getWorkerThread$2(TemporalAttemptExecution.java:174) ~[io.airbyte-airbyte-workers-0.35.2-alpha.jar:?]
	... 1 more

@mri-dula
Copy link

@reubano I was able to get past this error by adding JAVA_OPTS=-Djdk.lang.Process.launchMechanism=vfork to the worker's environment in docker-compose.yaml.

@alafanechere
Copy link
Contributor

alafanechere commented Jan 26, 2022

@reubano you'll find more details about existing M1 workarounds in this issue: #2017

@davinchia
Copy link
Contributor

This is solved by upgrading docker to > 4.6.1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

6 participants