1

I recently had to factory reset my phone due to it crashing to the Android Recovery screen. It seems that several other users have had the same issue; all in the past week.

Is it possible to view system logs which were recorded prior to a factory reset, after the reset, in order to diagnose what may have caused this?

I suspect it's not as the reset wipes data; but hoping that logs are put to one side somewhere before the reset so that infromation about the root cause can be identified after the device's issues are resolved & it's again accessible.

Related: FairPhone Forum discussion on the underlying issue.

3
  • 2
    In a regular Android system logs are saved to the user data partition which is completely erased on factory reset. Unless FairPhone has modified Android in a way that certain logs are saved to a separate partition logs the factory reset has wiped everything in a way that makes it impossible to restore.
    – Robert
    Commented Nov 10, 2022 at 14:23
  • 1
    Logs are not saved to persistent storage unless you do so. Saving the logs to external storage or extracting the log files before performing the factory reset is also up to you. On some devices pstore also has a small buffer for userspace logs but that also needs to be configured. Commented Nov 10, 2022 at 14:26
  • Thank-you both; much appreciated.
    – JohnLBevan
    Commented Nov 10, 2022 at 14:46

1 Answer 1

0

UPDATE

Per the comments thread - this probably isn't a solution to the question I'd asked; rather this is just how to view logs (and it's possible to do without the app by running adb shell logcat (optionally writing to file by appending > logs.txt (note: the log is a continuous stream, so this won't stop until you stop it or the phone's disconnected) without the need for steps 3 & 7 below (i.e. those which relate to the Logcat Reader app).


I found a solution for the FairPhone 3...

  1. Enable developer mode:

    • swipe down from top of phone
    • swipe down from top of phone again
    • click the (i.e. the cog icon) to view the settings menu
    • click About Phone
    • tap the build number entry 7 times
  2. Enable USB Debugging:

    • return to the settings menu
    • click System
    • click Advanced
    • click Developer options
    • Enable USB debugging
  3. Install LogCat Reader via Google Play

  4. Connect the phone to your computer

    • use a USB to connect your computer's USB port to your phone's USB C port
    • swipe down from the top to see your notifications
    • tap the USB charging options menu
    • select file transfer
  5. On your computer install Android Debug Bridge (adb)

    • Documentation
    • Downloads
    • Download the appropriate version for your OS
    • Extract the files from the compressed file
  6. On your computer, connect adb to your phone

    • Open a command line & navigate to the extracted package tools folder
    • run adb shell pm grant com.dp.logcatapp android.permission.READ_LOGS
  7. Open the LogCat Reader app on your phone; it should now have access to view your device logs.

2
  • 3
    Hi John. This doesn't answer the question that you posted. This is an answer to a question which could be titled "How to view Android device logs?". For that this answer would work. Although that third-party app part is not needed there.
    – Firelord
    Commented Nov 12, 2022 at 12:36
  • @Firelord Ah sorry - this allowed me to find FATAL EXCEPTION: main from a time before I'd performed a factory reset; though there were no other logs there until much later (i.e. until the time at which I'd performed the reset). It's possible that I'm misremembering timings of events (I'd had to reset many times over the past few days so it's a bit of a blur); but assuming I've remembered correctly, maybe the FP3 stores the most recent fatal exceptions somewhere permanently? I admit that it's more likely that I'm wrong given everyone's saying this can't be done though.
    – JohnLBevan
    Commented Nov 13, 2022 at 8:41

Not the answer you're looking for? Browse other questions tagged .