Pages:
Author

Topic: [ANNOUNCE] Abe 0.7: Open Source Block Explorer Knockoff - page 7. (Read 220757 times)

legendary
Activity: 840
Merit: 1000
However, when I launch it for use with apache2/fastcgi I get into trouble with it... Or at least launching bitcoin-abe doesn't want to launch.

Have you checked out, if you have everything installed for Apache and Python regarding FastCGI?
http://www.electricmonk.nl/docs/apache_fastcgi_python/apache_fastcgi_python.html
https://docs.python.org/2/howto/webservers.html

Don't know, which distro you are using, but this could be helpful, too, for you to have a start:
https://packages.debian.org/squeeze/python-flup (here for Debian Squeeze, should install via apt-get or aptitude)
sr. member
Activity: 411
Merit: 250
Call me stupid, but I managed to get it up & running not so long ago and now I can't even remember if I did something special except RTFM to get it up & running.
Bitcoin-abe works perfectly with its built-in web server and the block chain got loaded:
Code:
akira@NGC4826:~/minerals-abe$ python -m Abe.abe --config abe.conf --host 192.168.241.128 --port 2750
RPC failed: [Errno socket error] [Errno 111] Connection refused
catch_up_rpc: abort
Opened /home/akira/.Minerals/blk0001.dat
Abe initialized.
Listening on http://192.168.241.128:2750
RPC failed: [Errno socket error] [Errno 111] Connection refused
catch_up_rpc: abort
Opened /home/akira/.Minerals/blk0001.dat
192.168.241.1 - - [02/Oct/2014 15:14:46] "GET / HTTP/1.1" 200 1545
192.168.241.1 - - [02/Oct/2014 15:14:47] "GET /abe.css HTTP/1.1" 200 1064
192.168.241.1 - - [02/Oct/2014 15:14:47] "GET /logo32.png HTTP/1.1" 200 568

However, when I launch it for use with apache2/fastcgi I get into trouble with it... Or at least launching bitcoin-abe doesn't want to launch.
Code:
akira@NGC4826:~/minerals-abe$ python -m Abe.abe --config abe.conf
RPC failed: [Errno socket error] [Errno 111] Connection refused
catch_up_rpc: abort
Opened /home/akira/.Minerals/blk0001.dat
Abe initialized.
WSGIServer: missing FastCGI param REQUEST_METHOD required by WSGI!
WSGIServer: missing FastCGI param SERVER_NAME required by WSGI!
WSGIServer: missing FastCGI param SERVER_PORT required by WSGI!
WSGIServer: missing FastCGI param SERVER_PROTOCOL required by WSGI!
fixed path_info
Status: 301 Moved Permanently
Location: http://localhost/
Content-Type: text/html

Moved

Moved

This page has moved to http://localhost/
akira@NGC4826:~/minerals-abe$


What kind of directory or file or symlink could be 'permantently moved'?
I don't remember what I did to get it up & running at two weeks ago. Unfortunately, while reverting to another snapshot of my Virtualbox VM, that software killed the whole tree and there's no way to recover the working bitcoin-abe snapshot I saved back then Sad
Currently using other virtualization software, but yeah... I must be doing something wrong this time :s

PS: the wallet daemon is not running atm, but that shouldn't be a problem?

The Virtual Host is configured like this:
Code:

        ServerName nightminerals.com
        #ServerAdmin webmaster@localhost
        #ServerAlias www.nightminerals.com
        #DocumentRoot /var/www/nightminerals.com/public_html
        Alias /static/ /home/akira/minerals-abe/Abe/htdocs/
        Alias /robots.txt /home/akira/minerals-abe/Abe/htdocs/robots.txt
        Alias /favicon.ico /home/akira/minerals-abe/Abe/htdocs/favicon.ico
        Alias / /usr/lib/cgi-bin/abe.fcgi/
        ErrorLog ${APACHE_LOG_DIR}/abe-error.log
        CustomLog ${APACHE_LOG_DIR}/abe-access.log combined
        #FcgidIOTimeout 40

And abe.conf like this:
Code:
datadir += [{
 "dirname":"/home/akira/.Minerals",
 "chain":"Minerals"
}]

dbtype MySQLdb
connect-args {"user":"***","db":"abe","passwd":"***"}

Basically, according to the instructions for fastcgi/mysql.
sr. member
Activity: 411
Merit: 250
To add to the discussion:

If the explorer is not used for a few hours/days and then has to fetch all the latest block-data from the blockchain to store it into the database with the fcgi-call by the visitor, you'll most probably get an timeout-error. I'd recommend the following, to keep the database up-to-date automatically in the background through a cronjob:

In /etc/crontab add:

*/2 * * * * USER cd /home/USER/bitcoin-abe; python -m Abe.abe --config abe.conf --no-serve >/dev/null 2>&1

