Take the 2-minute tour ×
Bitcoin Stack Exchange is a question and answer site for Bitcoin crypto-currency enthusiasts. It's 100% free, no registration required.

I'm trying to communicate with the new Bitcoin-Qt -server via a command line on Mac. I run ./Bitcoin-Qt -server, the application starts, but my terminal window is stuck on an empty line (no matter what I type in, there is no response). Only when I quit Bitcoin am I able to run any commands, but then I can't communicate with Bitcoin, because it is already off.

How do I start Bitcoin-Qt -server on Mac and control it through command line?

share|improve this question
add comment

3 Answers

up vote 12 down vote accepted

You can start it from the command-line using:

open Bitcoin-Qt.app --args -server

I think the --args option to open is OSX 10.6 and later; if you are running an older OSX put server=1 in your ~/Library/Application Support/Bitcoin/bitcoin.conf file. In fact, to use the -server command you must set a -rpcuser/-rpcpassword, so I'd suggest creating a bitcoin.conf that contains:

server=1
rpcuser=yourname
rpcpassword=...something else

We don't ship a bitcoind for the Mac, but you can use curl (for example) to send commands to the running Bitcoin-Qt:

curl --user yourname --data-binary '{"id":"t0", "method": "getinfo", "params": [] }' http://127.0.0.1:8332/

The bitcoin source tree also contains python code that uses the free 'jsonrpc' library to communicate with a running Bitcoin-Qt (see contrib/bitrpc/).

share|improve this answer
    
Can you set the datadir also as shown here? sourceforge.net/projects/bitcoin/files/Bitcoin/testnet-in-a-box The example there shows it calling 'bitcoin'. Still a little unclear on how to get testnet-in-a-box up and running on mac. Thanks! –  Brian Armstrong Feb 16 '12 at 6:47
add comment

bitcoind 0.5.x, starting with 0.5.6rc3 and 0.6.x starting with 0.6.3 include a deterministic Mac build. Unfortunately, bitcoind 0.7 does not build with the Mac OS X 10.5 toolchain (which is what I compiled for gitian), so until I manage to make a LLVM-based cross-compiler you'll have to stick to the new Debug window interface and JSON-RPC.

share|improve this answer
add comment

You can't. This is a known bug in bitcoin.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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