Giter Club home page Giter Club logo

statoshi's Introduction

Statoshi: Bitcoin Core + statistics logging

What is Statoshi?

Statoshi's objective is to protect Bitcoin by bringing transparency to the activity occurring on the node network. By making this data available, Bitcoin developers can learn more about node performance, gain operational insight about the network, and the community can be informed about attacks and aberrant behavior in a timely fashion.

There is a live Grafana dashboard at statoshi.info

License

Statoshi is released under the terms of the MIT license. See COPYING for more information or see http://opensource.org/licenses/MIT.

Development Process

Statoshi's changeset to Bitcoin Core is applied in the master branch and is built and tested after each merge from upstream or from a pull request. However, it not guaranteed to be completely stable. We do not recommend using Statoshi as a Bitcoin wallet.

A guide for Statoshi developers is available here

Other Notes

A system metrics daemon is available here

Statoshi also supports running multiple nodes that emit metrics to a single graphite instance. In order to facilitate this, you can add a line to bitcoin.conf that will partition each metric by the name of the host: statshostname=yourNodeName

statoshi's People

Contributors

achow101 avatar ajtowns avatar dongcarl avatar fanquake avatar furszy avatar gavinandresen avatar glozow avatar gmaxwell avatar hebasto avatar instagibbs avatar jamesob avatar jnewbery avatar jonasschnelli avatar jonatack avatar kallewoof avatar laanwj avatar luke-jr avatar meshcollider avatar morcos avatar non-github-bitcoin avatar practicalswift avatar promag avatar ryanofsky avatar sdaftuar avatar sipa avatar sjors avatar thebluematt avatar thestack avatar theuni avatar vasild avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

statoshi's Issues

Investigate adding new metrics

Add orphan block gauge in processblock function
track tx fees & tx size - check
gauge # inputs & outputs per tx - check

track tx types / OP_
track timestamp metrics for blocks
gauge block size in KB, # of tx in block

from peer version msg:
gauge block heights of peers
gauge version of peers
gauge nTimeOffset

document statoshi features & utilities

Need to add documentation for:

Node pool connection management daemon
DisconnectPeer RPC function
System metrics daemon
Grafana installation + elasticsearch support

Add sample bitcoin.conf to note disablewallet and blocknotify=bitcoin-cli gettxoutsetinfo to populate UTXO set metrics

More hash estimates

I love statoshi.info.

I'm viewing the mining page a lot to track the hashrate after the halving.

I'm wondering if it's possible to add more panels with estimations of the hashrate using more blocks in the calculation. Currently we can only see an estimation based on 120 blocks (20 hours). It would be nice to also be able to see for example 50 and 100 hours.

I would create a pull request for this myself but I'm too bad at cpp to be able to figure out how. I see that we need to change request in this line to not use the default 120 in getnetworkhashps but instead 300 and 600.

statsClient.gauge("network.exahashesPerSecond", getnetworkhashps(request).get_real() / 1e18);

BR,
Fridokus

Dockerize Statoshi

BOUNTY: Anyone who submits a working docker build for everything below will be paid $500 worth of BTC.

I want a docker container that installs:

  1. Statoshi fork of Bitcoin Core
  2. node.js
  3. forever
  4. statsd
  5. graphite
  6. carbon
  7. whisper
  8. apache / nginx
  9. memcached
  10. grafana 2.0
  11. The system metrics daemon

Installation & config instructions are at https://jlopp.github.io/statoshi/

Additionally, it would be preferable to compile, install, and run the Statoshi fork of Bitcoin Core before anything else, wait ~24 hours so that the blockchain finishes syncing, and then install and configure the rest of the software. Otherwise the initial syncing will be much slower and will store a bunch of useless metrics. As part of this, there is no need to configure the bitcoin.conf "blocknotify" hook until after the blockchain has finished syncing.

Basically, a docker image that creates a fully functional web site backed by a statoshi instance like you see on statoshi.info with just a click of a button to deploy it will satisfy the requirements for the posted bounty.

fix hashesPerSecond overflow

This stat is displaying as negative now, likely due to overflow. Should switch to exahashesPerSecond and divide the output by 10^18

build error - error: ‘relative’ is not a member of ‘fs’

on ubuntu 16.04 64-Bit

I did:

./autogen.sh && ./configure && make

But I gor error:

  CXX      wallet/libbitcoin_wallet_a-walletdb.o
  CXX      wallet/libbitcoin_wallet_a-walletutil.o
wallet/walletutil.cpp: In function ‘std::vector<boost::filesystem::path> ListWalletDir()’:
wallet/walletutil.cpp:60:32: error: ‘relative’ is not a member of ‘fs’
             paths.emplace_back(fs::relative(it->path(), wallet_dir));
                                ^
wallet/walletutil.cpp:71:36: error: ‘relative’ is not a member of ‘fs’
                 paths.emplace_back(fs::relative(it->path(), wallet_dir));
                                    ^
Makefile:6912: recipe for target 'wallet/libbitcoin_wallet_a-walletutil.o' failed
make[2]: *** [wallet/libbitcoin_wallet_a-walletutil.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: Leaving directory '/home/ak/git/SUGAR/TOOLS/statoshi/src'
Makefile:10250: recipe for target 'all-recursive' failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory '/home/ak/git/SUGAR/TOOLS/statoshi/src'
Makefile:774: recipe for target 'all-recursive' failed
make: *** [all-recursive] Error 1

Any idea?

Lightning network stats

Is your feature request related to a problem? Please describe.

Missing lightning network (layer 2) insides.

Describe the solution you'd like

Gathering lightning network stats and also leverage StatsD daemon to aggregate them towards a database/dashboard.

Describe alternatives you've considered

https://1ml.com/statistics (but meh, Grafana would be much cooler)

bitcoin-cli gettxoutsetinfo returns empty set

19:31 ~/bin/statoshi $ bitcoin-cli gettxoutsetinfo
{
}
19:40 ~/bin/statoshi $ 

Notice how it takes 9 minutes to process that request.
I got to this because the utxoset gauges were missing in my Grafana installation. Running the latest Statoshi version.

add addr type breakdown

Via next release:

$ bitcoin-cli -addrinfo
{
"addresses_known": {
"ipv4": 14406,
"ipv6": 2511,
"torv2": 5563,
"torv3": 2842,
"i2p": 8,
"total": 25330
}
}

Update Installation Guide for Grafana

Current install guide only goes as far as Graphite installation. Need to add the rest of the instructions for adding Grafana on top.

Also: instructions for running "forever" scripts to auto-restart crashed daemons.
Also: templates for default Grafana charts.

Error: Cannot read property 'length' of undefined

consolidate instances of statsd client

There are currently several separate instances of the client to prevent compiler linking errors; figure out how to reduce this to preferably a single instance.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.