Replace USER with the actual username, which runs Abe on your machine.

Maybe this helps some people on a slower machine. It makes Abe check the blockchain every 2 minutes by the cronjob and add new transactions to the database, even if no website-visitor runs an Abe-call by opening the page. So normally by this the database should be mostly current and only the latest few transactions are added by the call of the real user on the website, hence he does not get an error-message. Just make sure, that the paths and names of the files in the above command are set correctly, according to your installation.

Edit:
Regarding the 1000 rows-limit, just remove the outcommenting hash mark in the config-file and set to -1 to check, whether your system can cope with unlimited tx-numbers for an address: https://github.com/bitcoin-abe/bitcoin-abe/blob/54ee67eafff81ec9cd1f5ef5cebea3514c267ae5/abe.conf#L267
Thank you for your tips.

I've forgot to chekc this thread lately as I've been trying to get Insight up & running with X11 POW/POS coins, but this requires more changes to the different components than I can handle within my limited time. For now, I'll be putting my attention back to ABE Smiley
legendary
Activity: 840
Merit: 1000
Hi my abe work:
http://explorer.zaplnc.pl/

Abe work in fast cgi mode and adresses is unhashed

My server:
http://www.kimsufi.com/
KS-1

I have on this serwer:
pool.zaplnc.pl
explorer.zaplnc.pl
beta.zaplnc.pl - demo MPOS
Thank you for your reaction. I think something more performing is needed for a block explorer. I get and error when trying to query http://explorer.zaplnc.pl/address/A1PxdQEhJTAy5tVit6kKrPWv3Ggn8qABcm for example.

My VM does it correctly, but slowly, once blocks are synched as they trickle in by the wallet daemon and there are not too many transactions for the address. Some with over 20000 transactions ran for more than an hour with the 1000 rows limit removed and FcgidIOTimeout at 900 seconds iso 40 seconds in the apache vhost's config file.

To add to the discussion:

If the explorer is not used for a few hours/days and then has to fetch all the latest block-data from the blockchain to store it into the database with the fcgi-call by the visitor, you'll most probably get an timeout-error. I'd recommend the following, to keep the database up-to-date automatically in the background through a cronjob:

In /etc/crontab add:

*/2 * * * * USER cd /home/USER/bitcoin-abe; python -m Abe.abe --config abe.conf --no-serve >/dev/null 2>&1

Replace USER with the actual username, which runs Abe on your machine.

Maybe this helps some people on a slower machine. It makes Abe check the blockchain every 2 minutes by the cronjob and add new transactions to the database, even if no website-visitor runs an Abe-call by opening the page. So normally by this the database should be mostly current and only the latest few transactions are added by the call of the real user on the website, hence he does not get an error-message. Just make sure, that the paths and names of the files in the above command are set correctly, according to your installation.

Edit:
Regarding the 1000 rows-limit, just remove the outcommenting hash mark in the config-file and set to -1 to check, whether your system can cope with unlimited tx-numbers for an address: https://github.com/bitcoin-abe/bitcoin-abe/blob/54ee67eafff81ec9cd1f5ef5cebea3514c267ae5/abe.conf#L267
sr. member
Activity: 411
Merit: 250
Abe will run ok on Digital Ocean's 1GB RAM VPS ($10/month). It is possible to get it to work ok also on 512MB RAM if you set up swap memory, pick the right distro and disable some unnecessary things to conserve memory use. Don't worry about CPU usage because even if Abe is written in Python which is a shit slow performing language that is not where problem or bottleneck with Abe is, it will run good on some old Pentium 3 Tongue If you want smaller footprint blockexplorer (but with some limited feature) check out RPC Ace https://bitcointalksearch.org/topic/announce-rpc-ace-a-simple-cut-down-block-explorer-alternative-686177
I managed to load the whole blockchain, but made a mistake with the hex value for processing addresses... So they all look weird.
Currently I'm also experimenting with Bitcore's Insight. I noticed it loads it DB extremely fast compared to ABE, but also ran into some little bumps along the road, but will hopefully flatten them soon Smiley
sr. member
Activity: 374
Merit: 250
Hi,
 i had problem with the last bitcoin-abe release v0.7.2 and last bitcoin client.
The problem was with blkXXXX.dat files:
blk0001.dat (old btc client) VS blk00000.dat (new btc client)

my fix in 3 steps :-)  :
edit file DataStore.py

1. line nr 651

            store.datadirs.append({
                "id": store.new_id("datadir"),
                "dirname": dirname,
                "blkfile_number": 1,
                "blkfile_offset": 0,
                "chain_id": chain_id,
                })


to


            store.datadirs.append({
                "id": store.new_id("datadir"),
                "dirname": dirname,
                "blkfile_number": 0,
                "blkfile_offset": 0,
                "chain_id": chain_id,
                })


