Setup Curio

This guide will show you setup a new Curio cluster or migrate to Curio from Lotus-Miner

Setup YugabyteDB

For this guide, we’re setting up a single YugaByteDB. However, you can set up multiple YugaByteDB instances in a cluster to enable high availability.

Ensure that you have the following available before we install and set up YugabyteDB:

  1. One of the following operating systems:

    • CentOS 7 or later
    • Ubuntu 16.04 or later

    For other operating systems, Docker or Kubernetes. Please check out the YugabyteDB documentation.

  2. Python 3. To check the version, execute the following command:

    python --version
    Python 3.7.3

    If you encounter a Command 'python' not found error, you might not have an unversioned system-wide python command.

    • Starting from Ubuntu 20.04, python is no longer available. To fix this, run sudo apt install python-is-python3.
    • For CentOS 8, set python3 as the alternative for python by running sudo alternatives --set python /usr/bin/python3

    Once these dependencies have been installed, we can run the install script:

    Note: avoid using ZFS as the backing drive for YugabyteDB because of advanced filesystem commands so-far is unavailable.

    tar xvfz yugabyte- && cd yugabyte-
    ./bin/yugabyted start --advertise_address  --master_flags rpc_bind_addresses= --tserver_flags rpc_bind_addresses=
    |                                                yugabyted                                                 |
    | Status              :                                                                                    |
    | Replication Factor  : None                                                                               |
    | YugabyteDB UI       :                                                             |
    | JDBC                : jdbc:postgresql://          |
    | YSQL                : bin/ysqlsh   -U yugabyte -d yugabyte                                               |
    | YCQL                : bin/ycqlsh   -u cassandra                                                          |
    | Data Dir            : /root/var/data                                                                     |
    | Log Dir             : /root/var/logs                                                                     |
    | Universe UUID       : 411422ee-4c17-4f33-996e-ced847d10f5c                                               |

You can adjust the --advertise_address, --rpc_bind_addresses and --tserver_flags according to your own configuration and needs.

Migrating from Lotus-miner to Curio

Curio provides a utility to users onboard quickly. Please run the below command on your lotus-miner node and follow the os-screen instructions. It communicates in English (en), Chinese (zh), and Korean (ko).

curio guided-setup

Once the migration is complete, you can shut down all of your workers and miner processes. You can start curio process to replace them with correct configuration layer.

Testing the setup

You can confirm that the curio process is able to schedule and compute WindowPoSt by running a WindowPoSt test computation:

curio test window-post task

From the output we can confirm that a WindowPoSt gets inserted to the database, and is being picked up by the Curio process running with the wdpost configuration layer.

Initiating a new Curio cluster

Initiating a new miner ID on the Filecoin network requires an owner, worker and sender address. These address can be same or different depending on the user’s choice. Users must create these wallet on Lotus node before running the Curio commands.

lotus wallet new bls

Once new wallet are created, we must send some funds to them.

lotus send <WALLET> 5

Curio provides a utility for users to onboard quickly. Please run the below command on your new Curio node, choose Create a new miner option and follow the on-screen instructions. It communicates in English (en), Chinese (zh), and Korean (ko).

curio guided-setup

Once, the new miner has been created, You can start curio process with correct configuration layer.

Edit this page on GitHub