🚀 From Zero to Blockchain: Installing Hyperledger Fabric on Ubuntu with Docker and VirtualBox
Ready to dive into the world of enterprise blockchain? This guide will walk you through setting up a complete Hyperledger Fabric development environment from scratch. We'll use VirtualBox to create a virtual machine, install Ubuntu Server, and then use Docker to get Hyperledger Fabric up and running. Let's get started!
Step 1: Gather Your Tools 🛠️
Before we begin, you need to download two key pieces of software:
Oracle VirtualBox: This is the virtualization software that will host our Ubuntu operating system.
Download here:
https://www.virtualbox.org/wiki/Downloads
Ubuntu Server 24.04 LTS: We're using the Long-Term Support version for stability. The server version is lightweight and perfect for this setup.
Download here:
https://ubuntu.com/download/alternative-downloads
Step 2: Create and Configure Your Virtual Machine (VM)
Once VirtualBox is installed, it's time to create the home for our Fabric network.
Create a New VM: Open VirtualBox and click "New".
Name and OS: Give your VM a name (e.g., "Fabric-Dev-Node") and select "Linux" as the Type and "Ubuntu (64-bit)" as the Version.
Allocate Resources: This is important! To run Fabric smoothly, you need to give your VM enough power.
Minimum: 4 GB RAM / 2 CPUs / storage 25 GB
Recommended: 5 GB+ RAM / 4 CPUs / Storage 40GB
Create a Virtual Hard Disk: A dynamically allocated disk of about 25-30 GB should be plenty to start.
Mount the Ubuntu ISO: In the VM settings under "Storage," select the empty optical drive and choose the Ubuntu Server
.iso
file you downloaded. This is like inserting the installation CD.
Step 3: Install Ubuntu Server 🐧
Now, start your new VM! The Ubuntu Server installer will launch. Follow the on-screen instructions. The process is straightforward:
Choose your language and keyboard layout.
Stick with the default network settings.
Use the entire disk for the installation.
Set up your username and password.
Important: When prompted, make sure to install the OpenSSH server so you can easily connect to your VM.
Let the installation complete and then reboot. Remember to "remove" the virtual installation disk when prompted
Step 4: Standalone installation
Now, start with the following script below save it as install.sh and do chmod +x change to root and execute
issues identified while using samples:
/root/go/src/github.com/hyperledger/fabric-samples/asset-transfer-basic/chaincode-go/go.mod:3: invalid go version '1.23.0
in this file
1.23
Comments
Post a Comment