2. line nr 918

"""CREATE TABLE datadir (
    datadir_id  NUMERIC(10) NOT NULL PRIMARY KEY,
    dirname     VARCHAR(2000) NOT NULL,
    blkfile_number NUMERIC(4) NULL,
    blkfile_offset NUMERIC(20) NULL,
    chain_id    NUMERIC(10) NULL
)""",


to


"""CREATE TABLE datadir (
    datadir_id  NUMERIC(10) NOT NULL PRIMARY KEY,
    dirname     VARCHAR(2000) NOT NULL,
    blkfile_number NUMERIC(5) NULL,
    blkfile_offset NUMERIC(20) NULL,
    chain_id    NUMERIC(10) NULL
)""",


3. line nr 2597

    def blkfile_name(store, dircfg):
        return os.path.join(dircfg['dirname'], "blk%04d.dat"
                            % (dircfg['blkfile_number'],))


to


    def blkfile_name(store, dircfg):
        return os.path.join(dircfg['dirname'], "blk%05d.dat"
                            % (dircfg['blkfile_number'],))


 Wink
full member
Activity: 203
Merit: 100
sr. member
Activity: 411
Merit: 250
Hi my abe work:
http://explorer.zaplnc.pl/

Abe work in fast cgi mode and adresses is unhashed

My server:
http://www.kimsufi.com/
KS-1

I have on this serwer:
pool.zaplnc.pl
explorer.zaplnc.pl
beta.zaplnc.pl - demo MPOS
Thank you for your reaction. I think something more performing is needed for a block explorer. I get and error when trying to query http://explorer.zaplnc.pl/address/A1PxdQEhJTAy5tVit6kKrPWv3Ggn8qABcm for example.

My VM does it correctly, but slowly, once blocks are synched as they trickle in by the wallet daemon and there are not too many transactions for the address. Some with over 20000 transactions ran for more than an hour with the 1000 rows limit removed and FcgidIOTimeout at 900 seconds iso 40 seconds in the apache vhost's config file.
member
Activity: 69
Merit: 10
Hi my abe work:
http://explorer.zaplnc.pl/

Abe work in fast cgi mode and adresses is unhashed

My server:
http://www.kimsufi.com/
KS-1

I have on this serwer:
pool.zaplnc.pl
explorer.zaplnc.pl
beta.zaplnc.pl - demo MPOS
sr. member
Activity: 411
Merit: 250
Good evening

I've prepared a VM with Ubuntu Server 14.04/1GB RAM/8GB VDI and had some fun setting it up to host ABE. It's very slow, but I that's due to the hardware it runs on (old 6 year old laptop with a 1.6ghz athlon neox2 and 4GB ram. Anyway, since my tests are successful, I was thinking to host it somewhere, but I have no clue about the hardware requirements needed. When I look at VPS solutions like Digital Ocean's 5$ and 10$ packages, they look similar to my VM, memory-wise, but I don't know about the other virtualized hardware.

I'd like to avoid getting Error 500's or time-outs as the daemon will be running in the background to keep it updating at any time.
On my VM, the wallet daemon takes up to 15% of the cpu load, python around 35% and postgresql is sometime at 80% while loading blocks in the database (in huge chunks) during the initial loading.

When no blocks are added as the come, it's around 10% for postgresql and python, daemon runs at <2% load.
If I query the block explorer for an address, it pyhon gets spikes as high as 45%, postgresql 50% and apache2 45%...

So, I'm wondering what the minimum hardware requirements (or VPS equivalent) are to host this kind of service.
Also, is there a way to filter out the staking transactions?

I also think there's a problem. When looking at transaction details, it show always the same kind of addresses for any sender and receiver, for any transaction... for the first one to the last one in the whole blockchain. But I can query a specific transaction and it shows all the transactions that I see in my wallet as well. Did I miss something during the setup. Is there an (d)e(n)coding error? The address receiving those 5000 coins should be the one in my sig. M.....eXe iso 6KZ...PW9


Thanks for insights Smiley
newbie
Activity: 33
Merit: 0
nevermind.....figured it out on my own

for any others with this issue -- this specific error appears to be directly related to a malformed magic number (in mine, i left out an 'x' from one of the hex bytes)




Quote from: abn123
I give up....I have searched Google and this forum at length.  Attempted to implement the changes I found for items that were kinda close to my issue, but I cannot find this specific error anywhere else.

Trying to populate the db for the first time with my alt....  I just can't seem to figure out what it is trying to store, and how to make it smaller
Much thanks in advance....

Keep getting this error:


