Deploy Blobber on Own Server

This page offers detailed instructions on deploying a blobber via Chimney on your own server.

Server Configuration

To ensure optimal performance for read and write operations, we recommend using a server with a minimum of 6 CPU cores and 500GB of SSD storage. This configuration will help improve your blobber's rank, increasing its chances of hosting an allocation.

Instructions

  1. 1.
    Upon registration, you have two options for setting up a blobber: you can either rent a server for your blobber or deploy it on your own server. In this guide, we will focus on deploying a blobber on your own storage server. Please proceed to Step 2: "Deploy in Chimney App" and refer to the screenshot below:
Note: For instructions on deploying a blobber on a rented server, refer to the "Deploy Blobber on Rented Server" section. Deploy Blobber on Rented Server.
  1. 2.
    Provide your server specifications, including the amount of space you wish to rent, read and write prices, provider name and password, staking settings, and click on "Deploy Your Blobber."
Here are descriptions of the blobber specification terms:
  • Storage Capacity: The amount of storage capacity you intend to offer.
  • Write Price: The price you charge for write operations.
  • Read Price: The price you charge for read operations.
  • Self Stake: This represents the ZCN you plan to stake on your own server. A higher self-stake is recommended; we suggest allocating at least 20% of your total stake to self-staking.
  • Min Stake per Delegate: This is the minimum stake you allow from any delegate staking on your server.
  • Max Stake Per Delegate: This is the maximum stake you allow from any delegate staking on your server.
  • Service Charge: This is the commission percentage you request from delegates staking on your server.
  1. 3.
    Provide the IP address or domain of the server on which you want to deploy the blobber via the chimney script. To request a script, click on "Create," fund server wallets, and generate the script.
Note: Note: In the Domain section, you can enter either an existing domain or provide the public IP of the server. We will add a DNS entry for your IP address. If you wish to use your own domain, ensure that the DNS entry is pointed to the IP address or your VM. This domain will be used to generate TLS certificates for secure communication with the blobber.
  1. 4.
    Upon request, you will receive a script. Here is a sample script for reference:
Here is a sample script for reference :
curl -fSsL https://raw.githubusercontent.com/0chain/blobber/setup-new-blobber/docker.local/quick_blobbers.sh | sed 's/0chainreadPrice/0.7/; \
s/0chainwritePrice/1.4/; \
s/0chainminStake/500/; \
s/0chainmaxStake/2000/; \
s/0chainserviceCharge/1/; \
s/0chainclientId/ff341191908b0c0703a7be47fc1533af6e8b2617c1356fcca3eb2d3d0852b1d0/;
s/0chaingfadminuser/manohar/; s/0chaingfadminpassword/reddy/;
s/0chainblockworker/https:\/\/demo.zus.network\/dns\//;
s/0chainblobberhost/chimneyvz3de.devnet-0chain.net/;'
All the details mentioned, such as read_price, write_price, and delegate wallet ID, are passed as parameters to the script. Note that a domain has also been provisioned.
Note 1: Your wallet ID will serve as a delegate wallet ID to receive rewards.
Note 2: You can update your read_price, write_price, and other configurations later, but be cautious as changes to read_price and write_price may affect your blobber's ranking
  1. 5.
    To run the script on your storage server, follow these steps:
    a) Open terminal:
    • On Windows: Press Windows + r and type "cmd."
    • On Mac: Press Command + Space Bar and type in 'Terminal.'
    • On Linux: Press Ctrl + Alt + T.
    b) SSH into your server by typing 'ssh [email protected]' and press Enter.
    c) Click on the COPY icon to copy the script and paste it into your terminal. The copy button is highlighted in the screenshot below.
d) Press Enter to execute the script on your server. A screenshot demonstrating the successful execution of the script is provided.
Note: During chimney deployment, if there are any pre-existing blobber deployments on the server, running a new script in chimney will permanently prune (erase) the data associated with the previous chimney deployment.
  1. 11.
    Once the script is executed successfully, click the 'I have run the script' button to establish communication with your server. The button is highlighted in the screenshot below.
  1. 12.
    The application will redirect you to the chimney dashboard, where you can view and manage your deployed blobber. Here is an overview of the dashboard.

Disabling root access:

To disable ssh from root access add this line to the ~/.ssh/authorized_keys file.
no-port-forwarding,no-agent-forwarding,no-X11-forwarding,command="echo 'Please login as the user \"ubuntu\" rather than the user \"root\".';echo;sleep 10;exit 142"

Disabling IPMI access:

IPMI provides a powerful out-of-band management interface that can be used to remotely manage and monitor the server hardware. However, as with any powerful management interface, there is a risk that it could be abused or exploited by attackers to gain unauthorised access to the server or its data.
Disabling IPMI may reduce this risk by limiting the attack surface of the server. Without IPMI enabled, attackers would need to rely on other attack vectors, such as exploiting vulnerabilities in the operating system or application software, in order to gain access to the server.
To disable IPMI access on a rented server, ipmitool can be used. You can use the following command:
ipmitool lan set 1 ipsrc dhcp
This command sets the IP address source for the IPMI LAN interface to DHCP, effectively disabling the IPMI interface. Note that this command assumes that the IPMI LAN interface is on channel 1. If your IPMI interface is on a different channel, you will need to adjust the command accordingly.

Updates to the Blobber Image version:

To manage updates to the containers an open source agent called watchtower is installed as a part of blobber deployment. This agent automatically pulls the latest version of blobber as and when they are released.