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

Miranda database problem #1428

Open
SmilingSpectre opened this Issue Jun 18, 2018 · 11 comments

Comments

Projects
None yet
4 participants
@SmilingSpectre

SmilingSpectre commented Jun 18, 2018

I have Miranda NG on USB-stick. It worked just fine for me, until today. Today I opened conversation... and everything hangs.

I tried to check DB settings - same hang. I tried to compact base - Miranda silently crashed.

In the old DB-format it usually means that base is corrupted. So I searched for fix tool... and found none. Nothing, except "compact database" is available.

What are my actions now?

I have crashdump. This is it.

2018.06.18.zip

@Goraf

This comment has been minimized.

Member

Goraf commented Jun 18, 2018

When it hangs then try to obtain some stack info following those instructions: Using_Process_Explorer_as_the_debugging_tool
Download page is showing 0.95.8 as a stable but those are 0.95.8.1 so the one you need. Extract .pdb files to the main Miranda NG folder (do not extract anything to Plugins folder), that way CrashDumper will also use them in case of crash.

You mentioned two scenarios in witch it hangs so just in case provide two stack info (one for every scenario). I don't know if "compact database" can do some harm in such cases but if you have backups of your profile (I see you have autobackup plugin) then try to reproduce that crash with installed debug symbols (as mentioned above) and attach new report. Right now it is missing information because of the lack of those symbols.

Did you did some updates to Miranda just before that unfortunate day or there was no such actions between the last time it worked fine?

@SmilingSpectre

This comment has been minimized.

SmilingSpectre commented Jun 18, 2018

Well, I haven't much access to internet at work, but I'll try debugging at home.

I did some experimenting with importing old backups while I am at work, and found some interesting problems. (Worth to ask for features, but so far I'll complain here to give you picture. :)

---import complains starts---

  • It's impossible to import settings, except "full" import.
  • It's impossible to import messages to date, not from it.
  • "Import all" effectively adds everything, regardless of duplicating. My 60Mb base become 120Mb in result.
    ---import complains end---

So, I got as far back as I could (it was 13 June, unfortunately). It works fine. Just as 14th. 15th and 16th doesn't work - and I noticed that it hangs on certain contact windows, not everywhere (again, totally fine for corrupted database). But... all this bases cannot be compacted, ends with the forementioned crash. So it's some problem with database. I suspect, it's result of conversing to new base format itself - I never tried to compact base before today, you see.

I tried to import data into new, clean database. It was semi-success.

  • "Full import" crashes just somewhere in the middle, missing half of my contacts and ICQ protocol. Unfortunately, it's only way to get my settings back.
  • "Import contacts and messages" after that works just fine... if not count that base has the same non-opening entries here and there. Trying to open it result in hang, when one core totally occupied, and Miranga,exe eaten more and more memory. Tested in XP, 7 and 10. But compacts just fine.
  • "Custom import" works somewhat. If I am getting last working base (from 13th) and import new messages here (from 13th and on) - I got totally working base. That still doesn't compact.
  • I tried combined approach: full import (crashed, but I got my settings), "contacts and messages" (worked), then "custom contact and messages" for everything. It was semi-success. I got working and compacting database. Unfortunately, it had 120Mb instead 60 and opened from stick on my slow working machine about 1+ minute.

I believe, it can be totally fixed (at least, on first glance) if I'll omiss second or third step and simply make custom import once (actually, I didn't notice that step 1 didn't enable ICQ, so I thought that I missed messages then repeated import with different settings. Clear error in current, buggy, importing state :)

But as I have no idea what's the reason of error in first time, I'll better ask for more informed conclusions - your. :) Will be here in several hours!

@georgehazan

This comment has been minimized.

Member

georgehazan commented Jun 18, 2018

@SmilingSpectre is there any crash log with debug symbols available?

@SmilingSpectre

This comment has been minimized.

SmilingSpectre commented Jun 18, 2018

Home results:

  1. Now it not hangs on opening reply windows. It's because my home computer is much more powerful than both work ones. (i5-8600 vs lower i3 for Win7). So while I checked wiki info about tracing with process viewer, window opened actually! About two minutes for each start though.

During opening it still eats full core (one from six) and stack says that:

coml2.dll!StgOpenStorage+0x1037e
mir_core.mir!Ordinal690+0x2c
  1. Base edit doesn't eat processor... and hangs on 30% forever. Process explorer says that:
wow64cpu.dll!TurboDispatchJumpAddressEnd+0x544
wow64cpu.dll!TurboDispatchJumpAddressEnd+0x421
wow64.dll!Wow64KiUserCallbackDispatcher+0x3686
wow64.dll!Wow64LdrpInitialize+0x120
ntdll.dll!LdrInitShimEngineDynamic+0x306d
ntdll.dll!LdrInitializeThunk+0x19e
ntdll.dll!LdrInitializeThunk+0x5b
ntdll.dll!LdrInitializeThunk+0xe