[INDENT][INDENT]Traceback (most recent call last):
  File "/usr/lib/python2.7/runpy.py", line 162, in _run_module_as_main
    "__main__", fname, loader, pkg_name)
  File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
    exec code in run_globals
  File "/home/david/Projects/bitcoin-abe/Abe/abe.py", line 2206, in
    sys.exit(main(sys.argv[1:]))
  File "/home/david/Projects/bitcoin-abe/Abe/abe.py", line 2200, in main
    store = make_store(args)
  File "/home/david/Projects/bitcoin-abe/Abe/abe.py", line 119, in make_store
    store = DataStore.new(args)
  File "Abe/DataStore.py", line 2872, in new
    return DataStore(args)
  File "Abe/DataStore.py", line 148, in __init__
    store.initialize()
  File "Abe/DataStore.py", line 1139, in initialize
    conf["magic_name"]))
  File "Abe/DataStore.py", line 450, in sql
    store.cursor.execute(cached, params)
psycopg2.DataError: value too long for type character(Cool


[/INDENT][/INDENT]
Posted from Bitcointa.lk - #GPMw8JdVXjFIcJs4
newbie
Activity: 33
Merit: 0
I give up....I have searched Google and this forum at length.  Attempted to implement the changes I found for items that were kinda close to my issue, but I cannot find this specific error anywhere else.

Trying to populate the db for the first time with my alt....  I just can't seem to figure out what it is trying to store, and how to make it smaller
Much thanks in advance....

Keep getting this error:


[INDENT][INDENT]Traceback (most recent call last):
  File "/usr/lib/python2.7/runpy.py", line 162, in _run_module_as_main
    "__main__", fname, loader, pkg_name)
  File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
    exec code in run_globals
  File "/home/david/Projects/bitcoin-abe/Abe/abe.py", line 2206, in
    sys.exit(main(sys.argv[1:]))
  File "/home/david/Projects/bitcoin-abe/Abe/abe.py", line 2200, in main
    store = make_store(args)
  File "/home/david/Projects/bitcoin-abe/Abe/abe.py", line 119, in make_store
    store = DataStore.new(args)
  File "Abe/DataStore.py", line 2872, in new
    return DataStore(args)
  File "Abe/DataStore.py", line 148, in __init__
    store.initialize()
  File "Abe/DataStore.py", line 1139, in initialize
    conf["magic_name"]))
  File "Abe/DataStore.py", line 450, in sql
    store.cursor.execute(cached, params)
psycopg2.DataError: value too long for type character(Cool


[/INDENT][/INDENT]
Posted from Bitcointa.lk - #dDu0XS4nINCsuzHl
hero member
Activity: 535
Merit: 500
member
Activity: 69
Merit: 10
explorer.zaplnc.pl

What wrong and what now ?
legendary
Activity: 1792
Merit: 1008
/dev/null
Who can help me with the Abe Blockchain Explorer.

I want to install it for an scrypt coin. PLS send me a PM if you can help. THX

If I want to set up an Abe installation, which version should I use then? The last release v0.7.2 from 7 Dec 2012, or the current master branch from GitHub?

I tried the current master branch from GitHub without success.
README-* contains informations on how to setup abe.

i'd be using master since it contains fixes. as you saw there wasnt a version/rc since a long time.
hero member
Activity: 535
Merit: 500
Who can help me with the Abe Blockchain Explorer.

I want to install it for an scrypt coin. PLS send me a PM if you can help. THX

If I want to set up an Abe installation, which version should I use then? The last release v0.7.2 from 7 Dec 2012, or the current master branch from GitHub?

I tried the current master branch from GitHub without success.
member
Activity: 69
Merit: 10
Who can install bitcoin-abe and fastcgi?
I must have it and I'll pay for the configuration!
full member
Activity: 203
Merit: 100
Can someone tell me what to edit to make Abe show extremely low difficulty?  

The coin is PoS only at this point and difficulty is often below 0.001 and shows as 0.0 which is not useful information.



Silent for days..... maybe you can give RPC Ace a try, it shows difficulty at 4 decimal points and can be change easily for more/less Wink
full member
Activity: 140
Merit: 100
Can someone tell me what to edit to make Abe show extremely low difficulty? 

The coin is PoS only at this point and difficulty is often below 0.001 and shows as 0.0 which is not useful information.

sr. member
Activity: 264
Merit: 250
... and rebuilds the entire list from block 1 each time you run it (very slow)

Plus, MMXIV is a PPCoin clone, which does not support getrawtransaction (it appears this is required for tally.php to work).

I actually just fixed the "from block 1 each time" part :) https://bitcointalksearch.org/topic/m.8270786

But unfortunately the getrawtransaction method missing in MMXIV cannot be helped. That's how RPC Ace and tally.php works and always will work. It's a very strange choice they made when removing it, since getrawtransaction (and other RPC calls) are so fundamental for many block chain and wallet tools.
Pages:
Jump to: