Tag Archives: centos

Uninstall go-ethereum on Centos 7 / Linux

To uninstall go-ethereum

run the following, first start by deleting the huge blockchain off your server:

geth removedb


[root@base go-ethereum]# geth removedb
Remove this database? [y/N] y
Remove this database? [y/N] y


Delete the Data Directory

  • Mac: ~/Library/Ethereum
  • Linux: ~/.ethereum
  • Windows: %APPDATA%\Ethereum

Make sure you delete it recursively! Meaning make sure the keystore folder under ~/.ethereum is deleted as well so your wallet data is deleted so no one can steal. Likewise make sure you have backup of it on your local machine to receive and transfer funds.

Next let’s delete the previous symbolic link we made during installation
Here is my previous symbolic link:
ln -s /go-ethereum/build/bin/geth /usr/local/bin/geth

First unlink it:

unlink /usr/local/bin/geth


Then delete the rest of the installation here:

rm -rf /go-ethereum



How to Mine Ethereum on centOS 7

Mining on centos7 seems to be a labor and existing guides are outdated or hard to find. Here is one updated and written for our times. Keep in mind, using this will consume 10s of GB of disk space, this is because the whole block chain, has to be downloaded.

Make sure you have git installed:
yum install git
git clone https://github.com/ethereum/go-ethereum
cd go-ethereum
make geth
The full command to start geth will look something like this
/go-ethereum/build/bin/geth account list

Use a symbolic link so you can use geth without the long filepath
ln -s /go-ethereum/build/bin/geth /usr/local/bin/geth

The command below should now work
geth account list

It will not return any result because you don’t have any accounts created or imported. If you don’t have a ethereum address, then you can create a new one by typing geth account new

If you do have an account already create a new file and paste the unencrypted private key like so as shown below:

Create a new file named “pass”
touch pass

Edit that file, you can use any editor, i use the editor nano
nano pass
paste the unencrypted key, Ctrl+X to save and exit it.

Now have geth import that file with its key
geth account import pass

Now make sure that account is imported:
geth account list

Protect the unencrypted pass file, don’t ever let anyone touch it or lose it
chmod 700 pass
Chmod prevents other users from using it or seeing it.

Then start mining:
geth –mine –minerthreads=2

Now I recommend installing screen and running it in a screen so you can use the terminal for other business or run geth in the background using the & flag.

For screen
yum install screen

Then mine and hold ctrl + A + D, this will detach the screen but keep it open

You can return to that screen session by typing
screen -r

That’s it!