This morning my Samsung Galaxy Mega 6.3 (Android 4.4.2) rebooted suddenly. I was not doing anything at that time, and it was the very first time when it did that.
I managed to pull out a logcat using adb, but about 11 hours later. Also, I don't think that logcat was enabled on my phone at the time when the error occurred. Is there a way to see an error that is 12 hours long?
I suspect that the phone rebooted due to a system update. Is there a way to see a system update history, perhaps using an app instead of a code? I need the EXACT time (date + hour) of the last update.
Also, I don't think that logcat was enabled on my phone at the time when the error occurred
Logging is always enabled. LogCat simply reports what's in the log.
Is there a way to see an error that is 12 hours long?
The logging area is a ring buffer. It used to be fixed at 64KB. On Android 5.0, it is selectable by you via the Developer Options in the Settings app. I am not sure how big it is on Android 4.4 in general, let alone on a Samsung device.
How old the logs can be therefore is dependent on the size of the ring buffer and how much stuff gets logged. Unfortunately, production hardware logs a lot, so I would be skeptical that you can see 12+ hours back in the log. For example, on my Nexus 5, in a 256KB log buffer, I get about 8 hours of history.
Is there a way to see a system update history, perhaps using an app instead of a code?
Not that I am aware of, though that would be a better question for the Android Enthusiasts Stack Exchange.
Related
I'm seeing a small amount of logcat entries for my app since Android 13. I can usually only see a few minutes before plugging the phone in to check the logcat. If I leave it plugged in it doesn't clear and I can see as far back as I could when I first plugged it in. It's as if something is clearing the logcat. I have increased the log buffer size to 4M and then 8M and it's still the same. I should be able to see logcat entries from the previous day with such big log buffers. It's also the same whether checking the logcat from Android Studio or from the phone itself with a logcat reader app.
What should I check to solve this?
I debug with a Samsung Galaxy SII, running 2.3.6. I created an app that runs fine, every time, even under stress, on this device. I uploaded for a colleague in another state, using a device with 2.3.7 (I believe it's a Nexus One).
On his device, the app gives a "Not responding - Force Close or Wait" dialog when clicking a button that switches a ListView's adapter between 2 DB Cursors.
I tried on the emulator. Literally an hour and 45 minutes later (most of this time was spent converting JSON from a remote server to a local SQLite DB on the device, which happens only once during install, and I don't believe has any bearing on the issue I'm describing), I was able to recreate the problem, but nothing was reported in logcat.
Any ideas why I'm seeing this different results? My device works every time, his fails every time. I've tried targetting 2.1 and 2.2 - both have the same results on both devices and the emulator.
TYIA
I have similar problem in the past. My app is failing on the HTC device and working fine on google experience phone and emulators. Fortunately for me, both devices are mine and I was able to track down the problem after some digging. The cause is some differences in implementation of UI(HTC sense) and a few basic applications. My app fails because surprisingly, HTC is doing a good job of tightening up some loose code.It is a bit of a corner case. So, you need to have access to that device or give him a special build with writing Log to a file and send you back the file for you to debug.
apparently the devices had different SQLite implementations. The issue was resolved by adding a missing index to one of the SQLite tables.
I am experiencing a strange issue.
I am trying to collect some logs from my android phone using logcollector or aLogcat. Everything works just fine for my Nexus S and moto Defy but when I am trying to capture and send a log from Galaxy S the output is very very short. It captures only last few seconds of phone's activity.
Does anybody know how can I fix this?
Regards, Peter
Many possible things can be occurring here. Another process could be clearing the logcat buffer periodically (logcat -c). Galaxy S could have also modified the default buffer size for its logs to be very small (so it is constantly rolling them over). Other than that, who knows what it could be. The best I can think is to enable USB debugging and seeing if you can run logcat yourself and see what you can see (adb logcat). If you can see the logs fine then it is the app otherwise the system does not allow log collection.
use pipeline to save logs in text file from command prompt
adb logcat > logs.txt
The title speaks for itself, but I would add some pointers I've noticed along the way.
I would like anyone who also experiences the end result while developing for Android to try to reproduce this and see if this scenario is really the case.
The crash happens when Logcat is overpopulated. By overpopulated I mean that from a point in time, if you would leave a device connected in debug mode for a while, and you would look at the Logcat view, it would display only the new 'delta' lines added to the log in the past short interval of about two seconds.
If you would pay attention, while the Logcat is overpopulated, the device which is been debugged, responds slowly to user interaction (this can be your indication, that the Logcat is overpopulated while testing your application), and perform other actions ridiculously slow.
If you would leave the device connected and more logs would be added, there is a short interval 5-10 seconds, where Eclipse starts to behave weird, and after that, there is nothing you can do, Windows 7 freezes and only hard reboot allows you to get back to work.
I can reproduce this every time, if I would just leave a device connected in debug mode with an application running.
I've Googled this and came up with nothing. I assume that if me and my colleagues encounter this (we have the same Eclipse setup), then other should also experience this, so before posting a bug, I would like to confirm this...
Details:
Windows 7
Eclipse 3.6
ADT 10.0.0.v201102162101-104271 (latest for today)
I have the same problem here. I've been troubleshooting this for months! Mostly because it's been extremely difficult to find anyone with the same issue. (I was actually linked to this post from the bug report that Android Developer provided.)
I've been working with someone on a similar Stack Overflow issue. He thought the problem was his IDE until I reported that I was experiencing the same issue, but with a different IDE. Together, we've been able to whittle the problem down to either the device itself or the drivers. We recently just excluded the USB cables as the culprit.
However, the problems reported in the Google bug report are exactly what we've been experiencing. It makes sense that ADB might be where the problem ultimately lies.
Hopefully, this post will help create some search-friendly connections between the other posts.
Other Stack Overflow post mentioned above -- Android development in IntelliJ IDEA causes computer to freeze
Google bug report, Issue #24171 (originally posted by Android Developer) -- http://code.google.com/p/android/issues/detail?id=24171
I also have a similar problem. Sometimes, the Windows OS completely freeze when an Android device is connected.
I'm not sure why it happens, but I think that it only occurs when the ADB is active.
Here's a bug report I've found recently about this:
adb causes whole Windows operating system to freeze randomly
After using a USB from the back, and installing Windows 8, the problem doesn't occur any more.
However, it's Windows 8, and I wish I used Windows 7. For some reason, Microsoft didn't provide a way to go back...
Try setting your Eclipse Android Settings for the maximum amount of logcat messages in the buffer to a lower value.
This should help
I don't want to jump to conclusions, but I think I've found the real issue which causes this halt...
I'm going to make some assumptions, and if one of these does not fit your scenario, let me know:
Assumptions:
This only happens on a chargeable computer... Be very very sure before dismissing this assumption.
This happens when a laptop is connected to the adapter, and is being charged.
Cause:
This happens when you use a custom adapter, and not one that 100% fit your computer.
According to my experience, once I've used my home adapter on my work computer, the crash reoccurred over, and over, and over... drove me nuts... and when I got back to work, and used the proper adapter, the issue vanished!
Same with my home computer, and work adapter.
Lend me your thoughts...
I use IntelliJ IDEA to write Android apps, and use the DDMS Windows application to view the Android logs (separate from the IDE). It works fine, but after a seemingly random period of time, the logs vanish, except for one line of log, which gets overwritten with incoming logs. I have to shut it down and restart it, which combined with the delays of deploying an app to a device over ADB to debug and test is pretty tiresome.
Is this a known issue with DDMS? Is there anything I can do to make it work consistently without breaking itself?
Are there any other Android log viewing applications for Windows that work better? I'm not very fond of the IntelliJ IDEA one. My favourite is actually CatLog on Android itself, but on a small-screen device it's not a great experience.
It's not about the time, but number of lines being recorded. As Dave C said in the comment, just clear the log and it will be fine
Have you tried looking at "Why doesn't LogCat show anything in my Android?"? The top voted answer may solve your problem