Curio
English
English
  • What is Curio?
    • Filecoin Storage Provider
  • Design
    • Sealing
    • Harmony Tasks
  • Getting Started
  • Versions
  • Installation
  • Setup
  • Curio Service
  • Storage Configuration
  • Configuration
    • Listen Address
    • Alert Manager
    • Balance Manager
    • Default Curio Configuration
  • Curio Market
    • Storage Market
    • Deal filters
    • Curio HTTP Server
    • Curio libp2p Server
      • libp2p Protocols
    • Indexing
    • IPNI (Interplanetary Network Indexer) Provider
    • Market UI
    • Retrievals
    • Migrating From Boost
  • Snap Deals
  • Batch Sealing with SupraSeal
  • Scaling Curio cluster
  • Curio GUI
  • Garbage Collection
  • Best Practices
  • Logging
  • Curio CLI
    • Curio
    • Sptool
  • API
  • Docker Devnet
  • Experimental Features
    • GPU Over Provisioning
    • Enable PDP
Powered by GitBook
On this page
  • Simplified explanation
  • How to enable snap-deals
  • Configuration
  • Enable snap tasks

Snap Deals

This guide explains how to enable snap-deals in Curio.

PreviousMigrating From BoostNextBatch Sealing with SupraSeal

Last updated 2 months ago

Simplified explanation

Snap-deals allow storage providers to accept deals from users and place that user’s data into a block of storage that had already been committed. That was a bit of a mouthful, so picture it like this.

Imagine there is a town with a very long shelf. Anyone in this town can store anything they want on this shelf. When a townsperson wants to store something, they give that thing to a storage provider. The storage provider builds a wooden box, puts the townsperson’s stuff into the box, and then puts the box on the shelf.

Some of the boxes have useful stuff in them, like photographs, music, or videos. But sometimes, the storage providers don’t have any townspeople lining up to put useful stuff into the boxes. So instead, they put packing peanuts in the box and put that on the shelf. This means that there are a lot of boxes being made to just hold packing peanuts. Making boxes takes a long time and takes a lot of work from the storage provider.

Instead of creating a new box every time someone wants to store something, it’d be better if we could just replace the packing peanuts with useful stuff! Since nobody cares about the packing peanuts, nobody is going to be unhappy with throwing them out. And the storage provider gets to put useful stuff on the shelf without having to create a new box! Things are better for the townsperson, too, since they don’t have to wait for the storage provider to create a new box!

This is a simplified view of how Snap-deals work. Instead of a storage provider creating an entirely new sector to store a client’s data, they can put the client’s data into a committed capacity sector. The data becomes available faster, things are less expensive for the storage provider, and more of the network’s storage capacity gets utilised!

How to enable snap-deals

To enable the snap deals pipeline in a Curio cluster, user needs to enable the snap deal specific tasks on the machines that have GPU resources. Apart from this, the deal ingestion pipeline needs to be updated to pass the deals to the snap deal pipeline instead of the PoRep sealing pipeline.

Data can be ingested using either the Snap Deals pipeline or the PoRep pipeline at any given time, but not both simultaneously.

Configuration

When switching between Snap and PoRep deal pipeline, you must ensure that no sectors are being sealed or snapped. All pipelines must be empty before making a switch.

Curio Market

  1. Enable snap deals on base layer. Enabling it on base layer is very important so that no node in the cluster accidentally forwards deal to PoRep pipeline.

  [Ingest]
  DoSnap = true

Boost Adapter (Deprecated)

Boost adapter is no longer supported with new Curio releases.

  1. Create or update the market layer (if one is already created) for the minerID where you wish to use snap deals pipeline.

    curio config add --title mt01000

    Add an entry like:

      [Subsystems]
      EnableParkPiece = true
      BoostAdapters = ["t10000:127.0.0.1:32100"]
      
      [Ingest]
      DoSnap = true

    Press ctrl + D to save and exit. Or edit the existing layer.

    curio config edit mt01000

    Enable the snap deals for ingestion:

      [Subsystems]
      EnableParkPiece = true
      BoostAdapters = ["t10000:127.0.0.1:32100"]
      
      [Ingest]
      DoSnap = true

    Save the layer and exit.

Enable snap tasks

  1. Add the upgrade layer already shipped with Curio to the /etc/curio.env file on the Curio nodes where GPU resources are available.

    CURIO_LAYERS=gui,seal,post,upgrade <----- Add the "upgrade" layer
    CURIO_ALL_REMAINING_FIELDS_ARE_OPTIONAL=true
    CURIO_DB_HOST=yugabyte1,yugabyte2,yugabyte3
    CURIO_DB_USER=yugabyte
    CURIO_DB_PASSWORD=yugabyte
    CURIO_DB_PORT=5433
    CURIO_DB_NAME=yugabyte
    CURIO_REPO_PATH=~/.curio
    CURIO_NODE_NAME=ChangeMe
    FIL_PROOFS_USE_MULTICORE_SDR=1

  2. Restart the Curio services on the node.

    systemctl restart curio

Save the layer and exit. and restart all the nodes.

Add the new market configuration layer to the appropriate nodes based on the .

best practices
Enable snap tasks
Sector as a shelf
Data boxes
Replacing data
A shelf representing the Filecoin network.
Types of data in a Filecoin sector.
Emptying sectors of dummy data to fill them with real data.