Computer Science/Blockchain

[Blockchain] A Journey with Hyperledger Fabric: Build Test Server

Henry Cho 2024. 8. 29. 07:08
728x90

포스트 난이도: HOO_Senior


# Introduction

I've been grappling with how to explain the general challenges of data flow through blockchain. As someone who struggles with design and visual representation, I know how daunting it can be to convey complex concepts effectively. After a recent seminar, one of students, who’s pursuing a Master of Engineering, mentioned, "I want to start studying blockchain" but he seemed unsure where to begin. I realized that simply pointing people to GitHub, as many developers often do, might not be the most helpful advice, especially for someone just starting out.

 

Therefore, I decided to take the time to delve into blockchain, specifically focusing on Hyperledger Fabric. While I can't promise constant updates, I aim to provide a useful introduction to the topic here. If there’s enough interest and questions, I’ll do my best to continue writing about it.

 

As you know, I’ve categorized the difficulty level of this content as HOO_Middle, though some parts might be more advanced, making it feel more like HOO_Senior—especially for master’s students. I’ll skip over basic explanations of the Hyperledger fabric and blockchain itself.

 

If you need more background information, feel free to leave a comment or reach out through a "방명록".


# Requirements

Let's start with the requirements. Among those who have worked with Hyperledger Fabric, it's common to hear, "What? It doesn't work!"—especially if they dealt with it last year or during its early versions. This often happens because different versions of the tools have been used over time, leading to conflicts. It’s crucial to ensure version compatibility to avoid these issues.

 

The constant updates and variations in the tools used by different developers can cause version mismatches, resulting in frustrating conflicts. It’s like trying to complete a coding task but spending the whole day searching for a missing "Run" button that just isn’t there.

 

To help you avoid these pitfalls, I'd like to introduce the requirements for version 2.5 of Hyperledger Fabric, which I am currently using and testing as of August 2024. If your version of Docker or Fabric differs from this, you can either downgrade or upgrade to match the version.

 

Just to emphasize a point you might already know: if you're using Hyperledger Fabric, it's generally better to run it on a Linux-based system. Although it’s possible to set up a Windows environment and use Docker similarly, Linux tends to be more straightforward. For Mac users, the setup is usually less troublesome, so you can proceed with confidence.


brew --version
Homebrew 2.5.2 or Homebrew 4.3.13

git --version
git version 2.23.0 or git version 2.39.3

curl --version
curl 7.64.1 or curl 8.7.1

docker --version
Docker version 19.03.12 or Docker version 25.0.3

docker-compose --version
docker-compose version 1.27.2 or docker-compose version 2.24.5

go version
go1.22.5 or go1.22.4

 

The requirements mentioned are just the basics. If you’re using a version that falls within the specified range,  you shouldn’t encounter significant issues. However, since I haven’t tested every possible version, I can’t guarantee 100% compatibility. To avoid any potential problems, I recommend using the exact version I’ve tested it.

 


# Installing and Testing Hyperledger Fabric v2.5

https://hyperledger-fabric.readthedocs.io/en/release-2.5/install.html

 

Once you’ve completed the setup, you can install Fabric version 2.5 and test the server by opening and closing it.  The installation and testing process is similar to other versions of Fabric, so it should be straightforward if you follow the guidelines. If you encounter any issues or lack experience with this process, feel free to reach out. I’ll consider creating a new post with detailed instructions for installation and testing.


 

728x90