Fjordcoin

Fjordcoin documentation

Everything you need to run a Fjordcoin node, hold coins and mine. Fjordcoin Core is a fork of Litecoin Core 0.21.4, so almost any Litecoin or Bitcoin Core guide also applies. Swap the program names and ports.

1. Build the software

On Debian or Ubuntu, install the build tools and libraries:

sudo apt-get install git build-essential libtool autotools-dev automake pkg-config \
  bsdmainutils python3 libevent-dev libboost-dev libboost-system-dev \
  libboost-filesystem-dev libboost-test-dev libboost-thread-dev libssl-dev \
  libfmt-dev libdb5.3++-dev libsqlite3-dev zlib1g-dev

Then, inside the Fjordcoin source folder (chain/):

./autogen.sh
./configure --without-gui --disable-tests --disable-bench --with-incompatible-bdb
make -j"$(nproc)"

The build names its programs after Litecoin. Copy them to their Fjordcoin names:

for b in d -cli -tx -wallet; do
  sudo install -s src/litecoin$b /usr/local/bin/fjordcoin$b
done

2. Run a node

Create ~/.fjordcoin/fjordcoin.conf. Choose your own long random password:

server=1
daemon=1
rpcuser=fjord
rpcpassword=CHANGE-ME-to-a-long-random-string
fallbackfee=0.0001

Start the node and check that it is on the right chain. Block 0 must be the Fjordcoin genesis block:

fjordcoind
fjordcoin-cli getblockhash 0
69f98fc6689a62b7dd61898d2658ff330607798509afe8a31095aa88430a8e14

Stop it cleanly with fjordcoin-cli stop. Data is kept in ~/.fjordcoin.

3. Create a wallet

fjordcoin-cli -named createwallet wallet_name=main load_on_startup=true
fjordcoin-cli getnewaddress
fjc1q…

Prefer not to run a node? Use the web wallet instead. The address starting with fjc1 is safe to share. It is what you paste into the balance checker and the faucet. Your private keys stay in ~/.fjordcoin/wallets. Back that folder up, and consider fjordcoin-cli encryptwallet.

4. Get coins

Fjordcoin is not sold anywhere and has no price. There are three ways to get some:

Check what you have with fjordcoin-cli getbalance, or see everything with fjordcoin-cli getwalletinfo.

5. Mine

The starting difficulty is deliberately low, so the node's built-in miner finds a block in seconds to minutes on a single CPU core:

fjordcoin-cli generatetoaddress 1 "$(fjordcoin-cli getnewaddress)"

Mined coins are locked for 100 blocks before they can be spent. Until then they show as immature_balance in getwalletinfo.

To keep the chain ticking, tools/miner.sh mines one block whenever the newest block is older than 2.5 minutes. As more miners join, the difficulty adjusts every 2,016 blocks to hold that pace.

6. Send coins

fjordcoin-cli sendtoaddress fjc1q…recipient… 0.5
fjordcoin-cli gettransaction <txid>

A payment is confirmed once it is included in a block. Six confirmations (about 15 minutes) is the usual mark for "settled".

7. Connect nodes

There are no seed servers yet, so nodes have to be introduced to each other by hand. On the second machine, point at the first one's address and P2P port:

fjordcoin-cli addnode 203.0.113.10:24333 add
fjordcoin-cli getpeerinfo

Or make it permanent with addnode=203.0.113.10:24333 in fjordcoin.conf. The first machine must allow inbound TCP on port 24333.

Accounts and the web wallet

The web wallet is the quickest way to hold Fjordcoin: no node, no download. You create an account with a user name and password, and your wallets, contacts and notes follow you to any device you sign in on.

How your wallets are protected. Your browser turns your password into two separate keys. One proves who you are when you sign in. The other encrypts your wallets before they are sent to the server, and never leaves your device. The server therefore stores only data it cannot read, and transactions are signed on your device.

Wallets follow the BIP39 and BIP84 standards with derivation path m/84'/1'/0'/0/0.

Mining pool

In a pool, many miners work on the same block and share the reward, so everyone gets small, regular payments instead of waiting to find a whole block alone. The pool page shows the live numbers and the exact command to run.

To run the pool yourself: pool/start.sh. Settings are environment variables: POOL_FEE (percent, default 1), SHARE_DIFF (0.05), MIN_PAYOUT (0.1), STRATUM_PORT (3333). For a quick test without installing a miner, node tools/testminer.js YOUR_ADDRESS mines slowly on one core.

Explorer

The explorer shows every block, transaction and address on the chain. Search by block height, block hash, transaction id or address. Everything on a blockchain is public: anyone can see the balance and history of any address.

Networks and ports

NetworkFlagP2PRPCAddresses
Main(none)2433324332fjc1…, F…
Testnet-testnet3433334332tfjc1…
Regtest-regtest4444444443rfjc1…

Regtest is a private, instant-mining sandbox on your own machine. It is the best place to experiment with anything risky.

How the fork was made

A fork that starts a new chain changes surprisingly little code. These are all the edits relative to Litecoin Core 0.21.4:

FileWhat changed
src/chainparams.cppNew genesis block (message, time, nonce, hash) for all three networks. New network magic bytes and P2P ports. Address prefixes (F, fjc). Lower proof-of-work limit. Soft forks active from block 1. Litecoin's checkpoints and seed nodes removed.
src/chainparamsbase.cppRPC ports.
src/util/system.cppData folder ~/.fjordcoin and config file fjordcoin.conf.
src/clientversion.cppNetwork user agent FjordcoinCore.
src/policy/feerate.hCurrency unit FJC.
src/util/message.cppSigned-message prefix.
src/rpc/mining.cppgetblocktemplate no longer requires connected peers or a recent tip, so a pool can run on a one-node network.
configure.acPackage name Fjordcoin Core.

The genesis block was mined with tools/genesis.py, a short Python script that builds the first transaction, then tries nonces until the Scrypt hash of the block header is below the target. Run git diff inside chain/ to read every changed line.

Hobby project. Fjordcoin is for learning. It has no monetary value and is not an investment.