6Block Podcast II — Core Developer Howie Yang on Filecoin Mining

Natalie-6block
6block
Published in
10 min readJun 10, 2020

This Monday 6Block Podcast has a second interview with 6Block core developer Howie Yang on Filecoin mining. Here is the highlight of the interview. You can also listen to the full podcast here.

Filecoin Podcast 2 — Interview with Howie Yang on building the 6Block Filecoin Miner

Hey, this is Kevin, welcome back to the 6Block podcast. Today we are joined by Howie, who is building the 6Block Filecoin miner, which has gotta be a hard problem to solve. Howie, thanks for joining us and welcome to the podcast.

1. Kevin: What is your background, how did you end up falling down the crypto mining “rabbit hole” and how did you get interested in Filecoin mining?

Howie: I didn’t get started with mining in the benign. I started as a smart contract developer. I have started playing with Bitcoin mining a little bit out of curiosity. Now we (6Block) have an opportunity to start Filecoin mining early. We have been working on it for over a month.

2. Kevin: What kind of results are you seeing for testnet phase II so far?

Howie: We are focusing on the stability of software at this stage, to make sure the whole system works and can scale. 6Block is consistently top 10 in mining power, production capacity and storage. But we are not targeting to be №1 miner at the moment, because we are doing small scale testing phase. I believe we will be in an even higher ranking when we feel it’s ready to scale.

3. Kevin: For you, what is the most interesting part of building this Filecoin miner?

Howie: It’s a completely new system. I am interested to learn new projects. It’s exciting to dive into this large system with multiple different parts, the binding part, the proof system, the underlying zero-knowledge proof, and the computation. It covers a wide range of diverse topics. I get to learn a lot of new things. The novelty of it is fun.

4. Kevin: Have you been testing RAM speed, and what are you finding?

Howie: We haven’t been testing Ram speed yet because it’s not that important. Memory is a multi-layered system. The top layer memory is in the CPU. You need to move all the memory into the CPU cache to speed up. The needs to be big enough with enough bandwidth to ship everything into the CPU. As far as we know, the RAM bandwidth is not exhausted. The bottleneck is in the CPU.

5. Kevin: We are pretty close to mainnet launch, but the project team has cautioned about loading up on hardware because the specs may change. If miners are stocking up on generic hardware (CPU, GPU, disk) are they going to be okay?

Howie: It depends. In a midterm of 6 to 18 months, the hardware is pretty much fixed. Although there is some talk about changing the algorithms a couple of weeks ago, now the PL team said they would not change it for the upcoming main net. So we know it will need CPU that has SHA extension and many cores for the sealing process. But for the long term, the team is also saying the current system is a bit wasteful on the CPU, so they would like to have an algorithm that takes advantage of the CPU cores. But that would be a bit further off after the mainnet launch.

There are people stocking Intel CPUs. It could be useful in the long term but not so much in the near future.

6. Kevin: I hear a lot of talk about block rewards for Proof of Spacetime and Proof of Replication but nothing about retrieval mining. Is it possible for you guys to make a miner for retrieval?

Howie: Probably. Some details are coming out about the retrieval market. I am not super familiar with that part? The storage market and the retrieval market have different incentive economics. With the past two testnets, we are mostly playing around the storage market, using random data stress testing the sealing and replication component of the system. As of two weeks ago, there isn’t much code about the retrieval market. So I don’t know much about it. But there will be a whole separate market for retrieval. The retrieval market will essentially act as a CDN. Say the miners are mostly in China, then it will be difficult to access the data from the US. It will have high latency. Then it will require to build some sore of to distribute the market to different parts of the globe. There might be regionalized retrieval markets, so when users are fetching large files, it is more efficient for the retrieval provider to pass the data on to different data centers around the globe. The market will have to incentivize that.

7. Kevin: What is the whole thing with “clusters” in your miner and how does that help with scaling?

Howie: It separates the different computation needs. For sealing, you will need better performance SSD because you will need to read and write a lot of data at a higher speed. After sealing is done, you don’t need that speed. You can store it in traditional hard drive which is safer or internal network storage to store finalized data, which will provide better scalability and reliability and some data redundancy. Before that, you will need raw performance. The cluster is really about different machines serving different needs at different stages and how we coordinate the resources.

8. Kevin: How big does the 6Block Filecoin miner scale, in petabytes, or is there some point where it would be better to run multiple miners?

Howie: For petabytes storage, the current architecture should be ok. But there are some oddities right now and we are not sure whether some of it would be in the mainnet. For example, I think the advantage of diving your storage power into multiple actors shouldn’t exist but it does. There are reliability issues and you won’t want to put all your eggs in one basket. It will be more reliable if you have multiple miners for one petabyte. But there is no theoretical reason why you shouldn't put all things into one miner. There could be operational issues if you scale up. The codebase is so not mature and so much change is possible. Simple because of the uncertainty it is safer to divide it into multiple miners.

9. Kevin: Do you think it is possible for your miner to do sealing faster than the official miner?

Howie: We have done some internal research which we can optimize by 20%. Our tech partners claim to be able to increase the speed 2x with the same amount RAM. It’s quite a bold claim but we think it is possible.

10. Kevin: What is your favorite spinning disk hard drive for Filecoin storage (for petabytes of storage) and why do you like it?

Howie: We are not that obsessed with different drives. We just use really generic stuff. It does not depend on hardware that much. So far the generic hardware works fine, but we will see how it goes in the future. For storage, we are using CEPH, it’s a network object storage similar to S3. Or you can also add an interface to make it work like Amazon block storage service.

