Mmap() failed: Out of memory size

io.realm.exceptions.RealmError: Unrecoverable error. mmap() failed: Out of memory size: 1073741824 offset: 0 in /Users/cm/Realm/realm-java-release/realm/realm-library/src/main/cpp/io_realm_internal_OsSharedRealm.cpp line 101
at io.realm.internal.OsSharedRealm.nativeGetSharedRealm(Native Method)
at io.realm.internal.OsSharedRealm.(
at io.realm.internal.OsSharedRealm.getInstance(
at io.realm.internal.OsSharedRealm.getInstance(
at io.realm.RealmCache.doCreateRealmOrGetFromCache(
at io.realm.RealmCache.createRealmOrGetFromCache(
at io.realm.Realm.getDefaultInstance(

minSdkVersion 22
targetSdkVersion 28
classpath “io.realm:realm-gradle-plugin:6.0.0”

a database of 1GB, even can’t delete data because you get this error.
Please help to solve the problem :frowning:

I have many places I read about this problem, basically there was a transaction, but I have an error voznikaet immediately after initialisatie, that is, no other transaction no.

@mherarsh It best to report bugs like this at github realm/realm-java. That said, it’s hard to help without a bit more context and details about how you ended up with such a big file, and if that’s expected. You can try opening the file with Realm Studio in case you want to delete data from it and compact it again.

Hello, thanks for the feedback! to get this database from the phone I had to root the device to take out the base, then I got the data on the PC, but it’s not good, because if it’s a database issue that urgently needs to come up with something!