When I run tor.exe -f torrc, one of the first messages in log file is:
Nov 25 19:51:48.000 [warn] ISO time "2018-11-25 17:00:00\r" was unparseableNov 25 19:51:48.000 [warn] Unable to parse networkstatus consensus
Version tested: 3741f9e5 on Windows 7 SP1 x64.
Trac: Username: Vort
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Child items 0
Show closed items
No child items are currently assigned. Use child items to break down this issue into smaller parts.
Linked items 0
Link issues together to show that they're related.
Learn more.
Hm. Does this happen with older versions of Tor, or is it a regression with this one?
To me it sounds like the issue is with the \r at the end of the line -- like the consensus file was saved in a windows text format, but it's being interpreted as a unix-style text format.
I was about to file this bug, too. This happens on Windows as well when testing in a Tor Browser context. I think this prevents Tor Browser starting up properly as I've seen numerous instances where Tor Browser "hangs" for 20 minutes after those messages. But that's "only" happening with a clean, new bundle on first start. Luckily, 0.3.5.5-alpha is fine, though.
I was about to file this bug, too. This happens on Windows as well when testing in a Tor Browser context. I think this prevents Tor Browser starting up properly as I've seen numerous instances where Tor Browser "hangs" for 20 minutes after those messages. But that's "only" happening with a clean, new bundle on first start. Luckily, 0.3.5.5-alpha is fine, though.
I think I am wrong. This just happens with testing Tor Browser 8.0.4 which ships 0.3.4.9. The result is that bootstrapping is delayed for several minutes (assuming that delay is actually caused by that parsing issue). I wonder, though, while this seems to be a new bug...
I was about to file this bug, too. This happens on Windows as well when testing in a Tor Browser context. I think this prevents Tor Browser starting up properly as I've seen numerous instances where Tor Browser "hangs" for 20 minutes after those messages. But that's "only" happening with a clean, new bundle on first start. Luckily, 0.3.5.5-alpha is fine, though.
I think I am wrong. This just happens with testing Tor Browser 8.0.4 which ships 0.3.4.9. The result is that bootstrapping is delayed for several minutes (assuming that delay is actually caused by that parsing issue). I wonder, though, while this seems to be a new bug...
Wait, scratch that. I think I took the wrong bundle to test. Sorry for the noise.
Mark some tickets as postfreeze-ok, to indicate that I think they are okay to accept in 0.4.0 post-freeze. Does not indicate that they are all necessary to do postfreeze.
Note that we don't pass it the RFTS_BIN flag, which means tor_open_cloexec()'s open() ultimately uses O_TEXT rather than O_BINARY for its flags.
But 0.4.0's networkstatus_map_cached_consensus_impl()'s tor_mmap_file() doesn't have the same Windows notion of O_TEXT.
And on Linux, open() doesn't care if it's binary or text because they're the same thing, so Linux (and really everything other than Windows) continued to work when we shifted from text to binary in 0.4.0.
Of course, for extra fun notice that we seem to have a Windows-specific mmap implementation: see the #elif _WIN32 version of tor_mmap_file().
Or maybe I am looking at this bug the wrong way around: how did it come to have \r's in it on disk? I assume it's because we wrote it with Windows-style O_TEXT which added the \r's. So if we want it to not have \r's in it when we read it, we need to write it in O_BINARY mode too? And then there will still be the edge case where we try to load a legacy file which has \r's in it, and we should teach ourselves to handle that case better (e.g. discard it and fetch another right then)?
Could we avoid that and just ask users to clear the old file if it's wrong?
We could, but that would be inconvenience to the users, and it's best not to inconvenience users for a problem that we can fix.
Not everybody is comfortable navigating inside folders and deleting stuff.
No user intervention then. But adding more code to core tor just for transition to a new file format is not the best option. Will you remove it when tor is upgraded?
Could we avoid that and just ask users to clear the old file if it's wrong?
We could, but that would be inconvenience to the users, and it's best not to inconvenience users for a problem that we can fix.
Not everybody is comfortable navigating inside folders and deleting stuff.
No user intervention then. But adding more code to core tor just for transition to a new file format is not the best option. Will you remove it when tor is upgraded?
Probably; would you like to open a ticket for that? This code will be relevant until all earlier versions of Tor are obsolete, since people have any time between now and then to update. Since 0.3.5.x is supported till 2022, we shouldn't remove it before then.
Could we avoid that and just ask users to clear the old file if it's wrong?
We could, but that would be inconvenience to the users, and it's best not to inconvenience users for a problem that we can fix.
Not everybody is comfortable navigating inside folders and deleting stuff.
No user intervention then. But adding more code to core tor just for transition to a new file format is not the best option. Will you remove it when tor is upgraded?
Probably; would you like to open a ticket for that? This code will be relevant until all earlier versions of Tor are obsolete, since people have any time between now and then to update. Since 0.3.5.x is supported till 2022, we shouldn't remove it before then.
Usually such tickets are buried in the Tor: unspecified milestone. And it's almost impossible that somebody will remind us about it in 2022 :(
The main drawback is that tor should do additional parsing again and again at runtime instead of one time deletion during update.
The problem is half-fixed.
Fresh installation have no such messages anymore.
But updating from 0.3.5.8 is still broken - same message pops out.
Tested version: 0.4.0.3-alpha.
The problem is half-fixed.
Fresh installation have no such messages anymore.
But updating from 0.3.5.8 is still broken - same message pops out.
Tested version: 0.4.0.3-alpha.
Yes, we should fix that message.
But does Tor successfully parse the consensus, after it logs the message?
But does Tor successfully parse the consensus, after it logs the message?
I am not sure how to check it.
Log says Mar 28 08:23:58.000 [notice] Bootstrapped 100% (done): Done
BTW, clean start of 0.4.0.3-alpha brings another problem:
Mar 28 08:26:00.000 [warn] Failed to unlink C:\Users\Vort\AppData\Roaming\tor\unverified-microdesc-consensus: Permission denied
Maybe it is related.
But does Tor successfully parse the consensus, after it logs the message?
I am not sure how to check it.
Log says Mar 28 08:23:58.000 [notice] Bootstrapped 100% (done): Done
Please send us a full copy of your logs.
Please delete any guard fingerprints or names.
We should be able to tell from the bootstrap progress and times if you needed a new consensus or not.
BTW, clean start of 0.4.0.3-alpha brings another problem:
Mar 28 08:26:00.000 [warn] Failed to unlink C:\Users\Vort\AppData\Roaming\tor\unverified-microdesc-consensus: Permission denied
Maybe it is related.
I don't think it is, but I opened #29930 (moved) for it.
Looks like the main issue here is mainly logging -- we're logging the failures at 'warning', but we're only logging the message about retrying at 'info'.