Author

Topic: PushPoolD (Read 3647 times)

legendary
Activity: 1596
Merit: 1012
Democracy is vulnerable to a 51% attack.
August 13, 2011, 04:28:38 AM
#15
You have pushpoold connecting to the client on its network port. You need to connect on its RPC port (8332 by default, but which I think you changed to 8338). Also, change your RPC password in both bitcoin and pushpool, 'test123' is not secure.
newbie
Activity: 56
Merit: 0
August 13, 2011, 04:18:28 AM
#14
Maybe they're dead  Embarrassed
member
Activity: 67
Merit: 10
August 12, 2011, 11:26:57 PM
#13


No takers?
member
Activity: 67
Merit: 10
August 05, 2011, 07:02:16 PM
#12
bump! anyone?
member
Activity: 67
Merit: 10
August 04, 2011, 05:29:20 AM
#11


Hey what did you do to end up fixing the issue above with it looping? My miner gets same messages, let me know if you did anything special.

Cheers
newbie
Activity: 10
Merit: 0
July 13, 2011, 08:27:57 PM
#10
Thanks,

Now there is one more thing..

Quote
...@...:~/pushpool$ pushpoold --config=./config.json --debug=2 --stderr --foreground
[2011-07-14 01:25:8.018911] Debug output enabled
[2011-07-14 01:25:8.050485] Listening on host :: port 8342
[2011-07-14 01:25:8.050614] Listening on host :: port 8341
[2011-07-14 01:25:8.050678] Listening on host :: port 8344
[2011-07-14 01:25:8.050740] Listening on host 127.0.0.1 port 8338
[2011-07-14 01:25:8.082694] initialized

Connecting my miner.

Quote
JSON protocol request:
{"method": "getwork", "params": [], "id":1}