"hang" report relates to this situation.

  1. Attempt to compacting DB ends with crash. "crash" report included too
    2018.06.18-crash.zip
    2018.06.18-hang.zip

.

@georgehazan

This comment has been minimized.

Member

georgehazan commented Jun 20, 2018

such a stack is typical for entering discord servers with a lot of users, it might make Miranda very busy, it's a known problem. can you disable Discord for a while and check if that hang persisted?

@SmilingSpectre

This comment has been minimized.

SmilingSpectre commented Jun 20, 2018

Well, technically it can be Discord. I installed this plugin just at this weekend, and noticed delay at work after that.

But it's still feels wrong. Because:

  1. It's not Discord to hang. It's ICQ.
  2. I semi-restored functionality, as described before: I taken base of 13th, without delay, and imported messages from 13th and on from the latest base. And it have the same Discord - and totally works, without delays.
  3. Base still hangs on attempt to edit, and miranda crashes on compacting it.

But I will try discord idea at work. Unfortunately, with bad behavior of auto-save to kill backup it doesn't want and all this manipulations, I haven't here backups older than Tuesday. (I saved several at work when observed this behavior, before heavy manipulations. :)

@SmilingSpectre

This comment has been minimized.

SmilingSpectre commented Jun 27, 2018

I disabled and even deleted Discord. And imported my data into clean DB. Didn't work. Several ICQ contacts that was unresponsive before, remained the same. (Moreover, at least one such contact became unresponsive now again, in latest DB. :|

But it seems that crash is USB-stick related (even if I have free 400Mb on stick, and base is 60Mb). Because import totally worked when I did it on HDD-instance. So now I am bothered only with this "processor-greedy" ICQ.

@georgehazan

This comment has been minimized.

Member

georgehazan commented Jun 28, 2018

O_O how can ICQ eat CPU?
does it do that in the separate thread?

@SmilingSpectre

This comment has been minimized.

SmilingSpectre commented Jun 28, 2018

If I am look literate for you, georgehazan, it's only partially right. So I haven't no idea. :) I know that: after installing Discord, some of my ICQ contacts (in Miranda, of course) started to open dialogue windows as described above: 2 minutes for opening ICQ dialogue window with full loading of one core. Not any window, but several specific contacts.

Also, it was fixed when I got old (before Discord) base and import newer data over it.

And when I used the same (processor-hungry) base at work for test, but on new Miranda installation, it did the same. But... maybe not exactly the same. Because then I imported newer data and got new strange results:

  1. It eats CPU again even after importing newer data. And new backup (that was totally fine at home day before!) expose the same behavior. And even new base, that I created from scratch and then imported newest base - it stalls on the same ICQ contacts too. sigh But! Everything else works just right, unlike previous time, with trying to work on USB-stick.
  2. I waited about twenty minutes (my work machine is slow, mind you), just becase I haven't much to do with this Miranda anyway. And then window opened, just as in home. But! This time it "cleared" delay. I.e. after this everything works fine so far.

So... I have no idea what this Miranda did to my poor base, and why it worked on HDD, but didn't work on usb-stick before, but right now everything is fine. :)

@georgehazan

This comment has been minimized.

Member

georgehazan commented Jul 4, 2018

well, I just meant that you can use rather simple technique to build a stack when ICQ eats your CPU
https://wiki.miranda-ng.org/index.php?title=Using_Process_Explorer_as_the_debugging_tool

@SmilingSpectre

This comment has been minimized.

SmilingSpectre commented Jul 12, 2018

georgehazan, right now I suspect that it's combination of interaction between protocols, new base and faulty usb-stick. I changed the stick, so maybe it will fix problems (Right now it didn't for duplicate messages, but it's theme for another thread). If it will not, I'll ask here again.

But answering you, my initial message was about ICQ, as I happened. This one:

Now it not hangs on opening reply windows. It's because my home computer is much more powerful than both work ones. (i5-8600 vs lower i3 for Win7). So while I checked wiki info about tracing with process viewer, window opened actually! About two minutes for each start though.
During opening it still eats full core (one from six) and stack says that:

coml2.dll!StgOpenStorage+0x1037e
mir_core.mir!Ordinal690+0x2c

I thought that it affects any reply window, but in hindsight all (three) seemingly random cases was ICQ contacts. After I noticed it, I checked my other protocols - Steam, Jabber, Skype - and all are seems inaffected. Maybe it's coincidence, of course, but anyway - this quoted stack was about ICQ.

@dartraiden dartraiden added the blocker label Jul 12, 2018

@georgehazan georgehazan removed the blocker label Aug 30, 2018

@georgehazan georgehazan reopened this Aug 30, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment