Understand the value embodiment and mining principle of Filecoin in one article
星球君的朋友们
2020-09-04 09:09
本文约7029字,阅读全文需要约28分钟
The "Filecoin" mining investment report sorts out the value of IPFS and Filecoin.

Editor's Note: This article comes fromEditor's Note: This article comes fromsecondary title

abstract

abstract

The "Filecoin" mining investment report sorts out the value of IPFS and Filecoin. The mining principles that miners need to understand to participate in mining, as well as the core elements of mining: computing, storage, and software including hardware.

Among them, the hardware part of the mining machine analyzes the difference between Filecoin mining and traditional mining in computing power and storage power, and calculates the mining cost of the hardware part.

*The full text of the article is 7016 words, and the reading time is about 25 minutes.

What is the value of Filecoin

secondary title

1. The relationship between IPFS and Filecoin

The target of the IPFS protocol is the HTTP protocol. The HTTP protocol solves the problem of network transmission. IPFS is a global, point-to-point distributed version file system, dedicated to creating a network transmission protocol for persistent and distributed storage and sharing files."form.

secondary title

2. Filecoin market situation

① ICO Fundraising Situation

Filecoin's ICO is divided into two stages: private placement and public placement, with a total of 257 million US dollars.

The total number of Filecoins is 2 billion, of which 70% are rewards for miners; 15% are reserved by Filecoin (Protocol Lab) for future technology development and marketing; 10% are sold to Filecoin partners at preferential prices; 5% set up foundations to develop community ecology.

secondary title

3. Project development

①Project development

The white paper for IPFS and Filecoin was published in 2014. On February 14, 2019, the first version of Filecoin was launched. Up to now, the code of Filecoin has been updated for 5+ versions, and the main network is expected to be launched in late September.

② Testnet with rewards

The rewarded testnet is a three-week miner competition test. Participants need to store the encapsulated data into the network, and the rewards will increase with the growth of the stored data.

The competition elements for participating in the testnet include: the success rate of order transactions, to determine whether miners can provide effective storage; the sector life cycle, to determine that miners can upgrade the committed space through sector upgrades.

③ Reasons for multiple delays in the launch of the mainnet

Secondly, some problems that affect network usage during the development process require the development team to continuously repair and deploy, and the core team has a small number of development members.

secondary title

4. Application status of IPFS

①Decentralized video platform D-Tube

DTube is a decentralized video platform built on STEEM (a blockchain-based social media platform). Video files are stored on the DTube platform through the IPFS protocol. Content creators are rewarded with platform tokens for the content they upload.

DTube uses the STEEM blockchain to save user data, and IPFS to save video and picture data. Publishing a video on DTube is equivalent to doing two things:

2. Publish videos and pictures to the IPFS network

refer to:http://ipfs.cn/news/info-100155.html

refer to:

② Decentralized social platform AKASHA

AKASHA has received a lot of attention since its birth, and is known as the prototype of the next-generation social media network. It also uses IPFS technology, and files are placed on the IPFS network, ensuring file security while also ensuring users' freedom of speech and privacy.

The project aims to create a completely free social platform, so Ethereum and IPFS are used as the underlying technical support. Through the many decentralized nodes of Ethereum, the dependence on the server is eliminated. Through IPFS, the security, privacy and stability of content transmission are ensured. At present, it has tens of thousands of users around the world, and its products are constantly iteratively updated.https://akasha.org

Project Details:

③Other applications:

EOS, ETH digital currency and imToken wallet;

Library of Congress, WikiLeaks, Google and Firefox;

BitTube was developed to give content creators a part of the network they contribute to.

What preparations are required to participate in Filecoin mining?

secondary title

1. Understand the core elements of Filecoin mining

①Ranking of computing power

Computing power ranking is the core element of the rewarded testnet. In theory, block rewards are proportional to the effective computing power provided by miners. The higher the computing power per unit time, the greater the power of miners to participate in the block and the more rewards they get. It directly reflects the technical strength of miners.

Because the large-scale and small-scale technical problems that need to be solved are very different, involving network bandwidth, task allocation between machines, large-scale storage, etc. In the construction and maintenance of Filecoin distributed storage, the difficulty coefficient increases exponentially according to the scale state.

②Authenticity and transparency of mining machine information

Filecoin mining machines are assembled from some general-purpose hardware, and the threshold is relatively low, so there are hundreds of mining machine manufacturers. The hardware parameters of many manufacturers are very opaque. As the main network is about to go online in the market, the configuration of each manufacturer's mining machines becomes clearer.

③Packaging speed

In the PoRep proof of replication, the speed of storing files is the packaging speed, that is, how many T of computing power can be obtained per 10,000 yuan per day. It depends on the optimization level of mining software under certain hardware conditions.

The packaging speed solves the rapid conversion from storage space to computing power, which requires various configurations of hardware, which will be explained in detail in the hardware disassembly of the mining machine below.

(After the announcement of the Filecoin economic model, the mined FIL reward delay period and linear release period are 20 days and 180 days respectively; and the deflation casting model is adopted, and the miners are initially rewarded with 30% of the coins dug. The importance of packaging speed is relatively reduced. )

④Technical Strength

Technical strength mainly includes: operation and maintenance capabilities, block burst optimization, order receiving and other optimization capabilities.

At present, there are not many companies capable of independently developing the Filecoin mining system, which is why there are currently hundreds of miners conducting test mining on the development test network, but more than 80% of the mining machines do not have test data.

secondary title

2. Understand the principle of Filecoin mining

① Verify effective storage of miners

In order to prevent miners from cheating and launching malicious attacks, miners are required to generate Proof of Storage (Proof of Storage) into the network every block generation cycle in the blockchain system. There are two algorithms used in Proof of Storage that miners must cryptographically verify that they have kept their promise to store files: Prof of Replication and Proof of Space time.

② Copy proof and space-time proof

When the miners reach an agreement to store data within a cycle, verification is required after the storage is completed. There are two key points when verifying the effective storage of miners: the first is to verify that the storage is completed within the specified time, and the second is to verify that the data has not been deleted within the agreed time, and check regularly.

After the first verification completes the data storage within the specified time, it needs to pass the copy proof (Prof of Replication), and the link of copy proof calculation requires the miners to submit the proof to the entire network to the chain. This process is resource-intensive and takes a long time to complete.

After completing the first step, the second step needs to pass the proof of space time. The proof of space time proves that the data still exists within the validity period after the copy proof. Proofs of space-time need to be done in a very short time.

③ In-depth analysis of data computing and storage

(According to the official release of the Filecoin mining guide)

calculation part

The calculation is divided into four phases: PreCommit phase 1, Precommit phase 2, Comit phase 1, Commit phase 2, hereinafter referred to as p1, p2, c1, c2.

P1 link: Improve the efficiency of proof of replication, which can be completed within hours according to different hardware configurations.

P1 link: GPU acceleration is preferred, and CPU will slow down significantly.

C1, c2 links: CPU alone, or CPU and GPU hybrid computing can be used. It takes different time depending on the hardware configuration.

Space-time proof link: use GPU to improve efficiency, and complete space-time proof within 25s to get block rewards. The reason why the GPU is used is because a large number of powt-snark calculations are performed in a block to solve the fast sealing problem, and the most suitable solution for the snark calculation is the GPU. The greater the time-consuming gap between Proof of Replication and Proof of Space-Time, the better.

storage part

The storage part is the concept of hard disk space. Mining machine merchants claim to have 100T hard disk space, but they actually participate in network computing. The data is processed into officially recognized data through several stages, and then stored in the hard disk. The calculation part is involved here, and the speed of the calculation part is very different.

④Separation of computing and storage

If storage and computing are not separated, they will first face the problem of load.

Calculation and storage are carried out at the same time, and the load on the machine is too high, resulting in too slow reading and writing, and it is also easy for the hardware to fail and have to be restarted. The two most common situations are that the graphics card is lost, and the other is that the zombie process cannot be killed and the machine has to be restarted. If it is randomly checked during the restart process, the computing power will be deducted.

Then there is the issue of expansion.

When the disk is full, it needs to be expanded. Expanding the hard disk is not a very simple problem. In the end, this is related to the mechanism of Filecoin itself. The storage under a cluster has a characteristic, that is, it cannot leave the cluster. Once the data is written, the hard disk is deeply bound to the host and cannot be taken away. All disks need to remain in the cluster where they were originally located, which is a very important feature of Filecoin.

If computing and storage are put together, it means that the entire machine is bound to the cluster and cannot be taken away. If you want to expand the capacity, it will cause a linear increase in the size of the cluster. After the growth reaches a certain level, the network, hosts, and racks will all face unbearable results.

(Excerpt from Pomegranate Mining Pool "It's Not That Simple, Detailed Explanation of Filecoin Mining Machine Storage and Expansion Technology")

secondary title

3. The difference between Filecoin mining and traditional mining - computing power and storage power

Bitcoin mining adopts PoW workload proof, while the mining principle adopted by Filecoin is PoSt (full name Proof-of-Spacetime), which is (storage) proof of space time. On the basis of the equity consensus PoS (Proof-of-Stake), Filecoin improved the consensus mechanism to become PoSt to replace the workload proof PoW.

Disassembly analysis of Filecoin mining machine

secondary title

①CPU

1. Hardware configuration and its functions

②GPU

In the packaging pre-submission stage of the proof of replication, after the official algorithm was revised in April-May 2020, it took more than 30 hours for the original high-cost Intel CPU to complete the calculation of P1, and the requirements for the CPU were increased. AMD's CPU packaging efficiency is five times that of Intel's. Using AMD3960X CPU, it takes about 4 hours to complete parallelism. Currently on the market mainly AMD3 series and 7 series.

③SSD

In the packaging submission stage of the replication proof, an N card is required to generate a zero-knowledge proof. The current market brands are: Gigabyte, msi, ASUS, Zotac and so on.

The main functions of SSD in Filecoin mining are: used as a system disk; Filecoin node data storage disk; during the sealing process, the data in RAM is transferred to the mechanical hard disk, which can be used as a large cache and used to store unsealed transmission sectors.

After P1 and P2, there is a waitseed link, the main function is to wait for a certain number of blocks to obtain random numbers. Including a waiting time, the official changed the initial value 10 to 150, and the required waiting time became: 150 height * 25 seconds / 60 seconds = 62.5 minutes. If the SSD memory is not enough, the machine will idle down and process this part first After the data is modified, the demand for SSD becomes larger.

The mainstream SSD hard disks are 8TB, 16TB, etc., and the interface is generally divided into three types (take Samsung brand as an example):

SATA interface, the transmission speed is about 520MB/s

M.2 interface (SATA bus), the transmission speed is about 520MB/s

M.2 interface (NAME protocol), the transmission speed is about 3200MB/s

④Memory (RAM)

The main role of memory in Filecoin mining: when sealing files, temporarily store the sealed files and run the various links of the mining program, and use the calculation data cache. When choosing a memory, the speed of the memory needs to be considered. At present, the common DDR memory is DDR2, DDR3 and DDR4 series, and the starting frequency of DDR4 is the highest and the speed is the fastest. The second is the capacity of the memory.

The mines mainly provide electricity, bandwidth, computer rooms, and network security protection. Currently, the mines that meet Filecoin mining are mainly professional standardized IDC computer rooms. The height of the server host chassis needs to be customized to 4U.

secondary title

2. Official release hardware reference

Protocol Labs did not publish the specific hardware configuration schemes in the computing and storage links, but only published hardware references.

GPU:

As a rule of thumb, a multi-core CPU with a higher frequency will increase the packing speed, allowing storage miners to submit storage to the network. Protocol Labs' own tests show that modern AMD processors with SHA extensions have a big advantage over other processors.

RAM:

A powerful GPU is necessary to complete the SNARK calculation within the required time limit. Lotus' current design supports NVIDIA chips. We anticipate supporting graphics cards from other vendors in the future. The configurations we experimented with successfully are provided in our benchmarks.

The current Filecoin network only supports packing 32GiB and 64GiB sectors. Performing calculations on these larger sectors requires correspondingly more memory: at least 128GiB is recommended for mining systems.

There are many factors to consider when choosing the right storage solution design, and the revenue model of the mining operation is probably the most important factor. Storage miners are currently required to maintain a raw storage capacity of 1TiB (or the equivalent after mass adjustment; this will increase to 100 TiB for mainnet) in order to produce blocks, but miners may find more to consider.

(Time-consuming configuration recommended by the official website)

secondary title

3. Cost Analysis of Filecoin Mining

Filecoin mining machines need to generate effective computing power through continuous calculations, and secondly, hard disks are needed to store computing power. The cost of hardware is mainly in these two sectors.