* About to connect() to 127.0.0.1 port 8333 (#0)
*   Trying 127.0.0.1... * TCP_NODELAY set
* connected
* Connected to 127.0.0.1 (127.0.0.1) port 8333 (#0)
* Server auth using Basic with user 'username'
> POST / HTTP/1.1
Authorization: Basic enRqdWg6dGVzdDEyMw==
Host: 127.0.0.1:8333
Accept: */*
Accept-Encoding: deflate, gzip
Content-type: application/json
Content-Length: 45

* Empty reply from server
* Connection #0 to host 127.0.0.1 left intact
[2011-07-14 01:27:16.074094] HTTP request failed: Empty reply from server
JSON protocol request:
{"method": "getwork", "params": [], "id":2}

* Connection #0 seems to be dead!
* Closing connection #0
* About to connect() to 127.0.0.1 port 8333 (#0)
*   Trying 127.0.0.1... * TCP_NODELAY set
* connected
* Connected to 127.0.0.1 (127.0.0.1) port 8333 (#0)
* Server auth using Basic with user 'username'
> POST / HTTP/1.1
Authorization: Basic enRqdWg6dGVzdDEyMw==
Host: 127.0.0.1:8333
Accept: */*
Accept-Encoding: deflate, gzip
Content-type: application/json
Content-Length: 45



This keeps looping since my miner would like some work, but it doesn't send any work?  Huh
member
Activity: 84
Merit: 10
July 12, 2011, 01:48:43 PM
#9
Your problem is Port 8332...

If you notice, in your first running of pushpoold it complains when it hits this:
username@server:~/pushpool$ pushpoold --config=./config.json --debug=2 --stderr --foreground
[2011-07-12 01:05:30.548587] Debug output enabled
[2011-07-12 01:05:30.560904] Listening on host :: port 8342
[2011-07-12 01:05:30.561040] Listening on host :: port 8341
[2011-07-12 01:05:30.561110] tcp bind: Address already in use

When compared to the output that is working:
username@server:~/pushpool$ pushpoold --config=./config.json --debug=2 --stderr --foreground
[2011-07-12 02:13:45.245495] Debug output enabled
[2011-07-12 02:13:45.268446] Listening on host :: port 8342
[2011-07-12 02:13:45.268628] Listening on host :: port 8341
[2011-07-12 02:13:45.268702] Listening on host :: port 8332
[2011-07-12 02:13:45.268767] Listening on host 127.0.0.1 port 8338
[2011-07-12 02:13:45.359415] initialized

You can see the difference is "port 8332".

By default Bitcoind listens on port 8332, but bound to the localhost address (127.0.0.1).  That shouldn't conflict with pushpoold unless you changed this line in your server.json file:

Code:
      # requests to us | "proxy" should be set to your ip address that people will connect through
      { "port" : 8344, "protocol" : "http-json",
        "proxy" : "" },

My guess is you changed the pushpoold listen port to 8332, which conflicts with the port bitcoind is running on.


newbie
Activity: 1
Merit: 0
July 12, 2011, 01:08:47 PM
#8
Hello,

I get the excact same problem as ZtjuH does.
Is it me or are we doing something wrong?
newbie
Activity: 10
Merit: 0
July 11, 2011, 09:25:01 PM
#7
I've started bitcoind on port 8331 now (is this right, or doesn't it really mather? When I connect my miner to pushpoold now I get the following.

Quote
username@server:~/pushpool$ pushpoold --config=./config.json --debug=2 --stderr --foreground
[2011-07-12 02:13:45.245495] Debug output enabled
[2011-07-12 02:13:45.268446] Listening on host :: port 8342
[2011-07-12 02:13:45.268628] Listening on host :: port 8341
[2011-07-12 02:13:45.268702] Listening on host :: port 8332
[2011-07-12 02:13:45.268767] Listening on host 127.0.0.1 port 8338
[2011-07-12 02:13:45.359415] initialized
JSON protocol request:
{"method": "getwork", "params": [], "id":1}

* About to connect() to 127.0.0.1 port 8333 (#0)
*   Trying 127.0.0.1... * TCP_NODELAY set
* connected
* Connected to 127.0.0.1 (127.0.0.1) port 8333 (#0)
* Server auth using Basic with user 'username'
> POST / HTTP/1.1
Authorization: Basic enRqdWg6dGVzdDEyMw==
Host: 127.0.0.1:8333
Accept: */*
Accept-Encoding: deflate, gzip
Content-type: application/json
Content-Length: 45

* Empty reply from server
* Connection #0 to host 127.0.0.1 left intact
[2011-07-12 02:15:12.019588] HTTP request failed: Empty reply from server
newbie
Activity: 10
Merit: 0
July 11, 2011, 08:15:18 PM
#6
Well it's port 8332. I've checked that I've started bitcoind only once (http://gyazo.com/f2f656ef6fdc62c5319fc0fa0ad86d80.png). Then started pushpoold again, still same output.

Quote
username@server:~/pushpool$ pushpoold --config=./config.json --debug=2 --stderr --foreground
[2011-07-12 01:05:30.548587] Debug output enabled
[2011-07-12 01:05:30.560904] Listening on host :: port 8342
[2011-07-12 01:05:30.561040] Listening on host :: port 8341
[2011-07-12 01:05:30.561110] tcp bind: Address already in use

netstat -p -l gives me te following output:

Quote
tcp        0      0 localhost:8332          *:*                     LISTEN      7137/bitcoind
tcp        0      0 *:8333                  *:*                     LISTEN      7137/bitcoind

Hope this information helps..
member
Activity: 84
Merit: 10
July 11, 2011, 06:56:37 PM
#5
[2011-07-11 23:12:19.922736] tcp bind: Address already in use

The tcp bind error only shows up when bitcoind is started. Any pro-tips? Cheesy

That means you're either running two pushpoold's (check your process stack), or you're running something else on one of the ports that pushpoold wants to bind to...

First step is to figure out what port is colliding.
newbie
Activity: 10
Merit: 0
July 11, 2011, 06:18:21 PM
#4
Thanks for helping me guys Smiley

Okay, I've disabled memcache in the config. Started bitcoind with the following command:

Quote
username@server:~/bitcoin-0.3.24/bin/32$ ./bitcoind -gen=0 -server

Quote
usnermane@server:~/pushpool$ pushpoold --config=./config.json --debug=2 --stderr --foreground
[2011-07-11 23:12:19.905618] Debug output enabled
[2011-07-11 23:12:19.922538] Listening on host :: port 8342
[2011-07-11 23:12:19.922668] Listening on host :: port 8341
[2011-07-11 23:12:19.922736] tcp bind: Address already in use

The tcp bind error only shows up when bitcoind is started. Any pro-tips? Cheesy
newbie
Activity: 10
Merit: 0
July 11, 2011, 05:34:22 PM
#3
For easier troubleshooting, disable memcache (in the pushpool config).  It is not essential to the functioning of pushpool.
hero member
Activity: 630
Merit: 500
July 11, 2011, 05:29:33 PM
#2
Yes bitcoind needs to be running configured with the rpc settings you have entered in pushpoold.
newbie
Activity: 10
Merit: 0
July 11, 2011, 05:10:43 PM
#1
Hi,

I've just followed this tutorial: http://forum.bitcoin.org/index.php?topic=10321.0

But when I start pushpoold I get this:

Quote
username@server:~/pushpool$ pushpoold --config=./config.json --debug=2 --stderr --foreground
[2011-07-11 21:34:41.395048] Debug output enabled
[2011-07-11 21:34:41.413287] Listening on host :: port 8342
[2011-07-11 21:34:41.413414] Listening on host :: port 8341
[2011-07-11 21:34:41.413743] Listening on host :: port 8332
[2011-07-11 21:34:41.413832] Listening on host 127.0.0.1 port 8338
[2011-07-11 21:34:41.470741] initialized
[2011-07-11 21:35:36.569301] memcached store(/pushpoold/cred_cache/username) failed: WRITE FAILURE
[2011-07-11 21:35:36.591146] memcached store(/pushpoold/cred_cache/username) failed: WRITE FAILURE
JSON protocol request:
{"method": "getwork", "params": [], "id":1}

* About to connect() to 127.0.0.1 port 8333 (#0)
*   Trying 127.0.0.1... * TCP_NODELAY set
* Connection refused
* couldn't connect to host
* Closing connection #0
[2011-07-11 21:35:36.606349] HTTP request failed: couldn't connect to host

I've searched the forums, but couldn't find a appropriated answer Sad There must be something wrong Tongue Something I forgot, or something that's not described in the topic I mentioned above. Also, does bitcoin(d) have to be running, and if so, how should it be configured, because that's all not explained in the topic.

Anyway, this is my config.json:

Quote
{
        # network ports
        "listen" : [
                # binary protocol (default), port 8342
                { "port" : 8342 },

                # HTTP JSON-RPC protocol, port 8341
                { "port" : 8341, "protocol" : "http-json" },

                # HTTP JSON-RPC protocol, port 8344,
                # with trusted proxy appserver.example.com forwarding
                # requests to us
                { "port" : 8332, "protocol" : "http-json",
                  "proxy" : "127.0.0.1" },

                # binary protocol, localhost-only port 8338
                { "host" : "127.0.0.1", "port" : 8338, "protocol" : "binary" }
        ],

        # database settings
        "database" : {
                "engine" : "mysql",
                "host" : "localhost",
                "port" : 3306,
                "name" : "******************",
                "username" : "***************",
                "password" : "***************",
                "sharelog" : true,
                "stmt.pwdb":"SELECT `password` FROM `pool_worker` WHERE `username` = ?",
                "stmt.sharelog":"INSERT INTO shares (rem_host, username, our_result, upstream_result, reason, solution) VALUES (?, ?, ?, ?, ?, ?)"

        },

        # cache settings
        "memcached" : {
                "servers" : [
                        { "host" : "127.0.0.1", "port" : 11211 }
                ]
        },

        "pid" : "/tmp/pushpoold.pid",

        # overrides local hostname detection
        #"forcehost" : "localhost.localdomain",

        "log.requests" : "/tmp/request.log",
        "log.shares" : "/tmp/shares.log",

        # the server assumes longpolling (w/ SIGUSR1 called for each blk)
        "longpoll.disable" : false,

        # length of time to cache username/password credentials, in seconds
        "auth.cred_cache.expire" : 75,

        # RPC settings | Notice how this ISN'T port number 8332 this is becuase the same port number should not becuase inconjunction with the JSON RPC port other wise you'll get 500 errors
        "rpc.url" : "http://127.0.0.1:8333/",
        "rpc.user" : "username",
        "rpc.pass" : "test123",

        # rewrite returned 'target' to difficulty-1?
        "rpc.target.rewrite" : true
}

Thanks alot for the help Smiley

-Alex
Jump to: