I wanted to try out P2Pool mining, so I installed the newest Bitcoin (0.5.2, also tried it with 0.5.1).

Unfortunately when I start run_p2pool.exe it immediately crashes my Bitcoin!

My OS: Win7 x64

Any ideas?

  • Please drop by #p2pool channel on freenode IRC and the friendly folks there will try to help you out. – nanotube Jan 19 '12 at 6:57
  • 1
    Could you post the specific error(s) you get? It's very difficult to troubleshoot via telepathy ;) – David Perry Jan 19 '12 at 7:51
  • Before my edit, I read the title as "Something that P2Pool did made the Bitcoin market crash" :) – ripper234 Jan 19 '12 at 8:28
  • It seems I had to wait for my Bitcoin to fully synchronize with the network. After that it didn't crash any more. IMHO bitcoin-qt.exe should not just crash in a case like this. – Frizz Jan 19 '12 at 9:06
  • Did you report this as a bug in the Bitcoin bug tracker? ( github.com/bitcoin/bitcoin/issues/new ). p2pool shouldn't be able to make bitcoind crash, whatever it tries to do. Rather than working around this by using a weird configuration we should attempt to fix the underlying problem. – Chris Moore Feb 13 '12 at 13:31

I wrote a solution to this problem two days ago:

How to use p2pool with an accompanying standalone bitcoind

(since the windows gui version of bitcoin 0.5.1 crashes frequently when used with p2pool)

Assumptions:

OS: Windows 7

Bitcoin: Latest stable release installed and working - http://sourceforge.net/projects/bitcoin/files/Bitcoin/bitcoin-0.5.1/bitcoin-0.5.1-win32-setup.exe/download

p2pool: you'll be slightly off the beaten path with this configuration as you're specifying the bitcoin address to send generated bitcoins and not using the second bitcoin processes wallet

  1. Download latest current p2pool code and extract to "%programfiles%\p2pool" - https://github.com/forrestv/p2pool/zipball/master

  2. Download and install latest Python 2.7 (if you get 64bit, you'll need 64bit versions of the packages below) - http://www.python.org/download/

  3. Download and install python extension package twisted - http://www.lfd.uci.edu/~gohlke/pythonlibs/#twisted

  4. Download and install python extension package zope.interface - http://www.lfd.uci.edu/~gohlke/pythonlibs/#zope.interface

  5. Download and install python extension package pil - http://www.lfd.uci.edu/~gohlke/pythonlibs/#pil

  6. Download and install python extension package pygame - http://www.lfd.uci.edu/~gohlke/pythonlibs/#pil

  7. Open your Bitcoin GUI client if it is not running and generate a new address, take note of the generated address and close your Bitcoin GUI client

  8. Edit your existing "%appdata%\bitcoin\bitcoin.conf" and unless you know what you're doing, change what ever is there to this and if the file does not exist - create it:

    logtimestamps=1
    
  9. Create the folder "%programfiles%\p2pool\bitcoind-data"

  10. Create "%programfiles%\p2pool\bitcoind-data\bitcoin.conf" with your favorite text editor and populate it with this:

    server=1
    logtimestamps=1
    port=18333
    rpcport=18332
    rpcuser=bitcoinusername
    rpcpassword=bitcoinpassword
    rpcallowip=*
    
  11. Take note of the folder name of the latest current p2pool code - it is in "%programfiles%\p2pool"

  12. Create "%programfiles%\p2pool\p2pool.cmd" with your favorite text editor and populate it with this:

    @echo off
    title p2pool
    echo.
    echo running p2pool ...
    echo.
    C:\Python27\python.exe "%programfiles%\p2pool\folder-name-of-the-latest-current-p2pool-code\run_p2pool.py" --net bitcoin --address yourbitcoinaddresshere --bitcoind-address 127.0.0.1 --bitcoind-rpc-port 18332 --bitcoind-p2p-port 18333 bitcoinusername bitcoinpassword
    echo.
    echo p2pool stopped.
    echo.
    pause
    
  13. eg.

    @echo off
    title p2pool
    echo.
    echo running p2pool ...
    echo.
    C:\Python27\python.exe "%programfiles%\p2pool\forrestv-p2pool-4f6c2e2\run_p2pool.py" --net bitcoin --address 12uN6G1uAtn7G29qfTdLD9des4y63Whr61 --bitcoind-address 127.0.0.1 --bitcoind-rpc-port 18332 --bitcoind-p2p-port 18333 bitcoinusername bitcoinpassword
    echo.
    echo p2pool stopped.
    echo.
    pause
    
  14. Create "%programfiles%\p2pool\bitcoind.cmd" with your favorite text editor and populate it with this:

    @echo off
    title bitcoind
    echo.
    if exist "%programfiles%\bitcoin\daemon\bitcoind.exe" (set programfilesx86=0)
    if exist "%programfiles(x86)%\bitcoin\daemon\bitcoind.exe" (set programfilesx86=1)
    if %programfilesx86%==0 (goto :programfiles)
    if %programfilesx86%==1 (goto :programfilesx86)
    echo ERROR! bitcoind.exe not found in either "%programfiles%\bitcoin\daemon\" or "%programfiles(x86)%\bitcoin\daemon\" - giving up!
    echo.
    pause
    goto:eof
    :programfiles
    echo running bitcoind.exe from "%programfiles%\Bitcoin\daemon\" ...
    "%programfiles%\Bitcoin\daemon\bitcoind.exe" -datadir="%programfiles%\p2pool\bitcoind-data"
    echo.
    echo bitcoind stopped.
    echo.
    pause
    goto:eof
    :programfilesx86
    echo running bitcoind.exe from "%programfiles(x86)%\Bitcoin\daemon\" ...
    "%programfiles(x86)%\Bitcoin\daemon\bitcoind.exe" -datadir="%programfiles%\p2pool\bitcoind-data"
    echo.
    echo bitcoind stopped.
    echo.
    pause
    
  15. List item

  16. Copy blk*.dat from %appdata%\bitcoin to %programfiles%\p2pool\bitcoind-data

    Run "%programfiles%\p2pool\bitcoind.cmd"
    Run "%programfiles%\p2pool\p2pool.cmd"
    

You should now be able to mine on your machine to 127.0.0.1:9332 or to your machines IP on port 9332 on your LAN :)

Your Answer

 
discard

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.