The support forum is temporarily read-only. For urgent requests, please email contact[at]psyberia.net

[closed] Corrupted Tile Cache (Red Tiles)

Something wrong? Report it here
Post Reply
Yemble
Posts: 333
Joined: Sun Apr 28, 2013 5:02 pm

[closed] Corrupted Tile Cache (Red Tiles)

Post by Yemble »

This one goes under the strange behaviours category as I do not believe that this is an AQ bug (although I could be wrong)...

I have been using my Note 10.1 a lot recently to cache large areas of the UK at 1:50K & 1:25K scales. I have also been using it to find a suitable replacement for MapPoint, to use in conjunction with AQ for passenger vector based navigation (primary navigation is done with TomTom on my S3 phone). The apps I have been looking at include OSMand+, Navigator, Google Maps and TomTom. None of these come close to MapPoint for overall usability, although my wife has shown a slight preference for OSMand+ (even though it has an appalling search function).

What I have noticed on the Note, is that the SD card appears to become un-mounted at random times, usually when multiple GPS apps are running simultaneously. Naturally, AQ objects to this and usually freezes for a while before throwing an exception. Once the issue has occurred, the SD card remains inaccessible until the Note has been rebooted, after which everything is fine again and the SD card shows no sign of corruption.

Yesterday, something different occurred whilst I was tracking the car journey home following a day out. AQ was the only app in use. I first noticed an issue when some of the 1:50K tiles were shown as unavailable (white), even though I know for certain that they were all in cache (there was no GPRS feed at the time). Then some odd red tiles started to appear with an associated message about detected cache corruption. The vast majority of the tiles were showing correctly. When I got home, I tried to view the SD card with a file explorer, but it was inaccessible - AQ was still displaying most tiles correctly.

I then ejected the SD card and re-inserted it. This completely cured the issue and all of the previously missing / corrupted tiles were now instantly available from cache in AQ.

Given that I can find absolutely no issues with the SD card itself, either with Android, or with Windows, I am thinking that this is more likely to be some kind of application memory issue - maybe even a bug / leak with the JB 4.1.2 OS.

So my question to you is whether you can offer up any suggestions as to the circumstances when AQ would report some tiles as unavailable and some as corrupt, even though the cache itself is complete and not physically corrupt on the SD.
Psyberia-Support
Site Admin
Posts: 6407
Joined: Wed Apr 14, 2010 9:41 pm

Re: Corrupted Tile Cache (Red Tiles)

Post by Psyberia-Support »

Hi,
This is a weird issue which can be quite dangerous depending on what's happening at the time the SD card appears unavailable... (I thinking of incomplete writing operations that could leave the card into an inconsistent state)
Since you seem to have a large AQ cache storage, maybe a good thing would be to make a backup so the whole thing is not lost in case of a SD card corruption (even if until now everything came back to normal after a reboot).

Concerning the AQ behavior:
- White tiles are displayed if nothing can be found in the local storage (and there is no Internet access). It can happen if the storage path or index file don't exist, or if the particular tile is not stored.
- Red tiles (with a corruption warning) can be seen if a tile is marked as stored (so the storage index has been successfully read), but AQ fails to read it correctly (tile data missing or broken).

In your case, if AQ is running at the time the SD card becomes unavailable and is not restarted, it seems normal to see red tiles. What can happen is that some of the storage index data can still be available in the system cache (even if the SD card is no more available), so AQ thinks that the tile is available, but when it tries to read it, it fails (=> red tile). When looking for other tiles in a non-cached index part, AQ sees the index as missing and so the tile (=> white tile).
After a restart of AQ, all tiles should be displayed as missing (white).
Also, since the card is still physically present, it could be in an inconsistent state at the system level (not ejected, but not available), so some reads could still be tried and few succeeded...

Have you found similar user reports of ejected SD card with your particular device/android version?
Best regards
Do you like AlpineQuest ? Leave a small comment on Google Play !
Yemble
Posts: 333
Joined: Sun Apr 28, 2013 5:02 pm

Re: Corrupted Tile Cache (Red Tiles)

Post by Yemble »

I was puzzled as to how AQ continued to work when the SD card was not (fully) available, but you have explained that... it all depends upon which data is currently in which cache ;-)

It would be easy to blame a faulty SD card, however, I am pretty convinced that the SanDisk 64Gb micro-SD is OK. In fact as a precaution, I moved all of the data off, via my PC, onto my NAS and then copied it all back (a four hour plus operation). If the card was faulty, it would not have survived four hours of solid data transfer!

I keep wondering whether, or not, I should stick CyanogenMod (JB 4.2.2) on my Note, since it has been rock solid on my S3. Trouble is that I would have to sacrifice some useful Samsung proprietary functionality. I just wish that Samsung would get on with rolling JB 4.2.2 out officially to the field! Unfortunately, there is so much guff on the Internet, that it is impossible to get any clear correlation between the version of Android and memory / SD related bugs.

My gut feeling is that AQ is a victim here, rather than the culprit, but I need to keep an eye on this to see if any pattern emerges. At least I know that it does not appear to have any terminal consequences and that recovery seems straightforward.

Question: If a tile is found to be corrupt (ie. red) will AQ automatically attempt to re-download it if there is a path to the Internet?

I'll keep you posted if there are any further developments...
Post Reply