4

For the error "com.iota.iri.service.TipsManager - Ledger inconsistency detected", does the inconsistency here mean local database corruption? I checked the source code of tip manager and ledgerValidator but it's quite hard to understand. How does that algorithm exactly work?

  • I think inconsistency means that the subtangle is invalid, as it contains an invalid transaction – Werner der Champ Feb 15 '18 at 15:53
  • 1
    I cant find it in the source code, too. Probably a former version. Did you reproduce this error on your own? How? – Tobi MZ Feb 15 '18 at 18:19
  • No, this error is from another post. See the link provided by Tobi. – Jennifer Q Feb 16 '18 at 8:39
3

This error message was removed in April 2017. Thats the reason why you can't find it.

You can fix the issue by deleting your local database. Take a look here.

The code which contains this error message is following:

final Iterator<Map.Entry<Hash, Long>> stateIterator = state.entrySet().iterator();
        while (stateIterator.hasNext()) {

            final Map.Entry<Hash, Long> entry = stateIterator.next();
            if (entry.getValue() <= 0) {

                if (entry.getValue() < 0) {
                    log.error("Ledger inconsistency detected");
                    return null;
                }
                stateIterator.remove();
            }
        }

If there is more you want to know, the code can be found in Mainnet new Release 1.1.2.2.: TipsManager.java

| improve this answer | |
  • Yep, That post is where I first knew this error. I was curious about the error, so I looked into source code. But I couldn't find the error in latest version. Then I made this post to see if anyone knew the reason and detailed algorithm to check ledger inconsistency. – Jennifer Q Feb 16 '18 at 8:35
  • I found the former code for you – Tobi MZ Feb 16 '18 at 8:57
  • Thanks! In the latest version, I found the code in Snapshot.java – Jennifer Q Feb 16 '18 at 9:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.