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

Fatal signal 11 (SIGSEGV), code 1, fault addr 0x28 in tid 6777 #3765

Closed
matomick opened this issue Nov 9, 2016 · 9 comments
Closed

Fatal signal 11 (SIGSEGV), code 1, fault addr 0x28 in tid 6777 #3765

matomick opened this issue Nov 9, 2016 · 9 comments
Labels

Comments

@matomick
Copy link

matomick commented Nov 9, 2016

I get this crash with some devices (Honor7, Xiaomi MI5, etc...), it seems like the realm database is corrupted, but it never happens with precedent realm versions. (current version: 2.1.1)

The crash appears on Realm.getInstance(conf)
Any ideas?

my realmConfig:
realmFileName = Realm.DEFAULT_REALM_NAME;
config = new RealmConfiguration.Builder()
.name(realmFileName)
.schemaVersion(versionSchema)
.encryptionKey(keykey)
.migration(new MigrationRealm())
.build();

logs:
A/libc: Fatal signal 11 (SIGSEGV), code 1, fault addr 0x28 in tid 6777 (cetts.messaging)
Build fingerprint: 'Xiaomi/gemini/gemini:6.0/MRA58K/V7.2.8.0.MAACNDB:user/release-keys'
pid: 6777, tid: 6777, name: cetts.messaging >>> com.facetts.messaging <<<
signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x28
sp 0000007fd4d0ae40 pc 0000007fab9653cc pstate 0000000060000000
backtrace:
#00 pc 00000000001523cc /data/app/com.facetts.messaging-2/lib/arm64/librealm-jni.so
#1 pc 000000000016593c /data/app/com.facetts.messaging-2/lib/arm64/librealm-jni.so
#2 pc 0000000000124918 /data/app/com.facetts.messaging-2/lib/arm64/librealm-jni.so
#3 pc 00000000001659bc /data/app/com.facetts.messaging-2/lib/arm64/librealm-jni.so
#5 pc 00000000000a1a24 /data/app/com.facetts.messaging-2/lib/arm64/librealm-jni.so
#6 pc 00000000000a8bf8 /data/app/com.facetts.messaging-2/lib/arm64/librealm-jni.so
#7 pc 00000000000bb750 /data/app/com.facetts.messaging-2/lib/arm64/librealm-jni.so
#8 pc 00000000000bf420 /data/app/com.facetts.messaging-2/lib/arm64/librealm-jni.so
#9 pc 00000000000b85dc /data/app/com.facetts.messaging-2/lib/arm64/librealm-jni.so
#10 pc 000000000004a788 /data/app/com.facetts.messaging-2/lib/arm64/librealm-jni.so (Java_io_realm_internal_SharedRealm_nativeGetSharedRealm+304)
#11 pc 00000000013f56fc /data/app/com.facetts.messaging-2/oat/arm64/base.odex (offset 0xbde000) (long io.realm.internal.SharedRealm.nativeGetSharedRealm(long, io.realm.internal.RealmNotifier)+160)
#12 pc 00000000013f46e4 /data/app/com.facetts.messaging-2/oat/arm64/base.odex (offset 0xbde000) (io.realm.internal.SharedRealm io.realm.internal.SharedRealm.getInstance(io.realm.RealmConfiguration, io.realm.internal.RealmNotifier, io.realm.internal.SharedRealm$SchemaVersionListener)+760)
#13 pc 00000000013f43a4 /data/app/com.facetts.messaging-2/oat/arm64/base.odex (offset 0xbde000) (io.realm.internal.SharedRealm io.realm.internal.SharedRealm.getInstance(io.realm.RealmConfiguration)+72)
#14 pc 00000000013c13cc /data/app/com.facetts.messaging-2/oat/arm64/base.odex (offset 0xbde000) (io.realm.BaseRealm io.realm.RealmCache.createRealmOrGetFromCache(io.realm.RealmConfiguration, java.lang.Class)+656)
#15 pc 0000000001a498c4 /data/app/com.facetts.messaging-2/oat/arm64/base.odex (offset 0xbde000) (io.realm.Realm io.realm.Realm.getInstance(io.realm.RealmConfiguration)+232)
#16 pc 000000000117e828 /data/app/com.facetts.messaging-2/oat/arm64/base.odex (offset 0xbde000) (io.realm.Realm com.valrsoft.facetts.controller.DataAccess.getRealmInstance()+2876)
#17 pc 000000000112dfb4 /data/app/com.facetts.messaging-2/oat/arm64/base.odex (offset 0xbde000) (void com.valrsoft.facetts.common.GarbageCollectorFacetts.facettsRecycle()+88)
#18 pc 0000000001130e70 /data/app/com.facetts.messaging-2/oat/arm64/base.odex (offset 0xbde000) (void com.valrsoft.facetts.common.GarbageCollectorFacetts.recycle()+68)
#19 pc 0000000001144fc0 /data/app/com.facetts.messaging-2/oat/arm64/base.odex (offset 0xbde000) (void com.valrsoft.facetts.common.cache.CacheData.(java.lang.String, java.lang.String, com.valrsoft.facetts.controller.DataAccess, android.content.Context)+17188)
#20 pc 000000000114aad8 /data/app/com.facetts.messaging-2/oat/arm64/base.odex (offset 0xbde000) (void com.valrsoft.facetts.common.cache.ImageStore.(java.lang.String, java.lang.String, com.valrsoft.facetts.controller.DataAccess, android.content.Context)+380)
#21 pc 00000000011c715c /data/app/com.facetts.messaging-2/oat/arm64/base.odex (offset 0xbde000) (void com.valrsoft.facetts.controller.FlowControler.init(android.content.Context)+3072)
#22 pc 0000000001234c58 /data/app/com.facetts.messaging-2/oat/arm64/base.odex (offset 0xbde000) (void com.valrsoft.facetts.ui.SplashScreenActivity.onCreate(android.os.Bundle)+3452)
#23 pc 0000000073ee0b70 /data/dalvik-cache/arm64/system@framework@boot.oat (offset 0x238a000)

@kneth
Copy link
Contributor

kneth commented Nov 10, 2016

How easy is it to reproduce? Does it happens every time?

Does it happens the first time, the app is opened?

@matomick
Copy link
Author

The database was allready created since a while, for my case I was using my app for 3 month.
It seems to be very rare. But the app crash without any exceptions, so I don't have any reports if it.

I think it could be an issue with the MIUI or EMUI android app killer (energy saver). If there is a transaction, and the app is killed during the commit, maybe it could corrupt the database?
Like with a non encrypted database, just the data of this transaction is corrupted, but with an encrypted database, all the database is corrupted...

@kneth
Copy link
Contributor

kneth commented Nov 10, 2016

@matomick Thanks for providing a hypothesis. Without reproduction, I can only comment in general terms. Realm should not corrupt a database if the app is kill during a transaction.

@cmelchior
Copy link
Contributor

Hi @matomick Without further information there is not much we can do about this. I'll close it for now, but feel free to reopen if more information about reproducing this surfaces.

@timmygap
Copy link

timmygap commented Nov 23, 2016

I had the same issue, but I don't got more Informationen than @matomick posted.
I used my app and write 5-10minutes and than the app crashed. After this I can´t start the app again. It Looks like that the database is corrupted.
@kneth

@Zhuinden
Copy link
Contributor

@tkrawetzke is the version 2.x+?

@timmygap
Copy link

2.1.1 and after updating to 2.2.0 the issue isn't resolved too.

@timmygap
Copy link

timmygap commented Nov 23, 2016

For me the init isn't the Problem.
Realm.init(context) (works)
RealmConfiguration.Builder().schemaVersion(10).migration(DatabaseMigration(context)).build() (works)
Realm.setDefaultConfiguration(configuration) (works)
Realm.getDefaultInstance() (crashed)

It looks like if I read or write on realm the app crashed.

@timmygap
Copy link

Currently we have solved the problem by downgrade the realm version to v2.0.2

More Information that we got:
We use a sync adapter and if we got much data the realm crashed while we update data after syncing it.
But in v2.0.2 we can´t repro it at the moment.

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

No branches or pull requests

6 participants