syncthing-android icon indicating copy to clipboard operation
syncthing-android copied to clipboard

"Failed to create config file" on first launch

Open rijenkii opened this issue 1 year ago • 2 comments

Steps to reproduce

  1. Clear application data (or reinstall)
  2. Start application
  3. Complete first half of onboarding
  4. Application closes almost instantly, notifications "Syncthing was terminated" and "Failed to create config file" appear in the system drawer
Screen recording

https://github.com/syncthing/syncthing-android/assets/5338332/f14afcb6-baf9-421d-b900-52cf2148dedb

Logs

Syncthing log
--------- beginning of system
--------- beginning of main
05-23 23:11:55.601 I/SyncthingNativeCode(29173): INFO: Generating ECDSA key and certificate for syncthing...
Android log
--------- beginning of system
05-23 23:08:53.547 I/ActivityThread(26996): smart_link is  not supported!!!
05-23 23:08:59.979 I/ActivityThread(26996): smart_link is  not supported!!!
05-23 23:09:00.090 I/ActivityThread(26996): smart_link is  not supported!!!
05-23 23:09:01.821 I/ActivityThread(26996): smart_link is  not supported!!!
05-23 23:11:16.668 I/ActivityThread(26996): smart_link is  not supported!!!
05-23 23:11:49.866 I/ActivityThread(29173): smart_link is  not supported!!!
05-23 23:11:53.852 I/ActivityThread(29173): smart_link is  not supported!!!
05-23 23:11:53.966 I/ActivityThread(29173): smart_link is  not supported!!!
05-23 23:11:55.037 I/ActivityThread(29173): smart_link is  not supported!!!
05-23 23:12:12.012 I/ActivityThread(29173): smart_link is  not supported!!!
05-23 23:12:14.114 I/ActivityThread(29173): smart_link is  not supported!!!
05-23 23:12:15.548 I/ActivityThread(29173): smart_link is  not supported!!!
--------- beginning of main
05-23 23:12:16.653 I/gralloc4(29173): register: id=21f00096364
05-23 23:12:16.665 I/gralloc4(29173): register: id=21f00096363
05-23 23:12:16.686 I/gralloc4(29173): unregister: id=21f00096364
05-23 23:12:16.687 I/gralloc4(29173): unregister: id=21f00096363
05-23 23:12:16.687 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b34d0380 disconnect failed
05-23 23:12:16.690 I/gralloc4(29173): register: id=21f00096365
05-23 23:12:16.697 I/gralloc4(29173): register: id=21f00096366
05-23 23:12:16.714 I/gralloc4(29173): register: id=21f00096367
05-23 23:12:17.940 I/gralloc4(29173): unregister: id=21f00096365
05-23 23:12:17.940 I/gralloc4(29173): unregister: id=21f00096366
05-23 23:12:17.940 I/gralloc4(29173): unregister: id=21f00096367
05-23 23:12:17.940 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b34d0380 disconnect failed
05-23 23:12:18.983 I/gralloc4(29173): register: id=21f0009636a
05-23 23:12:19.010 I/gralloc4(29173): unregister: id=21f0009636a
05-23 23:12:19.010 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b3481730 disconnect failed
05-23 23:12:19.013 I/gralloc4(29173): register: id=21f0009636b
05-23 23:12:19.024 I/gralloc4(29173): register: id=21f0009636c
05-23 23:12:19.031 I/gralloc4(29173): register: id=21f0009636d
05-23 23:12:19.905 I/gralloc4(29173): unregister: id=21f0009636c
05-23 23:12:19.905 I/gralloc4(29173): unregister: id=21f0009636d
05-23 23:12:19.906 I/gralloc4(29173): unregister: id=21f0009636b
05-23 23:12:19.906 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b3481730 disconnect failed
05-23 23:12:20.173 I/gralloc4(29173): register: id=21f00096370
05-23 23:12:20.194 I/gralloc4(29173): register: id=21f0009636f
05-23 23:12:20.214 I/gralloc4(29173): unregister: id=21f00096370
05-23 23:12:20.214 I/gralloc4(29173): unregister: id=21f0009636f
05-23 23:12:20.214 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b3481730 disconnect failed
05-23 23:12:20.217 I/gralloc4(29173): register: id=21f00096371
05-23 23:12:20.224 I/gralloc4(29173): register: id=21f00096372
05-23 23:12:20.240 I/gralloc4(29173): register: id=21f00096373
05-23 23:12:20.979 I/gralloc4(29173): register: id=21f00096376
05-23 23:12:21.012 I/gralloc4(29173): register: id=21f00096375
05-23 23:12:21.039 I/gralloc4(29173): unregister: id=21f00096376
05-23 23:12:21.039 I/gralloc4(29173): unregister: id=21f00096375
05-23 23:12:21.039 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b347b100 disconnect failed
05-23 23:12:21.042 I/gralloc4(29173): register: id=21f00096377
05-23 23:12:21.047 I/gralloc4(29173): register: id=21f00096378
05-23 23:12:21.066 I/gralloc4(29173): register: id=21f00096379
05-23 23:12:21.317 I/gralloc4(29173): unregister: id=21f00096372
05-23 23:12:21.317 I/gralloc4(29173): unregister: id=21f00096373
05-23 23:12:21.318 I/gralloc4(29173): unregister: id=21f00096371
05-23 23:12:21.318 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b3481730 disconnect failed
05-23 23:12:23.199 I/gralloc4(29173): register: id=21f0009637c
05-23 23:12:23.215 I/gralloc4(29173): register: id=21f0009637b
05-23 23:12:23.236 I/gralloc4(29173): unregister: id=21f0009637c
05-23 23:12:23.236 I/gralloc4(29173): unregister: id=21f0009637b
05-23 23:12:23.236 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b34cbf60 disconnect failed
05-23 23:12:23.239 I/gralloc4(29173): register: id=21f0009637d
05-23 23:12:23.247 I/gralloc4(29173): register: id=21f0009637e
05-23 23:12:23.267 I/gralloc4(29173): register: id=21f0009637f
05-23 23:12:23.516 I/gralloc4(29173): unregister: id=21f00096379
05-23 23:12:23.517 I/gralloc4(29173): unregister: id=21f00096377
05-23 23:12:23.517 I/gralloc4(29173): unregister: id=21f00096378
05-23 23:12:23.517 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b347b100 disconnect failed
05-23 23:12:26.355 I/gralloc4(29173): unregister: id=21f0009637f
05-23 23:12:26.355 I/gralloc4(29173): unregister: id=21f0009637d
05-23 23:12:26.356 I/gralloc4(29173): unregister: id=21f0009637e
05-23 23:12:26.356 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b34cbf60 disconnect failed
05-23 23:12:28.216 W/androidtc(29173): TextClassifier called on main thread
05-23 23:12:28.433 W/androidtc(29173): TextClassifier called on main thread
05-23 23:12:28.465 I/gralloc4(29173): register: id=21f00096380
05-23 23:12:28.482 I/gralloc4(29173): register: id=21f00096383
05-23 23:12:28.507 I/gralloc4(29173): unregister: id=21f00096380
05-23 23:12:28.507 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b34ebe50 disconnect failed
05-23 23:12:28.510 I/gralloc4(29173): register: id=21f00096386
05-23 23:12:28.520 I/gralloc4(29173): unregister: id=21f00096383
05-23 23:12:28.520 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b34dcfe0 disconnect failed
05-23 23:12:28.523 I/gralloc4(29173): register: id=21f00096387
05-23 23:12:28.576 I/gralloc4(29173): register: id=21f0009638a
05-23 23:12:28.584 I/gralloc4(29173): register: id=21f00096389
05-23 23:12:28.613 I/gralloc4(29173): unregister: id=21f0009638a
05-23 23:12:28.614 I/gralloc4(29173): unregister: id=21f00096389
05-23 23:12:28.614 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b34e3610 disconnect failed
05-23 23:12:28.616 I/gralloc4(29173): register: id=21f0009638b
05-23 23:12:28.623 I/gralloc4(29173): register: id=21f0009638c
05-23 23:12:28.637 I/gralloc4(29173): register: id=21f0009638d
05-23 23:12:29.699 W/androidtc(29173): TextClassifier called on main thread
05-23 23:12:29.742 W/androidtc(29173): TextClassifier called on main thread
05-23 23:12:29.813 I/gralloc4(29173): unregister: id=21f0009638d
05-23 23:12:29.813 I/gralloc4(29173): unregister: id=21f0009638b
05-23 23:12:29.813 I/gralloc4(29173): unregister: id=21f0009638c
05-23 23:12:29.814 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b34e3610 disconnect failed
05-23 23:12:30.248 I/gralloc4(29173): register: id=21f00096390
05-23 23:12:30.254 I/gralloc4(29173): register: id=21f0009638f
05-23 23:12:30.274 I/gralloc4(29173): unregister: id=21f00096390
05-23 23:12:30.274 I/gralloc4(29173): unregister: id=21f0009638f
05-23 23:12:30.274 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b34e3610 disconnect failed
05-23 23:12:30.278 I/gralloc4(29173): register: id=21f00096391
05-23 23:12:30.284 I/gralloc4(29173): register: id=21f00096392
05-23 23:12:30.300 I/gralloc4(29173): register: id=21f00096393
05-23 23:12:31.044 W/androidtc(29173): TextClassifier called on main thread
05-23 23:12:31.049 I/gralloc4(29173): unregister: id=21f00096386
05-23 23:12:31.049 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b34ebe50 disconnect failed
05-23 23:12:31.057 I/gralloc4(29173): unregister: id=21f00096387
05-23 23:12:31.058 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b34dcfe0 disconnect failed
05-23 23:12:31.307 I/gralloc4(29173): unregister: id=21f00096392
05-23 23:12:31.307 I/gralloc4(29173): unregister: id=21f00096393
05-23 23:12:31.307 I/gralloc4(29173): unregister: id=21f00096391
05-23 23:12:31.308 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b34e3610 disconnect failed
05-23 23:12:31.878 I/gralloc4(29173): unregister: id=21f00096360
05-23 23:12:31.878 I/gralloc4(29173): unregister: id=21f0009635f
05-23 23:12:31.879 I/gralloc4(29173): unregister: id=21f00096361
05-23 23:12:31.879 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b33f0af0 disconnect failed
05-23 23:13:24.409 I/ActivityThread(29173): smart_link is  not supported!!!
05-23 23:13:24.440 I/gralloc4(29173): register: id=21f000963b7
05-23 23:13:24.453 I/gralloc4(29173): register: id=21f000963b6
05-23 23:13:24.474 I/gralloc4(29173): register: id=21f000963b5
05-23 23:13:25.171 I/gralloc4(29173): register: id=21f000963ba
05-23 23:13:25.202 I/gralloc4(29173): register: id=21f000963b9
05-23 23:13:25.221 I/gralloc4(29173): unregister: id=21f000963ba
05-23 23:13:25.221 I/gralloc4(29173): unregister: id=21f000963b9
05-23 23:13:25.222 W/libEGL  (29173): EGLNativeWindowType 0xb4000074b3459000 disconnect failed
05-23 23:13:25.225 I/gralloc4(29173): register: id=21f000963bb
05-23 23:13:25.233 I/gralloc4(29173): register: id=21f000963bc
05-23 23:13:25.249 I/gralloc4(29173): register: id=21f000963bd

