Installing bitcoin on Debian ‘squeeze’

Instead of being outdoors I geeked out indoors this weekend and amongst other things installed a Bitcoin daemon on a public facing server so I could have a play with the API/RPC features.

Below I document the steps I followed as it turned out to be slightly more taxing than the usual apt-get install bitcoind

Step 1) Get server

This is obviously optional depending on where it’s going but as I wanted it on a public facing machine and I’ve got a few projects where I need to using it soon I installed a new Debian image on the Rackspace cloud.

The newest version of Debian is ‘squeeze’ so I chose that and as for now this is for testing I chose the cheapest instance, 256MB RAM/10GB space for 24p a day (!) but can change this later if I need more grunt.

Step 2) apt-get install fail

It turns out that bitcoind isn’t in the standard package list for squeeze so you need to install it via back-ports. To do so add the following to your /etc/apt/sources.list

Save, then run:

Step 3 ) Install start-up & config scripts

Again, surprisingly for a debian package, there’s no start-up or config installed for you. So you’re going to have to do it yourself.

I took the

script found on this forum and edited it as per the thread recommendations with a few tiny mods of my own:

Note: items in the script above that may (or will definitely) need changing depending upon your environment are in bold.

Save it as /etc/init.d/bitcoind then run:

Now you need a config file, I got an example one here. Paste it into /home/[user script will run as]/.bitcoin/bitcoin.conf

4) Run

You can just run the init.d script now, but to be 100% sure that it’ll start on boot I simply rebooted.

On startup I could see a bitcoind process running and in my ~/.bitcoin/ folder I ran

I could see these two files slowly increasing in size, as the complete block chain was being synchronised:

You can get more info by running:

From this I could see that blocks was under the current count.

5 Comments Installing bitcoin on Debian ‘squeeze’

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">