Run a BTFS Host

Run a BTFS file storage host on the BTFS network

Introduction

Hosts play a vital part in the BTFS network. As a host, your participation enables the decentralization of vast file storage network, while at the same time capitalizes your spare resources by rewarding you with BTT.

How It Works

When a renter uploads a file, the file is split into 30 shards, with each shard being stored in a host under contract. By default, each contract produces a payout to the host every 30 calendar days. File shards are "pinned" in a hosts' storage for the contract duration, ensuring that as long as the host remains available, the file shards are guaranteed to be stored.

Command Line Setup

You may also choose to configure Host settings via the terminal. First set up your BTFS daemon. Then enable the BTFS host config settings:

btfs config profile apply storage-host

This command updates your BTFS config settings to enable storage hosting. You can verify this by viewing your config file:

btfs config show


// Under "Experimental", the StorageHostEnabled setting is set to true

"StorageHostEnabled": true,

Host Dashboard

The BTFS Host Dashboard lets hosts conveniently adjust the storage size allocation, monitor BTT earned-to-date, calculate future potential BTT earnings, and much more. Once your BTFS daemon has been launched and is running, simply paste the URL http://127.0.0.1:5001/hostui into your browser to access the Host Dashboard.

Once the Host Dashboard launches, the first screen prompts for hosts to adjust storage size commitment:

1318

Upon launching the Host Dashboard, you will be greeted with a prompt to select your dedicated host storage space.


After committing the storage space, your Host daemon commences the syncing process with the BTFS network. Please be patient, as the syncing process may take some time for completion.

1294
If the syncing process is taking longer than 45 minutes, please make sure you enabled host profile:
btfs config profile apply storage-host

Once network syncing completes, you will see the complete hosting dashboard: 1288

Dashboard Components

  • Status: This tells you if your BTFS host is online or offline.
  • Score: This score reflects your hosting ability. The higher your score, the more likely you will receive hosting contracts. To improve your score, ensure that your host is running and connected to the network at all times.
  • Uptime: The percentage of time your BTFS host is running and connected to the network.
  • Contracts: The number of file contracts your host is currently entered into.
  • Earnings To-Date: The amount of BTT your BTFS host daemon has earned to date.
  • Future potential earnings: Your maximum potential earnings, based on the storage space committed.
  • Next payment date: The closest date in which a contract will produce a host payment.
  • Current host pricing: The current price set by the Host for hosting 1 TB/month, in BTT.
  • Host storage size: The proportion of used storage space vs. available storage space.

Configure Host Settings

The btfs storage announce command allows hosts to configure and update their preferred storage host settings. The following host configuration options are available:

OptionDescriptionFlag
Minimum Host Storage TimeMin number of days for storage.-d, --host-storage-time-min
Maximum Host Storage CapacityMax number of GB this host provides for storage.-m, --host-storage-max

Minimum Host Storage Time

btfs storage announce --host-storage-time-min=5

Maximum Host Storage Capacity

btfs storage announce --host-storage-max=5

// Under "Datastore" in your BTFS config, the Storage Max is set to 5 GB

"StorageMax": "5.0 GB"

📘

Withdrawing BTT

If you need to withdraw your BTT earnings, please refer to https://docs.btfs.io/docs/requirements#section-installing-go-btfs. Please note, currently, we only accept withdraw inquiries for earnings at 1,000 BTT or more.