Version Information

App Version: 1.27.6
Android Version: Android 11

rijenkii avatar May 23 '24 16:05 rijenkii

I saw the same thing on Android 14 with Syncthing version 1.28.0.

I ran into it because for some reason my syncthing died on android. Unfortunately, I didn't grab any logs before I started troubleshooting but I have other family members using it and if they run into issues I'll pull from their devices and open a new issue on that in particular.

What fixed this for me was completely uninstalling syncthing, restarting my phone, and re-installing it. I installed via obtanium of course, but I imagine f-droid should be the same thing. If you've already done that, could you try the direct APK download and see if that works?

It seems that there is something being held on to by syncthing after clearing the storage which is what the config error seems to be complaining about. I also forgot to grab that from my end, but my error when on after the "..." you shared and mentioned that a key had already been created so it would not override, which is what clued me in to do a full re-install of Syncthing with a power-off in the middle.

midwesternrodent avatar Oct 18 '24 19:10 midwesternrodent

What fixed this for me was completely uninstalling syncthing, restarting my phone, and re-installing it.

Tried that, did not work.

If you've already done that, could you try the direct APK download and see if that works?

Did not work either, exactly same logs, abruptly ending at "Generating ECDSA key", nothing about the key that it would not override.

rijenkii avatar Oct 19 '24 18:10 rijenkii