Skip to content
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

0.10.1-win64 does not start #6078

Closed
vayvanne opened this issue Apr 28, 2015 · 18 comments · Fixed by #6093
Closed

0.10.1-win64 does not start #6078

vayvanne opened this issue Apr 28, 2015 · 18 comments · Fixed by #6093

Comments

@vayvanne
Copy link

On some windows setups path to DB includes windows username, like C:\Users\uzza\AppData\Roaming\Bitcoin. If uzza is in non-English locale bitcoind does not start.
0.10.0 was all right although it did show unreadable symbols in place of username.

@jonasschnelli
Copy link
Contributor

Tested 0.10.1 on windows 7 with a username containing a "ä" and a "ö".
No problems (see proof screen below).

@vayvanne: could you be more precise?

  • Define "does not start" (any output in the log)?
  • Windows version?
  • What do you mean with "path to DB"? Do you mean --datadir=?

bildschirmfoto 2015-04-28 um 21 45 59

@vayvanne
Copy link
Author

I have got the following
bitcoind
in russian windows 7 x64
generally I do see russian letters in console but these printed out by bitcoind are unreadable.

@jonasschnelli
Copy link
Contributor

Indeed.
This is an issue.
It looks like that the boost filesystem library can't handle non-latin chars (or similar).
Will analyze this more precise.
I could also reproduce the issue with 0.10. @vayvanne: are you sure that 0.10 didn't had this problem? Can you post a screenshot/log of the startup using 0.10?