How can the data be calculated faster? One is to improve the performance of computing resources, and the other is to improve the efficiency of storage on-chain. The increase in the proportion of this part of the cost investment will increase the cost per T, and there will be an equilibrium point in terms of economic return calculation and storage resource allocation. Therefore, various mining machine manufacturers on the market provide many different mining machine hardware configuration solutions.

Hardware calculation part cost:

CPU + motherboard + graphics card + flash memory + SSD + chassis ≈ 110,000

Hardware storage part:

Hard disk + CPU + motherboard + chassis ≈ 80,000

Calculation and packaging speed: G/10,000/hour = storage/price/24 hours

The theoretical daily income of mining and the time required for the mining machine to fill up the storage can also be calculated based on the packaging speed.

first level title

Profit Analysis of Filecoin Mining

1. Filecoin is a miner-friendly token: Filecoin network miner rewards or income mainly come from newly minted tokens on the network and miner fees for using the network.

2. Market value:

The total amount of Filecoin tokens is 2 billion, and miners can obtain 70% of them through mining. Calculated at $22 (price on September 1), there is a market of $30.8 billion.

3. Testnet rewards:

The 4.25 million testnet rewards are shared by the top 100 in the world and the top 50 in each continent, and the personal income of miners is considerable.

4. Add the amount of Filecoin circulating disk every day:

10% of the private placement round and ICO sales, that is, 200 million pieces, will be released linearly in 6 months, 12 months, and 3 years.

It can be calculated that about 600,000 coins are dug up by the ICO private placement and mining part every day. According to the current (September 1st) currency price of 22 US dollars, the daily increase in circulation is about 13.2 million US dollars.

Risks of Filecoin Mining

secondary title

1. The initial investment cost of mining has been greatly increased

Lock-up period + linear release:

The official has set a lock-up period of 20 days for FIL, and will be released linearly every day for the next 180 days.

Pledge mechanism:

In the newly published "Filecoin Economic Model White Paper", there are three different pledge mechanisms: initial pledge, block reward as pledge, and storage transaction provider pledge.

The first is that miners must provide filecoin for each sector as an initial commitment. The second mechanism is to reduce initial token staking requirements through block reward staking. The third creates an incentive mechanism between miners and users to make miners stand out in the market.

①Pre-stake

Pre-staking means that mining can only be done after pledging coins, and it is a relatively large proportion of pre-staking. The rewards obtained on the test network may need to be pledged, and miners who do not have coins need to invest again.

Post-staking leads to uncertain back-end income, which means that miners can only obtain all issued rewards after completing all storage contracts. There may be a freezing period or linear release of income, which has a great impact on investment income.

image description

(initial parameter setting)

According to the official initial pledge function: equivalent to 20 days of block rewards + 30% of Fil's circulating supply.

Therefore, the investment cost of early mining can be calculated: assuming that the current cost of increasing 1T computing power is 800 yuan, 32 FILs need to be pledged. Assuming that the first day is the same as the growth rate of the space race and the block rewards of 10PB daily growth computing power, combined with the above simple supply and baseline supply formulas, it can be calculated that the expected 20-day profit mortgage is 354,954 FIL, 10PB full network computing power To convert a single T, about 34.7 FILs need to be mortgaged.

Miners need to invest more than 6 times the cost of tokens on the basis of the cost of the mining machine.

secondary title

2. Technical risks of mining with mining machines

If you use the officially announced hardware reference solution, the efficiency and benefits are relatively low.

There may be network interruption or delay, and the space-time proof submitted by the network cannot be completed. At the same time, the "storage power" will also be affected. Therefore, the requirements for the network environment and power stability are relatively strict.

secondary title

3. How to avoid

①Choose a mining machine solution with transparent information

At present, some teams are optimizing and upgrading the official hardware solutions, and the transparency of the solutions is getting higher and higher. It is necessary to understand the brand parameters and other information used by each hardware, and conduct detailed price comparisons in the market to prevent excessive hardware premiums.

And a transparent solution can reduce the probability of buying some second-hand hardware, which may lead to hardware damage.

②The background of the company

It is necessary to conduct a detailed investigation on the sellers of mining machines. The most important inspection points for selecting mining machines/miners are the degree of information disclosure and the reliability of manufacturers. This requires a detailed understanding of the hardware, software systems and operation and maintenance of the entire mining process IDC computer room.

③Separation of software and hardware

星球君的朋友们
作者文库