question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Unable to run Embedded MongoDB on Macbook Pro with M1 CPU (ARM architecture)

See original GitHub issue

As title says - it looks similiar to issue #336.

Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [de.flapdoodle.embed.mongo.MongodExecutable]: Factory method 'embeddedMongoServer' threw exception; nested exception is java.lang.IllegalArgumentException: this version does not support 32Bit: Version{3.5.5}:OS_X:B32
	at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:185)
	at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:652)
	... 82 more
Caused by: java.lang.IllegalArgumentException: this version does not support 32Bit: Version{3.5.5}:OS_X:B32
	at de.flapdoodle.embed.mongo.Paths.getBitSize(Paths.java:157)
	at de.flapdoodle.embed.mongo.Paths.getPath(Paths.java:97)
	at de.flapdoodle.embed.process.store.LocalArtifactStore.getArtifact(LocalArtifactStore.java:71)
	at de.flapdoodle.embed.process.store.LocalArtifactStore.checkArtifact(LocalArtifactStore.java:38)
	at de.flapdoodle.embed.process.store.ArtifactStore.checkDistribution(ArtifactStore.java:65)
	at de.flapdoodle.embed.process.store.ExtractedArtifactStore.checkDistribution(ExtractedArtifactStore.java:60)
	at de.flapdoodle.embed.process.runtime.Starter.prepare(Starter.java:52)
	at de.flapdoodle.embed.process.runtime.Starter.prepare(Starter.java:45)
	at org.springframework.boot.autoconfigure.mongo.embedded.EmbeddedMongoAutoConfiguration.embeddedMongoServer(EmbeddedMongoAutoConfiguration.java:113)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
	at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:154)
	... 83 more

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:11
  • Comments:38 (19 by maintainers)

github_iconTop GitHub Comments

25reactions
Trundichocommented, Mar 9, 2021

A dirty workaround for local development (don’t use it in prod environment) on your M1 mac you can add the following in the static block of your @SpringBootApplication static { System.setProperty("os.arch", "i686_64"); }

3reactions
michaelmosmanncommented, May 22, 2022
Read more comments on GitHub >

github_iconTop Results From Across the Web

Unable to run Embedded MongoDB on Macbook Pro with M1 ...
Unable to run Embedded MongoDB on Macbook Pro with M1 CPU (ARM architecture)
Read more >
Support for Apple M1 Silicon? - MongoDB Server Development
Apple Silicon (aka ARM64 on macOS) is not a Supported Platform yet for MongoDB server or database tools. Some relevant issues to watch...
Read more >
How to Install and Run MongoDB on M1 (Apple Silicon) Macs
Step 1: Create a new terminal that opens using Rosetta. Open Finder and search for “Terminal”, then scroll down until you find the...
Read more >
Linker | Apple Developer Forums
Use ld to make your programs and link archive libraries at build time. ... not found for architecture arm64 clang: error: linker command...
Read more >
ARM Mac: Why I'm Worried About Virtualization - Hacker News
That would mean that physically the most performant option to run x86 code on an ARM CPU is dynamic translation (like QEMU-TCG or...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found