< gmaxwell>
morcos: actually the parallel signature checking gains are better than expected. So consider (all reindex chainstate, dbcache2000) no-scriptchecks par=4 10680.346728 seconds, all scriptchecks par=4 24453.715550 , all scriptchecks part=default (24 core, 48 thread host): 12182.296543 ... so if you compute (par4-none)/(parN-none) = 9.17 ... impressive trick considering MAX_SCRIPTCHECK_THREADS i
< gmaxwell>
s 16. ... my numbers may not be totally compariable because I had a rebase between the par4 and parN cases, that I didn't _think_ would impact performance.
< gmaxwell>
Good test hygine is hard when doing tests that take 7 hours.
< Chris_Stewart_5>
jonasschnelli: Do you have any numbers on how long it takes to sync headers with your pull req?
< warren>
jonasschnelli: hmm, I'm excited to use your SPV mode in conjunction with BIP150 (authenticated connection to my own full nodes)
< gmaxwell>
warren: just need 5 more regular contributors to get all the outstanding things done.
< morcos>
gmaxwell: i don't think thats a fair calculation though since during the none part the script checking threads are running
< morcos>
or at least N-1 of them
< gmaxwell>
morcos: I agree someone is wrong, but I don't follow your explination. None is effectively fScriptChecks = false. The threads may be running but they're not doing anything.
< gmaxwell>
all is fScriptChecks wedged true. (no checkpoints).
< morcos>
yes but during the all time so take the par=default case.. you have 15 script check threads running for 10k seconds and then 16 running for another 2k seconds, so its not fair to say it only took them 2k seconds
< gmaxwell>
duh right.
< gmaxwell>
okay, it's been a long day.
< morcos>
all this flurry of trying to fix concurrency problems showed up when it turned out that it could actually be faster to NOT have signatures cached because of the contention on the sigcache
< morcos>
thats certainly been fixed with the cuckoocache
< gmaxwell>
well for IBD it still might be. :P
< morcos>
but it is still the case that when sigs are cached, its harder to see the benefits of more parallelism, b/c then the contention on the checkqueue is greater
< gmaxwell>
I wish our design made it easier to get multiple blocks in the scriptchecking pipeline at once.
< morcos>
I suspect that improvement wouldn't be that much any more
< morcos>
with full blocks, there isn't much time where you have idle cores with nothing to do
< morcos>
it makes a much bigger difference with the old small blocks though
< morcos>
i do think if i had your computer i'd change MAX_SCRIPTCHECK_THREADS though!
< gmaxwell>
yes. well, also, I'm usually using 48 or 56 thread hosts.
< gmaxwell>
well it used to make it _slower_ I'm trying now with it at 48.
< gmaxwell>
it's at height 250k at hte moment and not making it much past 700% cpu according to top... but thats still early.
< morcos>
it's worse than video games. you're still going to be doing that at 3am
< morcos>
have a good night!
< gmaxwell>
hah
< gmaxwell>
"I thought mine-craft was a graphical program?"
< Chris_Stewart_5>
How is CScript serialized? It doesn't seem to use ADD_SERIALIZE_METHODS
< luke-jr>
Chris_Stewart_5: it's just a vector of uint8s
< Chris_Stewart_5>
luke-jr: Which is why we things like this? static_cast<const CScriptBase&>
< sipa>
yes CScript is just a subclass of std::vector<char>
< warren>
https://0bin.net/paste/iJSqUPkqv-zAG-ZN#vKw4haQ8j5fbQZK7NAkYO+nXugLmLPZP73uJghKj6nl This is an example of a double-spent transaction, previously confirmed in the local wallet but now invalid. I think years ago this output would continue to show the blockhash of the block that it was previously confirmed (but no longer the longest chain)? Any idea when this changed?
< sqltest>
hello. I'm having a problem getting bitcoind to run as a different user (other than logged in user) using init conf. It always fails because it tries to create a .bitcoin dir. If I create a /.bitcoin dir with ownership of user it works. But I don't want a root .bitcoin dir. The running user has no home dir. The bitcoin.conf is provided on cmd and datadir is in conf so works fine. No need to create an empty .bitcoin dir at a
< sqltest>
eg. "sudo -u btc bitcoind -conf=/etc/bitcoin/bitcoin.conf" works only if an extraneous .bitcoin dir exists even when not used
< gmaxwell>
you need to set the datadir path, not conf.
< gmaxwell>
you can just <sudo...> bitcoind -datadir=/etc/bitcoin/
< sqltest>
I do set that in the conf file and it works. But only when an empty .bitcoin is "hanging around". The .bitcoin remains empty even when daemon is full functionaing.
< sqltest>
I have other settings I need in the bitcoin.conf as well so provide that instead of datadir alone.
< sqltest>
It seems to test the exitence of .bitcoin even when using another datadir path.
< sqltest>
The issue is it is run as btc user by start-stop-daemon but that process chdirs to root first.
< sqltest>
So if I create an empty /.bitcoin dir it starts fine. But when that is not present it cannot start.
< jonasschnelli>
<*highlight><Chris_Stewart_5:#bitcoin-core-dev> jonasschnelli: Do you have any numbers on how long it takes to sync headers with your pull req?
< jonasschnelli>
2-3min
< sqltest>
If I tell start-stop-daemon to chdir to a writeable dir I thought it would create a .bitcoin dir there but for some reason it doesn't.
< jonasschnelli>
Headers-Sync does not run in parallel (from different peers)
< jonasschnelli>
So.. if you have download them from a slow peer, it may take longer.
< gmaxwell>
sqltest: don't use the config file to set it, thats too late.
< gmaxwell>
hm. well, that might be a bug then.
< jcorgan>
sqltest: i can confirm i've seen exactly the same behavior as you describe. i don't know if it is a feature or a bug, but nowadays i run bincoind inside a container so i map $HOME/.bitcoin inside the container to wherever i want outside the container
< gmaxwell>
though I don't think so.
< * gmaxwell>
straces.
< gmaxwell>
with datadir set on the commandline I don't see any access to $HOME/.bitcoin
< gmaxwell>
with master, I don't have a 0.13.2 binary handy to test at the moment.
< jcorgan>
i did trace through the code (though this was back in the 0.8 or 0.9 days, so it's probably all changed)
< jcorgan>
and it did seem that bitcoind was checking for $HOME/.bitcoin/bitcoin.conf before parsing the cmdline for -conf
< sqltest>
so I guess i need to set datadir and conf on command line unless I decide to move bitcoin.conf to datadir. I have a bunch of confs for daemons and wanted to keep them all in /etc/bitcoin
< jcorgan>
that's not an unreasonable way of doing things
< sqltest>
well, thanks. I guess I'll have to work around that. The docs seems to say you can set conf on cmdline but that's incorrect unless datadir also provided.
< gmaxwell>
sqltest: yes. you can't even put a datadir in the config of many of the altcoins.
< gmaxwell>
you can set a conf on the commandline. but what you're trying to do is override the conf and datadir at the same time and there is some interaction there it seems.
< sqltest>
Ok. I added datadir so both are provided to start-start-daemon exec args and it works ok like that. I'm creating an install script for my sqlchain daemon and this will work ok. Just need extra arg.
< sqltest>
Thanks for help.
< Chris_Stewart_5>
jonasschnelli: Wow, faster than I expected. Very nice.
< Chris_Stewart_5>
also, it isn't possible to run in parallel is it?
< gmaxwell>
not really without hacks.
< bitcoin-git>
[bitcoin] TheBlueMatt opened pull request #9486: Make peer=%d log prints consistent (master...2017-01-peer-log-consistency) https://github.com/bitcoin/bitcoin/pull/9486
< gmaxwell>
I'd really like us to stop using unbraced ifs. This is the kind of error that results from them, it was my screwup for sure, but getting things right is hard enough without a coding style that includes a predictable source of bugs.
< luke-jr>
gmaxwell: not sure if I mentioned, but I also came to that opinion following consideration of your arguments for it some months ago (always using braced blocks)
< luke-jr>
and as such have been using/adding them where appropriate
< gmaxwell>
luke-jr: yea, I see you've been using it.
< gmaxwell>
I've been inconsistent in my use in Bitcoin Core, I've slipped some in but worry about getting nagged about the coding style.
< phantomcircuit>
gmaxwell, unbraced if's are just wrong
< gmaxwell>
Unfortunately, I don't think any of the autoformaters or linter tools can enforce them. (they certantly can't enforce my preferred style: unbraced only if the whole statement is one line and there is no else.
< Chris_Stewart_5>
If I am trying to use the 'deserializing constructor' for CTransaction, what am I suppose to be passing in as 'deserialize_type'?
< kadoban>
max4307: Password to what? Alse this probably belongs in #bitcoin, at a guess.
< max4307>
the purse has created a password and forgot, you can't work Sneem
< max4307>
encrypted wallet and forgot my password now how to work the ck
< adam3us>
phantomcircuit unbraced if's are very wrong.
< adam3us>
very awesome security defects in other crypto applications have been created by them and poor formatting.
< sipa>
yeah, unfortunately, in some parts of the codebase they're still common
< sipa>
and people tend to (and have been advised to) mimick the style of the code surrounging what is being touched
< max4307>
encrypted wallet and forgot password bitcoincore?
< sipa>
max4307: this channel is not for support
< sipa>
max4307: perhaps try the forums or stackexchange, or #bitcoin (but beware of scammers)
< max4307>
And channel support don't know
< luke-jr>
BlueMatt: we are de facto including wallet/rpcwallet.h in the build already (and forever afaik) with --disable-wallet; how else would you suggest I do that?
< BlueMatt>
oh? where from?
< BlueMatt>
note: I'm ok with a little duplication of the headers with comments noting "this should go away - do not use in new code, yada yada"
< luke-jr>
Makefile.am
< BlueMatt>
you mean via BITCOIN_CORE_H?
< luke-jr>
yeah
< BlueMatt>
afaiu that just informs autotools that if this header changes it may need to recompile some files
< BlueMatt>
it doesnt actually compile/include/etc it in any way
< luke-jr>
it figures out dependencies automatically. although admittedly, I do not know what that reference actually does do
< luke-jr>
in any case, so basically you want me to duplicate the header in src/rpc/?
< BlueMatt>
that would be my preference
< gmaxwell>
phantomcircuit: hm. I thought we had written style mandates that prohibited braces on single line statements. But looking, I can't find that.
< gmaxwell>
phantomcircuit: so I've been thinking that I was being naughty every time I added one.