11. Kevin: But not RAID (Redundant Array of Inexpensive/Independent Disks), right?

Howie: No, it’s not RAID. It’s a software network storage. You can just attach raw disks in different isolation pods. The failure will be redundant over different storage pods. Each storage pod will have thousands of disks. The redundancy is in the software not the hardware. The system can be configured to have different redundancy requirements. It can be a parity redundancy similar to raid or it could be on the object level similar to S3. The redundancy level is above the individual disk.

12. Kevin: I don’t understand, for computing, you can work on 3 to 4 sectors in parallel, what does that mean?

Howie: This is related to the core. You can encode multiple videos at the same time, with the constraints of how much memory you have. If you have 6 cores and if you want to encode a video, then it will take 1 kilobyte of ram, theoretically you an only encode 2 videos simultaneously even though you have 16 cores. The same problem applies to Filecoin sealing. For the sealing process, a really expensive constraint is not the core. The resource constraint is with the memory. It requires a lot of memory. For each sector, it requires 100 GB of memory. Memory is far more expensive than cores. In some parts of the process, sometimes the cores just sit idle for hours. Out of 64 cores, only 6 will be running because the memory is saturated during that process, which can take 6 hours using the official code or 3 hours with a highly optimized proof system.

13. Kevin: What is the thing most people don’t really appreciate about Filecoin mining?

Howie: I think it’s the complexity of the system, which makes it so different from Bitcoin mining, where the cost analysis is far more straightforward. The basic input of electricity, hardware, operation costs will be standardized. For every unit of input, you will get a standardized hash power. The profitability variation will come from the price fluctuation. But the input components of Filecoin mining are far more complex. There is storage, retrieval, and different incentives for different parts of the systems.

In the testnet, most miners are mining random data or sealing because it could be expensive to retrieve the data from people who actually need the data. If you are an American miner, you want to store Wikipedia. It would be expensive to transfer the data to China. If there is no incentive, miners will prefer to seal random data. So there is a 1:10 incentive between sealing verified data. It makes cost analysis more complicated. It will require incentive design to attract miners to store meaningful data. It makes Filecoin mining more like running an internet business than a commodity business. You need to be useful and valuable to users. Maybe there is an advantage to have a business that supplements the mining part. If you usefully provide a lot of videos for example, then maybe you will have a mining advantage. If you already have a CDN business, maybe you will have a mining advantage on running retrieval. You really need to build a business to have that edge in mining. It can be CDN or a content play.

Currently, most of the mining is an ethereal business you don’t have to be useful to anyone. But with Filecoin it will be different.

14. Kevin: To miners with a tech background, what is so unique about 6Block’s solution?

Howie: The system is quite complex. There are different parts of the system. There are the application part where you need to make the system reliable. And the underlying proof system, where it makes the system economically viable, and there is also the hardware. All these need to integrate into one system efficiently and economically. To have the ability to integrate requires a lot of engineering expertise and different specializations. 6Block is quite special. We have expertise on different tiesrs of the system. We have people who can optimize the proof processes, people who know hardware ad people who can scale the software. The whole stack integration makes 6Block special.

15. Kevin: I heard that 6Block spotted an inflation bug on the Filecoin test net, that’s pretty cool, can you tell us more about it?

Howie: The inflation bug allows you to send money to yourself. If you have 50 Filecoins and you send that to yourself, you can double your balance every time you do that. You are not supposed to be allowed to send money to yourself. In the code, there is a check that checks that the sender and the receiver are different addresses. But the problem is, miners have two addresses. There is the BLS address used for zero-knowledge proof, and a SECP address, which is a normal elliptical encrypted address. This is another way to refer to the same entity. Essentially this loophole allows you to send tokens to yourself using two aliases.

16. Kevin: What cool features would you want the Filecoin team to add?

Howie: There are already a lot of cool features. The PL team is under a lot of pressure. They are burning a lot of midnight oil. They are producing a lot of features and a lot of bugs. In the coming testnet, I would like to see reliability become a feature. If you have played around and tried to deploy the system on scale, you will realize how untested the official testnet is. It is dealing with a lot of data. The smallest sector to work with is 32 GB, which produces 600 GB of derivative data during the sealing process. It’s quite stressful to the system using the official code. You will run into a lot of bottlenecks very quickly. For the internal team to move faster, the team should be working on smaller sectors to make sure the logic works so they be working on 4 Kilobyte sectors. If you just run on 4 KB sectors you will not likely run into bottlenecks. The whole system is sufficient for very small scale testing. It’s not sufficient for petabyte sectors.

17. Kevin: But thanks for burning some midnight oil with us here. How can people learn more about the 6Block Filecoin miner?

Howie: Just go to 6Block dot com and follow us on Twitter at @6block2.

Awesome, thanks again and have a good mining day!

6Block focuses on “Unicorn” projects in the blockchain area, providing solutions for cryptocurrency mining, including highly efficient mining programs, mining pools, hardware, cloud mining, and wallets.

6Block app https://6block.com/en/help/notification/detail/18

6Block Home https://6block.com/en

Twitter https://twitter.com/6block2

Telegram https://t.me/sixblock

Podcast https://www.youtube.com/channel/UCDPDdczcoVNNM-vWFxNT-9w

--

--

Natalie-6block
6block
Writer for

6Block is a mining pools focusing on Handshake and Filecoin.