Filecoin 백서

Filecoin

원문

bitpro가 원문에서 글자만 모은 내용이에요. 표·그림·수식은 빠지거나 깨질 수 있어요. 전체 52쪽 중 37쪽

cker stack and follow the web guide ([Run a PDP provider](/provide-storage/pdp/install-and-run-pdp) · [Curio-PDP](https://docs.curiostorage.org/getting-started/curio-pdp)). 3. **Build with the Synapse SDK** using the [FOC developer guides](https://docs.filecoin.cloud/developer-guides). 4. **Choose a storage path** via [Upload to Filecoin](/getting-started/how-storage-works/upload-to-filecoin). ## Resources * [FOC documentation](https://docs.filecoin.cloud/) * [PDP overview (FOC docs)](https://docs.filecoin.cloud/core-concepts/pdp-overview) * [FWSS overview (FOC docs)](https://docs.filecoin.cloud/core-concepts/fwss-overview) * [Synapse SDK repository](https://github.com/FilOzone/synapse-sdk) # Run a PDP provider Become a Filecoin Onchain Cloud storage provider in about five minutes with the Dockerized Curio-PDP stack. Storage is one of the most common things people buy online. [Filecoin Onchain Cloud (FOC)](/build-on-filecoin/filecoin-onchain-cloud) lets you sell it from your own hardware, and everything you need runs on a single machine. The chain proves you’re still holding the data, and the network sends paying customers your way. Until recently, getting a PDP node running meant setting up a chain node, a database, and Curio yourself, then wiring the three together. That part is packaged for you now. One command brings the stack up, and a web guide handles the rest. You do **not** need Lotus-miner, Boost, or a PoRep sealing pipeline. Downloads aside, setup takes about five minutes. ## What’s in the box Curio-PDP ships as a single Docker Compose stack made up of three pieces: * **Forest** — the Filecoin chain daemon * **Yugabyte** — the database * **Curio-PDP** — the storage node itself, with a web dashboard They all run in Docker on their own private network. Only Curio-PDP faces the internet, on ports 80 and 443. An external Lotus or Forest node works instead of the bundled Forest, pointed at with `FULLNODE_API_INFO`. The first time you open the dashboard, it lands you on a setup guide. The guide checks your node and ticks off each step as it completes. Everything is set from the dashboard, so there’s no config file to edit. ## What you need * A Linux or macOS machine with Docker installed (Docker Compose comes with it) * 64 GB+ RAM and a 16-thread+ CPU (no GPU required) * NVMe or SSD for Yugabyte and Forest * About 100 GB of disk for the chain state and database, plus the storage you want to sell (the guide needs at least 20 GiB of that attached) * A reliable internet connection * A domain or subdomain you own * A little FIL to fund a wallet ## Start the stack Run these on the machine that’s going to be the node, from a folder on its NVMe or SSD. Use the mainnet lines to run for real, or the Calibration lines to try it on the test network first, where everything runs on free test funds: ```bash git clone https://github.com/filecoin-project/curio.git cd curio/docker/skiff # Mainnet SKIFF_IMAGE=filecoin/curio-pdp:latest docker compose -f docker-compose.yaml up -d docker compose -f docker-compose.yaml logs -f # Calibration test network (free test funds, no real FIL) SKIFF_IMAGE=filecoin/curio-pdp:calibnet docker compose -f docker-compose.yaml -f docker-compose.calibnet.yaml up -d docker compose -f docker-compose.yaml -f docker-compose.calibnet.yaml logs -f ``` Keep the `SKIFF_IMAGE=` prefix on any later `docker compose up`, or the stack falls back to building the `:dev` image. That brings up the node. Yugabyte is up in seconds. Forest downloads a chain snapshot the first time it starts, which takes about 20 minutes, and the first run also pulls the Curio-PDP image. Curio-PDP starts as soon as Forest is accepting connections, although the wallet balance and registration checks wait for Forest to finish syncing. By default, everything lives under `curio/docker/skiff/data/`. Now open `http://127.0.0.1:4701` in a browser. The dashboard only listens on localhost and has no login, so keep it that way. If you’re working on a remote box, forward the port over SSH: ```bash ssh -fN -L 4701:127.0.0.1:4701 you@your-host ``` You’ll land on the PDP Guide page. {% hint style="warning" %} Open only TCP 80 and 443 on your public firewall. Port `4701` is an unauthenticated admin GUI for local operator access — do not publish it to the internet. {% endhint %} ## The PDP Guide does the rest The guide is a checklist that the node verifies for you. The boxes tick themselves as each step is confirmed, and you can re-run the checks with the **Re-check** button. 1. **Fund a wallet** — Click **Create wallet** to make a new signing key, or paste in one you already have. A hex private key or the output of `lotus wallet export` will both do. Keep the key safe: if you create it here, this is the only time it’s shown. Then send some FIL to the address on screen. Once it lands, the box ticks itself. 2. **Attach your storage** — Open the Storage page and attach the folders Curio-PDP should use. The stack has already mounted a `/data` folder for you, and attaching that is the simplest option. If your disks are elsewhere, map them under `/data` in `docker/skiff/.env` before you start the stack. 3. **Set your domain** — On the Configuration page, set `HTTP.DomainName` to a domain or subdomain you own and point its DNS at this machine. The guide then checks if it can reach your node at that address. Don’t want to open inbound ports? Create a tunnel in the Cloudflare Zero Trust dashboard and paste its token into the guide. It downloads `cloudflared` and starts the tunnel for you — entirely optional. 4. **Register with FOC** — When the first three are green, the register button unlocks. One click adds you to the Filecoin Onchain Cloud service provider registry. Once the working group approves you, data starts arriving. From then on, the PDP Overview is your home page: data under proof, proving success and net income over the last 30 days, chain status, wallet balance, and any open alerts, all on one screen. ## What you earn Customers pay in USDFC, a US dollar stablecoin on Filecoin, and the money streams to you through Filecoin Pay as you prove you’re holding their data. The price list is written into the storage contract, so every provider gets paid the same rates. There is no commission on the storage rate — a 0.5% network fee comes off at settlement, and that’s the only deduction. Registration gets you into the registry. Once the working group approves you, data is routed to you. Keep the node up and proving, and the data will come. See the current schedule and how it was worked out in the [FOC pricing docs](https://docs.filecoin.cloud/introduction/about/#pricing), and the [Medium walkthrough](https://medium.com/@filoz/become-a-filecoin-onchain-cloud-storage-provider-in-five-minutes-57abbcd95876) for worked examples. ## Go deeper Hardware, custom storage paths, external chain nodes, TLS, and troubleshooting: [**Curio-PDP**](https://docs.curiostorage.org/getting-started/curio-pdp) — [docs.curiostorage.org](https://docs.curiostorage.org/) * See [About PDP](/provide-storage/pdp/about) for how the protocol fits FOC * See [Provide Storage](/provide-storage/getting-started) if you wanted the PoRep sealing path instead * Come say hello in [#fil-curio-help](https://filecoinproject.slack.com/archives/C06LF5YP8S3) on Filecoin Slack if you get stuck # Networks Available Filecoin networks for production, testing, and local development. Filecoin operates several networks for different purposes. Use Mainnet for production, Calibration for testing, or spin up a local testnet for development. ## Table of contents * [Mainnet](/networks-and-tools/networks/mainnet) — the production Filecoin network with real FIL and storage deals * [Calibration](/networks-and-tools/networks/calibration) — the primary testnet that mirrors Mainnet parameters * [Local testnet](/networks-and-tools/networks/local-testnet) — a private network for local development and experimentation * [Legacy networks](/networks-and-tools/networks/legacy-networks) — deprecated networks that are no longer active # Mainnet Mainnet is the primary Filecoin network. Mainnet began on block 148,888. It supports 32 GiB and 64 GiB sectors. {% hint style="info" %} Also see [Mainnet RPCs](/networks-and-tools/networks/mainnet/rpcs) and [Mainnet Explorers](/networks-and-tools/networks/mainnet/explorers). {% endhint %} **Maintainer**: [Protocol Labs](https://protocol.ai) ## Genesis * CAR File: `QmavMCf95w2UMYGD1J5GpHcWBWXR2jTFYmtAkgeroMmpk1` * Reset Timestamp: `2020-08-24T22:00:00Z` * Genesis Block CID: `bafy2bzacecnamqgqmifpluoeldx7zzglxcljo6oja4vrmtj7432rphldpdmm2` * SHA-1 Digest: `4782cb42b4b01793b5cd9f593cc3dc87b6d3c7b4` ## Network parameters * Supported Sector Sizes: `32 GiB` and `64 GiB` * Consensus Miner Min Power: `10 TiB` * Epoch Duration Seconds: `30` * Expected Leaders per Epoch: `5` * WindowPoSt Proving Period: `2880` * WindowPoSt Challenge Window: `60` * WindowPoSt Period Deadlines: `48` * Pre-Commit Challenge Delay: `150` ## Bootstrap peers Bootstrap peers for mainnet can be found at: `https://github.com/filecoin-project/lotus/blob/release/`**\[latest release]**`/build/bootstrap/mainnet.pi` The latest Lotus release can be found at <https://github.com/filecoin-project/lotus/releases/latest/> ## Resources * [Latest lightweight snapshot](https://forest-archive.chainsafe.dev/latest/mainnet/) generated with [Forest](http://github.com/ChainSafe/forest) by [ChainSafe](https://chainsafe.io/) * [Complete Filecoin blockchain archival data](https://forest-archive.chainsafe.dev/list/) generated with [Forest](http://github.com/ChainSafe/forest) by [ChainSafe](https://chainsafe.io/) * [Status page and incidents](https://filecoin.statuspage.io/) * [Slack Channel for Updates: #fil-network-announcements](https://filecoinproject.slack.com/archives/C01AC6999KQ) * [Slack Channel for Questions: #fil-help](https://filecoinproject.slack.com/archives/CEGN061C5) * [Mainnet block explorer: FilFOX](https://filfox.info/en) * [Mainnet Faucet - Forest Explorer](https://forest-explorer.chainsafe.dev/faucet/mainnet) [Was this page helpful?](https://airtable.com/apppq4inOe4gmSSlk/pagoZHC2i1iqgphgl/form?prefill_Page+URL=https://docs.filecoin.io/networks-and-tools/networks/mainnet) # Explorers A block explorer is a tool that allows users to view and search the contents of blocks on a blockchain. This page covers available explorers for the Filecoin mainnet. Block explorers allow you to view the details of the Filecoin network on a single website. Individual block explorers contain different features that may be useful. None of these sites are created or maintained by Protocol Labs or the Filecoin Foundation. This list is in alphabetical order: ### Beryx Website [beryx.zondax.ch](https://beryx.zondax.ch/) ### Filfox Website: [filfox.info](https://filfox.info/en/) ### Filscan Website: [filscan.io](https://filscan.io) ### Starboard Website: [fvm.starboard.ventures](https://fvm.starboard.ventures/) ### Blockscout Open-Source FEVM Explorer Website: [filecoin.blockscout.com](https://filecoin.blockscout.com/) ## API requests If you have access to a Filecoin node, you can send a JSON-RPC request to get block information. To get the head tipset: ```shell curl --location --request POST 'https://api.node.glif.io/rpc/v1' \ --header 'Content-Type: application/json' \ --data-raw '{ "jsonrpc":"2.0", "method":"Filecoin.ChainHead", "params": null, "id":1 }' | jq ``` Print a block: ```shell curl --location --request POST 'https://api.node.glif.io/rpc/v1' \ --header 'Content-Type: application/json' \ --data-raw '{ "jsonrpc":"2.0", "method":"Filecoin.ChainGetBlock", "params": [{"/": "bafy2bzacebpgpa7elb5uwqxbiljlzgbmpenv4yw2e3gpcjk7ssxv2ijv3ecv2"}], "id":1 }' | jq ``` Print message information: ```shell curl --location --request POST 'https://api.node.glif.io/rpc/v1' \ --header 'Content-Type: application/json' \ --data-raw '{ "jsonrpc":"2.0", "method":"Filecoin.ChainGetMessage", "params": [{"/": "bafy2bzacebpgpa7elb5uwqxbiljlzgbmpenv4yw2e3gpcjk7ssxv2ijv3ecv2"}], "id":1 }' | jq ``` [Was this page helpful?](https://airtable.com/apppq4inOe4gmSSlk/pagoZHC2i1iqgphgl/form?prefill_Page+URL=https://docs.filecoin.io/networks-and-tools/networks/mainnet/explorers) # RPCs Public RPC endpoints are available for the Filecoin mainnet. [Chainlist](https://chainlist.org/?search=filecoin\&testnets=true) provides a dynamically updated list of [available Filecoin - Mainnet RPCs](https://chainlist.org/?search=filecoin\&testnets=false). These endpoints are limited to the read-only [Filecoin JSON RPC API](/reference/json-rpc) including read-only [Filecoin Eth RPC](/reference/json-rpc/eth) methods, except for the write operations [`MPoolPush`](/reference/json-rpc/mpool#mpoolpush) and [`EthSendRawTransaction`](/reference/json-rpc/eth#ethsendrawtransaction) for sending already signed messages. {% hint style="info" %} Please note that most publicly hosted endpoints **only guarantee recent state, i.e. 2000 of the latest blocks (last 16.67 hours).** To request an archival node you can contact a provider below. {% endhint %} In order to check the current benchmarked performance of each of the below endpoints, please see the [Filecoin ETH RPC Benchmark app](https://benchmark-rpc.vercel.app/). | Provider | HTTPS endpoint | WSS endpoint | Docs | API Support | | ------------------------------------------- | ------------------------------------- | -------------------------------------------------- | -------------------------------------------------------------------------------------------------- | --------------------------------------------------------- | | [Glif Nodes](https://api.node.glif.io/) | `https://api.node.glif.io/rpc/v1` | `wss://wss.node.glif.io/apigw/lotus/rpc/v1` | [Glif Nodes - Docs](https://api.node.glif.io/) | All Filecoin and Eth JSON RPC methods including MPoolPush | | [Ankr](https://ankr.com/) | `https://rpc.ankr.com/filecoin` | By request at: <https://www.ankr.com/rpc/filecoin> | [Ankr Docs - Filecoin](https://www.ankr.com/docs/rpc-service/chains/chains-list/#filecoin) | All Filecoin and Eth JSON RPC methods including MPoolPush | | [Chainup Cloud](https://cloud.chainup.com/) | `https://filecoin.chainup.net/rpc/v1` | `wss://filecoin.chainup.net/rpc/v1` | [Chainup Cloud Docs - Filecoin](https://docs.chainupcloud.com/blockchain-api/filecoin/public-apis) | | | [Lava](https://www.lavanet.xyz/) | `https://filecoin.lava.build` | | [Lava - Docs](https://docs.lavanet.xyz/iprpc#filecoin) | All Filecoin and Eth JSON RPC methods including MPoolPush | | [NOWNodes](https://nownodes.io/) | `https://fil.nownodes.io` | | [NOWNodes - Docs](https://docs.nownodes.io/fil/) | Requires an API key | ## Additional Notes: * Glif Nodes offers a [Lotus Lite node](/provide-storage/nodes/lite-nodes/spin-up-a-lite-node) endpoint with the following command: ```shell FULLNODE_API_INFO=wss://wss.node.glif.io/apigw/lotus lotus daemon --lite ``` When using a Lotus Lite node, omit `/rpc/v1` from Glif’s WebSocket address. A Lotus Lite node is a stripped down version of a Lotus full-node capable of running on lower-end hardware. It also allows for local signing for storage deals without a full Lotus node. [Was this page helpful?](https://airtable.com/apppq4inOe4gmSSlk/pagoZHC2i1iqgphgl/form?prefill_Page+URL=https://docs.filecoin.io/networks-and-tools/networks/mainnet/rpcs) # Network performance You can use these heuristics to understand general Filecoin network performance and how it fits your use case. The Filecoin Network is a decentralized storage market and network that provides data persistence via a decentralized protocol and publicly verifiable storage proofs on a blockchain. Current Filecoin network performance is primarily determined by security parameters and Filecoin’s [proof constructions](https://spec.filecoin.io/#algorithms__pos). It is highly non-trivial to provide highly reliable benchmarks for Filecoin network performance. However, as you begin interacting with Filecoin, you can use these heuristics to understand general Filecoin network performance and how it fits your use case. ## Financial transfers A message that requires [transferring FIL](https://lotus.filecoin.io/docs/set-up/manage-fil/) is often extremely fast, and will take on average \~1 blocktime (or around 30 seconds) to be reflected on-chain. We consider 120 blocks (1 hour) a conservative number of confirmations for high-value transfers. ## Data storage In the Filecoin data storage protocol, the following occurs once a deal is proposed and accepted: 1. *Funding the storage market actor*: This process takes roughly 1-2 minutes and ensures that both the client and the storage provider have funds and collateral to pay for the deal. 2. *Data transfer*: This portion of the deal flow involves the client’s node sending the relevant data to the providing node. The data transfer rate varies widely, depending on the client and the storage provider’s network and disk bandwidths. Generally, the network speed between client and storage provider is the limiting factor in transfer rate. 3. *Deal shows up on-chain*: Once the data is received, the storage provider verifies that it matches the deal parameters. Then, the provider publishes the deal on the chain. 4. *Sector sealing*: Once the deal shows up on-chain, the storage provider must still generate Proof-of-Replication and seal the sector. This process is currently estimated to take roughly 1.5 hours for a 32 GB sector on a machine that meets the minimum hardware requirements for storage providers. For the majority of clients, the most important metric is the time from deal acceptance to deal appearance on-chain. This metric is the sum of the time required to complete steps (1) through (3), described above. Based on current high-level benchmarks, these steps are estimated to take roughly 5-10 minutes for a 1 MiB file. ## Data retrieval There are two methods by which one can directly retrieve data from the Filecoin network: * **Fast retrieval**: By default, some Filecoin clients, like lotus, enable storage providers to store an unsealed copy of the stored data in addition to a sealed copy. The sealed copy is necessary for the ongoing storage proofs that a storage provider must submit, while the unsealed copy can be used for quicker retrievals of the data from the storage provider. While this is a valuable feature, there is no guarantee that all storage providers are storing extra unsealed copies of the stored data, as this is not a verifiable part of the protocol. In lotus, this feature is called *fast-retrieval*. * **Retrieval after unsealing**: Because of the Filecoin protocol’s design, storage providers are essentially cryptographically guaranteed to store client data in its sealed format. Therefore, if the storage provider doesn’t have an unsealed copy of the data stored, they will have to unseal the sealed data first (i.e., decoding the encoded data) and then serve it back up to the requester (i.e., the retrieval client). In both methods, the data retrieval process after a retrieval deal is accepted includes: 1. **Funding the payment channel for retrieval**: Similar to the storage deal payment channel funding above, except for data retrieval. The timing estimates for payment channel creation and funding are roughly the same as noted above. 2. **Unsealing (if needed)**: The storage provider unseals (decodes) the data so that the requester can read it. Sealing and unsealing are symmetric processes, which means they take roughly the same amount of time in either direction. Thus, the unsealing step is estimated to take around as long as the sealing step listed above, or around \~3 hours for a 32 GiB sector on a machine running minimum hardware requirements. 3. **Data transfer**: The storage provider begins transferring the data back to the data requester. This is also
프로젝트로 돌아가기