Hello IOTA Forum

Why latestSolidSubtangleMilestoneIndex not updating ?


By Thomas - 7 Dec 2017

Why latestSolidSubtangleMilestoneIndex not updating  (Already waited few days)?
The IRI node never reaches full sync, latestSolidSubtangleMilestoneIndex never catches up to latestMilestoneIndex
latestSolidSubtangleMilestoneIndex comes close to latestMilestoneIndex but then stops updating

for example from getNodeInfo:
latestMilestoneIndex: 297856 and latestSolidSubtangleMilestoneIndex: 297779

The code that updates latestSolidSubtangleMilestoneIndex is in Milestone,java

   if  (
      transactionValidator.checkSolidity(milestoneViewModel.getHash(), true) &&
      milestoneViewModel.index() >= latestSolidSubtangleMilestoneIndex &&
       latestSolidSubtangleMilestone = milestoneViewModel.getHash();
       latestSolidSubtangleMilestoneIndex = milestoneViewModel.index();

milestoneViewModel.index() is what is used to report latestMilestoneIndex, so milestoneViewModel.index() >= latestSolidSubtangleMilestoneIndex is true

The if statement is never executed after latestSolidSubtangleMilestoneIndex gets close to latestMilestoneIndex

Can anyone explain what is happening with:

transactionValidator.checkSolidity(milestoneViewModel.getHash(), true) &&

By Winston - 7 Dec 2017

@Thomas Someone more experienced than I am can chip in and help. My question is: how many neighbors do you have?
By Thomas - 7 Dec 2017

Winston  , I have 4 peers total.  3 peers using tcp and one peer using udp 
This issue was also mentioned by several people in github I think, but nobody had any answers.

transactionValidator.checkSolidity(milestoneViewModel.getHash(), true) &&

These two conditions return false always, that is why the if statement is not executed 
The if statement is inside a for loop which loops 10 times every 5 seconds.

The code in transactionValidator.checkSolidity and ledgerValidator.updateSnapshot is executed but always return false, in ledgerValidator.updateSnapshot the  statement 
hasSnapshot = currentState != null && latestSnapshot.patch(currentState, milestone.index()).isConsistent();
is always false because currentState is always null

I do not know if that is a bug or if it is supposed to work like that ,  
perhaps you can asked Paul, the module was Created by paul on 4/15/17.

By Thomas - 12 Dec 2017

After a long time waiting and nothing improving I followed the instructions in iota.partners to download a complete database:

 * download the complete database from http://db.iota.partners/IOTA.partners-mainnetdb.tar.gz (updated every 30 minutes) and extract in db folder;
* start the service and in max 5 hours you'll be FULL SYNC 

Indeed the node became synced  (latestMilestoneIndex: 301384 = latestSolidSubtangleMilestoneIndex: 301384) in few minutes, the corresponding transaction is YQMSDWGHWLCALRZQVPACMBX9KQ9VVXUGK9FTYEKJVNGGWKP9BYYBRDVYEKV9NEHHMTPMSMAFFOTP99999

However this milestone transaction  YQMSDWGHWLCALRZQVPACMBX9KQ9VVXUGK9FTYEKJVNGGWKP9BYYBRDVYEKV9NEHHMTPMSMAFFOTP99999 was already 5 hours old according to the IOTA explorer https://iotasear.ch/  and after waiting two more hours nothing has changed in my node, it still has the same latestMilestoneIndex: 301384 = latestSolidSubtangleMilestoneIndex: 301384


What is the reason that no new milestones are reaching my node ?

By Winston - 12 Dec 2017

@Thomas You might get some better answers by posting this in the Nodesharing forum as well.
By Thomas - 13 Dec 2017

I requested in the Nodesharing forum and got a couple more neighbors.
The node synced quickly after that , so finally is now ready for further testing and development.
Any one interested in building a real project let me now !