Cryptocurrency Mining Setup and Notes

From myWiki
Revision as of 15:26, 10 February 2020 by Stevet (talk | contribs)

Setup Ubuntu Server 16.04.3

Ethereum (geth)

sudo add-apt-repository ppa:ethereum/ethereum -y
sudo apt update
sudo apt install ethereum -y

Import ethereum key or create new account

geth account list

Uninstall AMDGPU Graphics stack

# Use this for Pro components
$ sudo amdgpu-pro-uninstall

AMDGPU-PRO 17.50-511655 (--compute has been deprecated)

tar -Jxvf amdgpu-pro-19.50-NNNNNN.tar.xz
cd amdgpu-pro-19.50-NNNNNN
sudo ./amdgpu-pro-install -y --opencl=pal,legacy --headless
sudo apt install mesa-common-dev
sudo apt install clinfo

Notes:

boot to onboard VGA first

cli: don't start GUI in headless (server) setup

sudo systemctl set-default multi-user.target

Make user part of video user group

sudo usermod -a -G video <userid>

Static IP Edit /etc/network/interfaces assuming enp4s0 is the ethernet interface id.

auto enp4s0
iface enp4s0 inet static 
  address 192.168.0.x
  netmask 255.255.255.0
  network 192.168.0.0
  broadcast 192.168.0.255
  gateway 192.168.0.1
  dns-nameservers 192.168.0.1 8.8.8.8 8.8.4.4

If the hostname is modified, update /etc/hostname & /etc/hosts

Problems with DHCP timeout, edit /etc/dhcp/dhcpclient.conf

timeout 15 #from 300

Ethminer

git repository download

Zcash

website

Mining

ethermine.org (ethereum & zcash)

Screen

screen    (start)
<ctl>-a d (exit) 
screen -r (reconnect)

Change default gateway temporarily

sudo ip route change default via 192.168.1.1 dev <interface>

Create the file /etc/udev/rules.d/70-persistent-net.rules with the following content

SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="02:01:02:03:04:05", ATTR{dev_id}=="0x0", ATTR{type}=="1", NAME="eth0"