I also wonder why my windows shell is not capable of displaying a correct unicode value (but that's probably a different story).

bildschirmfoto 2015-04-29 um 08 28 14

bildschirmfoto 2015-04-29 um 08 28 49

@vayvanne
Copy link
Author

I am sure that 0.10.0 was running well on the same system. But I can not get it running now:
bitcoin-0 10 0
Error message is other than from first screenshot this time.
My guess is it was ok because DB was created with non-English symbols in paths. It is confirmed by this:
bitcoin-0 10 0-init
As you can see 0.10.0 inits ok with empty DB.
Then bitcoind was upgraded several times from 0.8 to 0.10. Not sure why the boot error is triggered on only in 0.10.1.
PS. you can get non-English letters in place of question marks if you set your language support for all programs that does not support unicode in windows control panel. For russian windows 7 it looks like this:
non-unicode

@vayvanne
Copy link
Author

I was wrong that 0.10.0 inits correctly with empty DB. It shuts down in short time:

2015-04-29 17:00:09
2015-04-29 17:00:09 Bitcoin version v0.10.0 (2015-02-13 09:55:11 +0100)
2015-04-29 17:00:09 Using OpenSSL version OpenSSL 1.0.1k 8 Jan 2015
2015-04-29 17:00:09 Using BerkeleyDB version Berkeley DB 4.8.30: (April 9, 2010)
2015-04-29 17:00:09 Default data directory C:\Users\юзза\AppData\Roaming\Bitcoin
2015-04-29 17:00:09 Using data directory C:\Users\юзза\AppData\Roaming\Bitcoin
2015-04-29 17:00:09 Using config file C:\Users\юзза\AppData\Roaming\Bitcoin\bitcoin.conf
2015-04-29 17:00:09 Using at most 125 connections (2048 file descriptors available)
2015-04-29 17:00:09 Using 2 threads for script verification
2015-04-29 17:00:09 Allowing RPC connections from: 127.0.0.0/255.0.0.0 ::1/ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff
2015-04-29 17:00:09 Using wallet wallet.dat
2015-04-29 17:00:09 init message: Verifying wallet...
2015-04-29 17:00:09 CDBEnv::Open : LogDir=C:\Users\юзза\AppData\Roaming\Bitcoin\database ErrorFile=C:\Users\юзза\AppData\Roaming\Bitcoin\db.log
2015-04-29 17:00:09 Bound to [::]:8333
2015-04-29 17:00:09 Bound to 0.0.0.0:8333
2015-04-29 17:00:09 init message: Loading block index...
2015-04-29 17:00:09 Opening LevelDB in C:\Users\юзза\AppData\Roaming\Bitcoin\blocks\index
2015-04-29 17:00:09 Opened LevelDB successfully
2015-04-29 17:00:09 Opening LevelDB in C:\Users\юзза\AppData\Roaming\Bitcoin\chainstate
2015-04-29 17:00:09 Opened LevelDB successfully
2015-04-29 17:00:09 LoadBlockIndexDB: last block file = 0
2015-04-29 17:00:09 LoadBlockIndexDB: last block file info: CBlockFileInfo(blocks=1, size=293, heights=0...0, time=2009-01-03...2009-01-03)
2015-04-29 17:00:09 Checking all blk files are present...
2015-04-29 17:00:09 LoadBlockIndexDB(): transaction index disabled
2015-04-29 17:00:09 LoadBlockIndexDB(): hashBestChain=000000000019d6689c085ae165831e934ff763ae46a2a6c172b3f1b60a8ce26f height=0 date=2009-01-03 18:15:05 progress=0.000000
2015-04-29 17:00:09 init message: Verifying blocks...
2015-04-29 17:00:09 Shutdown requested. Exiting.
2015-04-29 17:00:09 Shutdown: In progress...
2015-04-29 17:00:09 StopNode()
2015-04-29 17:00:09 Committing 0 changed transactions (out of 0) to coin database...
2015-04-29 17:00:09 Shutdown: done

@Diapolo
Copy link

Diapolo commented Apr 30, 2015

@laanwj AFAIK there was a patch which changed some locale stuff and was related to boost? Can you perhaps shed some light in here?

@dexX7
Copy link
Contributor

dexX7 commented Apr 30, 2015

c9e022b and df45564 set a locale explicitly for boost::path, where the "C" locale is used as default and as fallback, if no valid environment locale is detected in POSIX systems.

However, what strikes me is #6078 (comment), which hints a path/locale related issue, before those changes were adopted.

@jonasschnelli
Copy link
Contributor

I just invested some hours to track this down without success.
Tried to change https://github.com/bitcoin/bitcoin/blob/master/src/util.cpp#L672 from A(nsi) to W(widechar). Worked partial but produced issues wherever a boost path was converted to c_str() (Databases, etc.).

Also figured out that 0.10 was running fine in Russian but not in Tajiki (chosen by random).
0.10.1 Does not run on Russian Window; therefore i think is serious and should get fixed asap.

@theuni
Copy link
Member

theuni commented May 1, 2015

@jonasschnelli Indeed. Thanks for looking into this. I'll join you in the hunt.

@jonasschnelli
Copy link
Contributor

I have tested bitcoind and Bitcoin-Qt 0.9.2, 0.9.3 and 0.10.0 and 0.10.1 on Windows 7 with Russian, Chinese, Tajik and German.
If you use usernames (or lets say a --datadir path) with special characters from one of these languages you might run into this boost::filesystem chars issue.
#6093 fixes this only partial.

@jonasschnelli
Copy link
Contributor

@vayvanne: can you test #6093? If you can't build yourself you can try use a prebuilt binary: https://builds.jonasschnelli.ch/pulls/6093/

@laanwj
Copy link
Member

laanwj commented May 1, 2015

I think this warrants a 0.10.2 release for Windows. If we don't find a better fix, I'll just roll back the patch that caused this on the 0.10 branch. This will re-introduce a rare shutdown race condition (#3136), but is preferable to users not being able to use the software at all.

@dexX7
Copy link
Contributor

dexX7 commented May 1, 2015

I'm currently testing two alternatives: https://gist.github.com/dexX7/7394a947b29c7d84c710

To test it, I'm trying to use different paths with those builds, as well as 0.9.3, 0.10.1 on Windows 8.1 x64, and I should have a list of results in a few minutes.

The "classic" route has a similar faulty behavior as 0.10.1, but the "dummy" route works very well so far.

@vayvanne
Copy link
Author

vayvanne commented May 1, 2015

@jonasschnelli I have got running 0.10.0, the problem was probably wrong permissions to %appdata%\bitcoin. The build you proposed does run ok too on my setup.

@theuni
Copy link
Member

theuni commented May 1, 2015

As mentioned here: #6093 (comment)
I propose this fix: theuni@a082804

laanwj pushed a commit that referenced this issue May 11, 2015
@laanwj
Copy link
Member

laanwj commented May 14, 2015

@vayvanne Should be fixed in the 0.10.2 release candidate - you're very welcome to test. See https://bitcoin.org/bin/bitcoin-core-0.10.2/test for executables.

@vayvanne
Copy link
Author

Yep. 0.10.2rc1 running good on my setup although the non-English symbols in console are still not readable.

@laanwj
Copy link
Member

laanwj commented May 16, 2015

Thanks for testing.

The character handling in the logging output is an orthogonal issue, and the result of mixing different kinds of encodings. On Linux and MacOSX this issue doesn't exist as everything from front-end to back-end is UTF-8, but Windows is the odd duck out. Needs to be fixed some day but is much lower priority than 'not running at all'.

reddink pushed a commit to reddcoin-project/reddcoin-3.10 that referenced this issue May 27, 2020
@bitcoin bitcoin locked as resolved and limited conversation to collaborators Sep 8, 2021
owlhooter pushed a commit to owlhooter/mazacoin-new that referenced this issue Dec 10, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
6 participants