FreshPorts -- net-p2pbitcoin Bitcoin freebsd freshports

Содержание статьи

FreeBSD, integrity

- May 30, 2011

After all this bitcoin hype lately and the fact that most clients are made for Linux, no wonder that i have seen several requests on how to run a bitcoin generator under FreeBSD. I’m still not convinced that bitcoins are more than a pyramid scheme, but i decided to check things out and it actually nowdays is quite easy to get a miner running on FreeBSD.

Well get a basic bitcoin generator and wallet running is quite easy:

First upgrade ports (The bitcoind port was recently updated), and then install bitcoind.

# portsnap fetch update

# cd /usr/port/net-p2p/bitcoind

# make install

When the config screen you have a option to enable the GUI or not. Since the port only installs bitcion (The command with GUI) or bitcoind (The command without GUI) you will have to decide which is best for you. I clearly prefer the version without GUI so it can be started in /etc/rc.local and run in the background.

When the install is done you have a bitcoin miner and wallet to run. Play a bit with it, but don’t use it!

Why? Well CPU mining is so slow that it will take for ages to get a bitcoin payout. I’m talking about years!

So instead join a mining pool. A mining pool is a service where serveral miners join forces and split the rewards when they mine a block of coins. In this way you will receive a small portion of the payout in proportion to how much you have contributed towards the block. The downside is that bitcon or bitcoind does not support joining bitcoin pools. So lets install another (Actually more efficient) miner. The one i have experimented with is called minerd and unfortunatly there is no port for it.

So this is what you need to do to get it up and running:

Upgrade ports:

# portsnap fetch update

Install jwasm:

# cd /usr/ports/devel/jwasm

# make install

And curl:

# cd /usr/ports/ftp/curl

# make install

Now it is time to download, patch and install minerd:

% wget

% tar xvf cpuminer-1.0.tar.gz

% cd cpuminer-1.0

Now some magic to get it running.:

Edit and find the follwing row:

DEFAULT_INCLUDES = [email protected][email protected]

And change it to:

DEFAULT_INCLUDES = [email protected][email protected] -I/usr/local/include

A file missing on FreeBSD is byteswap.h, but since it is just some small static inline functions jsut download it into the current directory:

# wget

Now we are ready to run configure and compiling the source:

# setennv CFLAGS “-O3 -Wall -msse2”

# ./configure

# make

This should have gone ok with a couple of warnings. Now we can run the miner with the following command:

% ./minerd –algo 4way –threads 2 –url –userpass USER.XXX:PASS

(This example is for running against the server at and you will need to register before your work will count towards generating bitcoins.)

And please note the –algo switch, there is several sha256 implementations to choose inbetwen. Do a couple of runs and check wich one is fastest on your machine. Now give it some time and you can start seeing the bit-cents rolling on your mining pools statistics page.

Anything strange? Or any questions or feedback? Please drop a comment here and i’ll try to help you out.

Это интересно:

Searching FreeBSD Ports

Added by Daniel Curtis 10 months ago. Updated 8 months ago.

Target version:


This is a guide for setting up and mining bitcoin on FreeBSD 10. This is not a comprehensive guide and is meant for educational purposes. YMMV

Prepare the Environment¶

  • Make sure the system is up to date:
    pkg update && pkg upgrade
  • Install sudo:
    pkg install sudo
  • Create a bitcoin user and group:
    pw add group bitcoin
    pw add user -n bitcoin -g bitcoin -s /sbin/nologin -c "Bitcoin" 

Install Bitcoin Daemon¶

  • Install bitcoin-daemon:
    pkg install bitcoin-daemon bitcoin-utils
  • Create a basic bitcoin config file:
    vi /usr/local/etc/bitcoin.conf
    • And set the following parameters:
  • Create the bitcoin data directory:
    mkdir /var/db/bitcoind
    chown bitcoin:bitcoin /var/db/bitcoind
  • Start and enable the server at boot:
    echo 'bitcoind_user="bitcoin"' >> /etc/rc.conf
    echo 'bitcoind_group="bitcoin"' >> /etc/rc.conf
    echo 'bitcoind_data="/var/db/bitcoind"' >> /etc/rc.conf
    echo 'bitcoind_enable="YES"' >> /etc/rc.conf
    service bitcoind start

Useful Commands¶

  • Get blockchain and network stats
    sudo -u bitcoin bitcoin-cli -conf=/usr/local/etc/bitcoin.conf getblockchaininfo
    sudo -u bitcoin bitcoin-cli -conf=/usr/local/etc/bitcoin.conf getnetworkinfo
    sudo -u bitcoin bitcoin-cli -conf=/usr/local/etc/bitcoin.conf getnettotals
  • Create a new bitcoin address and retrieve the address:
    sudo -u bitcoin bitcoin-cli -conf=/usr/local/etc/bitcoin.conf getnewaddress "MyBitcoin" sudo -u bitcoin bitcoin-cli -conf=/usr/local/etc/bitcoin.conf getaccountaddress "MyBitcoin" 
  • Get wallet info:
    sudo -u bitcoin bitcoin-cli -conf=/usr/local/etc/bitcoin.conf getwalletinfo
  • Get help:
    sudo -u bitcoin bitcoin-cli -conf=/usr/local/etc/bitcoin.conf help

