A Chia Harvest is a computer that farms Chia and connects back to a Master Node. You can almost think of it like the Master Node being a Pool and the harvesters as nodes on that “pool”. In this post we’ll talk about setting up a Chia Harvester on Ubuntu. Shouldn’t matter which version of Ubuntu. LTS or the latest should work fine.
Note: In the following commands we are assuming that the Chia directory is in your home “~/” directory on the harvester. Change the path if different.
Before we start you will need the ca directory from your Main/Master node uploaded or accessible to your Ubuntu harvester. You can get the CA directory from the following locations on Windows and Linux.
On Linux
~/.chia/mainnet/config/ssl/ca
On Windows
C:\User\username\.chia\mainnet\config\ssl\ca
You should be able to copy and paste the following path into Explorer to get to the correct directory.
%homepath%\.chia\mainnet\config\ssl\ca
Copy Chia ca directory
Copy this folder onto your Desktop, thumbdrive, network share, just some place you can access it.
Upload ca folder
You can use scp to upload the ca folder of the Harvester. In the following example we put the ca directory on our Windows desktop and we are uploading to our harvesters home directory.
scp -r Desktop\causer@192.168.1.5:~/
Activate Chia
The rest of the commands are run on the harvester. You can either ssh or physically log into it. If Chia was installed in a different directory, then you will need to change the path.
cd chia-blockchain . ./activate
Configure Harvester
You should be able to copy and paste all the following commands in, change the parts in bold as needed.
The –set-farmer-peer option is your main node’s ip address.
Should be all set. You can check the Main Node to verify that the harvester is connecting.
Important Notes: UPNP needs to be turned off. It can cause problems if there are multiple wallets running on a local network that both have upnp on.
Add your plot drive locations. We need something to harvest :)
Verify that the Linux user can write to the Chia Plot drives
The following command will give the ubuntu user write access to the drive. Change the path to your drive.
sudo chmod ugo+wx /media/username/your_drive
Creating Plots
Create plots by specifying the Farmer Public Key and the Pool Public Key. You can get these from the Main Node. Plan on adding info on how to retrieve that info soon.
Chia is a new kinda of Crypto Currency that instead of using PoW (Proof of Work) it uses Proof of Space and Time which ends up using hard drive space to “mine” farm.
Install Chia Blockchain
You can copy and paste all of these commands in a terminal.
The . ./activate command is needed to be able to run the chia commands. I believe it sources into the current shell so the commands work correctly.
Install Chia Blockchain Gui
After you have run the above commands, do the following to install the Chia Gui
chmod +x ./install-gui.sh ./install-gui.sh cd chia-blockchain-gui npm run electron &
Launching Gui after it is installed
In the future for launching the Gui you should be able to copy and paste the following commands in.
cd chia-blockchain . ./activate cd chia-blockchain-gui npm run electron &
You can also put all of the above commands into a bash shell script and then just run the script instead of having to run the commands all over again every time you want to launch the gui.
Fortunately, installing the NVIDIA drivers on Ubuntu is easy. Fire up a terminal and paste in the following command. There is a little bit of human interaction, but it is fairly straight forward.
If you are in recovery mode on Fedora, add –no-dbus right after the snapper command. e.g.
snapper --no-dbus list
You can use the diff command to list the changes that happened between snapshots.
snapper --no-dbus diff 108..109
And to undo a change or all the changes between a snapshot, do the following. Where 108..109 are all the changes you want to remove. So essentially going back to snapshot 108.
On Ubuntu and potentially other Debian based distributions, you can check the available versions of a package with the apt show command
apt show -a
Example showing firefox versions
~$ apt show -a firefox
Package: firefox
Version: 87.0+build3-0ubuntu0.20.04.2
Priority: optional
Section: web
Origin: Ubuntu
Maintainer: Ubuntu Mozilla Team <ubuntu-mozillateam@lists.ubuntu.com>
..................
More information
..................
Package: firefox
Version: 75.0+build3-0ubuntu1
Priority: optional
Section: web
Origin: Ubuntu
Maintainer: Ubuntu Mozilla Team <ubuntu-mozillateam@lists.ubuntu.com>
Bugs: https://bugs.launchpad.net/ubuntu/+filebug
..................
To install a specific version, use the version number
For some reason you can sometimes have this white bar appear on Windows File Explorer. Fortunately it is an easy fix. Launch Internet Explorer, Yes IE, some of the configuration settings affect both Internet Explorer and Windows File Explorer.
Right click on the Title bar and check the box on Lock the toolbars.
Lock the toolbars to get rid of white bar in Windows File Explorer
Close any open File Explorer windows and relaunch it. It should now be gone.
Apparently on some versions of Java checking the Java version will give you the following error.
root@local:~# java -v
Unrecognized option: -v
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
root@local:~#
The issue being the -v or –version options are not recognized. On newer versions of Java it is recognized.
The proper way to do it is -version with only one dash
root@local:~# java -version openjdk version "1.8.0_252" OpenJDK Runtime Environment (build 1.8.0_252-8u252-b09-1ubuntu1-b09) OpenJDK 64-Bit Server VM (build 25.252-b09, mixed mode) root@local:~#