This repository has been archived by the owner on Mar 16, 2024. It is now read-only.
forked from bitcoin-abe/bitcoin-abe
-
Notifications
You must be signed in to change notification settings - Fork 23
/
Copy pathREADME-MYSQL.txt
52 lines (35 loc) · 1.48 KB
/
README-MYSQL.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
Abe setup for MySQL.
Run the Bitcoin client to ensure that your copy of the block chain is
up to date.
Install Python 2.7 and pycrypto. The Debian/Ubuntu packages are
python2.7 and python-crypto.
Install MySQL 5.x server and MySQL-Python. On Debian/Ubuntu:
mysql-server-5.1 and python-mysqldb.
Configure the MySQL instance with InnoDB engine support. Often,
InnoDB is enabled by default. To check for InnoDB support, issue
"SHOW ENGINES" and look in the output for "InnoDB" with "YES" next to
it. If "skip-innodb" appears in the server configuration (my.cnf or
my.ini) then remove it and restart the server.
Log into MySQL as root (e.g.: mysql -u root) and issue the following,
replacing "PASSWORD" with a password you choose:
create database abe;
CREATE USER abe IDENTIFIED BY 'PASSWORD';
grant all on abe.* to abe;
Create file abe-my.conf with the following contents, replacing
"PASSWORD" as above:
dbtype MySQLdb
connect-args {"user":"abe","db":"abe","passwd":"PASSWORD"}
upgrade
port 2750
Perform the initial data load:
python -m Abe.abe --config abe-my.conf --commit-bytes 100000 --no-serve
Look for output such as:
block_tx 1 1
block_tx 2 2
...
This step may take several days depending on chain size and hardware.
Then run the web server as:
python -m Abe.abe --config abe-my.conf
You should see:
Listening on http://localhost:2750
Verify the installation by browsing the URL shown.