NOTE: To ensure you DO NOT lose your wallet, make sure to keep a backup of /var/db/bitcoind/wallet.dat in a safe and secure location.

  • Get the blockchain size used on disk:
    du -ch /var/db/bitcoind/blocks/
  • Check the blockchain download progress:
    tail -f /var/db/bitcoind/debug.log

Install Bitcoin GUI Client¶

  • NOTE: This is an optional step used in a graphical environment.
  • Install bitcoin:
    pkg install bitcoin


#2 Updated by Daniel Curtis 10 months ago

  • Description updated (diff)
  • % Done changed from 70 to 100
  • Status changed from In Progress to Resolved

Also available in: Atom PDF

nvidia quadro bitcoin mining.

Bitcoin wallet FreeBSD ‹ Bitcoin wallet Bitcoin trade


Jochen Neumeister noticed that FreshPorts no longer lists phpunit6. Sure enough, I went searching and failed to find it. It did not turn up. Then I checked Include deleted ports, then clicked on Search again. Ahh, there it it. Sure enough, it is marked as deleted. Look for the small icon at the top, just […]


For several weeks, FreshPorts had a vuxml processing problem. In this blog post, I will share what I found. Introduction Incoming events for FreshPorts are handled by a small Python script which checks for flags and incoming commits. This ensures that work is carried out serially because parallel work can have unintended consequences. After each […]


The previous post on this blog was nearly 10 months ago. However, things have not stood still. There have been a few issues fixed and some are still in progress. The biggest thing underway is a major rework of the backend, the part that processes the incoming commits. There is nothing major; no huge code […]


Tonight, I was contacted by jrm on IRC, who told me that FreshPorts was missing something on a search. Yep. It was not in there. I looked on dev and I saw the same thing. Finding the cause I started by enabling debug on dev. I found this SQL: I started by removing one LEFT […]


Committing to a branch (e.g. 2016Q4) when the port in question has slave ports is getting tricky, especially if the port was added after the branch was created. Case in point, www/linux-c7-flashplugin11 was added to the tree on 19 Oct 2016. The 2016Q4 branch was created on 3 Oct, and therefore that port does not […]


$ grep -c /usr/websites/log/ 72446


I was asked if this was a known bug. It’s not. I don’t think anyone knows about it. dvl: ping. FreshPorts truncates COMMENT. Known issue? Here’s what I found there: Tool for use with clang to analyze Here is what the Makefile contains: $ grep COMMENT Makefile COMMENT= Tool for use with clang to […]


FreshPorts uses a cache for every port page (e.g. When an update to a port occurs, we must clear the cache for that port. This sounds simple, and it is. The various ways in which updates occur complicates the situation. This post is all about fixing one edge case: the addition or removal of […]


Recently, I’ve been adding more and more file content into the database, mostly because it’s useful. For example, we add the contents of the distinfo, because that information is useful. Next, it was pkg-plist, and before I was done that, someone suggested added in the Makefile. Neither pkg-plist nor Makefile will be perfect: Not all […]


About two weeks ago, I wrote a function for creating a port. This will take the port from head and copy it to a branch. This is vital because of the reasons discussed here: creating a new port and copying a port from head to a branch. This function worked and was useful, but it […]

reading bitcoinwisdom charts.

Install freebsd 11.1 Bitcoin Trends

How do I install gimp under FreeBSD operating systems?
The GIMP is designed to provide an intuitive graphical interface to a variety of image editing operations. It can be easily installed using the following method. Login as root and type the following command to update ports tree:

# portsanp fetch update

Install gimp, enter:

# cd /usr/ports/graphics/gimp
# make install clena

It will take some time to download, compile and install the gimp. Alternatively, you can install the binary package, run:

# pkg_add -r gimp

Sample outputs: pll lot bitcoin. at master · bitcoinbitcoin · GitHub

Bitcoin is an innovative payment network and a new kind of money.




Bitcoin uses peer-to-peer technology to operate with no central authority or banks; managing transactions and the issuing of bitcoins is carried out collectively by the network. Bitcoin is open-source; its design is public, nobody owns or controls Bitcoin and everyone can take part. Through many of its unique properties, Bitcoin allows exciting uses that could not be covered by any previous payment system.

Or get a quick overview for

account bitcoind.

<< Go back to the previous page

Похожие статьи