Presearch Nodes: Set-Up Instructions on Linux VPS
Presearch Nodes: Set-Up Instructions for Linux VPS
Presearch - The Future of Search is a Decentralized Harmonious Loop
Overview
Don't ditch Google just for a vastly superior search experience with Presearch. When you use Presearch you also get paid to search, retain privacy, gain access to the keyword staking (free advertising) platform, and now you can run a search node to earn PRE for processing searches on the decentralized network.
Getting paid in Presearch tokens for your searches is great. But the demand side for Preseach tokens is largely driven by the keyword staking advertising platform. The vision is to create a harmonious loop where users are paid PRE tokens to search and advertisers stake PRE to gain the ad space at the top of search results for staked keywords and phrases.
Right now is a really exciting time for Presearch because the engine is polished up, and the user nodes (currently in closed beta) are about to go live to the public on January 28, 2021.
This project is really coming along. I've seen the test-net for the new engine and it's looking really good. I now much prefer Presearch to google or any other search engine and it still has so much room to develop. Read their vision paper:
https://www.presearch.io/vision.pdf
First thing you may want to do is buy at least 1,000 PRE so that you can stake them to your node to start earning. If you're brand new to Crypto, you can buy PRE directly from Presearch at https://presearch.org/signup?rid=1990186
If you are more experienced using exchanges or already have some cryptocurrency you can head over to KuCoin:
https://www.kucoin.com/ucenter/signup?rcode=8g7w25
...to swap for PRE. Presearch token is an ERC-20 token and runs on the Ethereum blockchain, so you can also use a decentralized swapping service like UniSwap.
Ok, Let's Set-Up Your Node
Step I.) Deploy VPS on Vultr
We're going to run our node on a Virtual Private Server (VPS) using Vultr. Head to Vultr:
https://www.vultr.com/?ref=8777599-6G
Or you can use DigitalOcean. The set-up is the same and their promotion is better right now. I think they are still giving you $100 free credit to play around with when you use this referral link:
https://m.do.co/c/588ca27819d3
Create and verify your account and then we will deploy a Linux Ubuntu VPS. So far the entry level VPS specs seem sufficient to run a presearch node (may need to upgrade later on). You can't use IPV6 as of now so choose cloud compute or high frequency and make sure the server size options aren't IPV6 only. Choose Ubuntu Version 18.04 and server location anywhere you think you'll get the most presearch traffic.
Step II.) Connecting your Vultr VPS to Putty via SSH
This unrelated video has basic instructions for connecting your VPS to Putty. Follow only the steps in this video which relate to installing Putty. Ignore all the Idena stuff:
You should now have Putty installed and linked to your VPS. Login to your VPS using Putty, the default username from your Vultr VPS is root and the password and ip are also listed in the server details section of Vultr. You're going to be doing a lot of copy-pasting in and out of Putty. If you are new to this, it's important to know that passwords in Linux do not display on screen for security. Also, in Putty, you can simply right-click to paste... VERY convenient, especially when running multiple nodes and using multiple Putty connections simultaneously.
Step III.) Run commands in Putty to install Docker and configure Linux VPS to run your node
You will have to make sure to hit enter after each command if it doesn't auto run. There's no harm in tapping enter/return a few times after commands to add some lines breaks between commands. It just helps break up the scripts to more easily identify any potential issues. Also, there will be a couple of Y/N prompts, answer Y to all.
1.
sudo apt update
2.
sudo apt upgrade
3.
sudo apt-get remove docker docker-engine docker.io containerd runc
4.
sudo apt-get update
5.
sudo apt-get install \ apt-transport-https \ ca-certificates \ curl \ gnupg-agent \ software-properties-common
6.
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
7.
sudo apt-key fingerprint 0EBFCD88
8.
sudo add-apt-repository \
"deb [arch=amd64] https://download.docker.com/linux/ubuntu \
$(lsb_release -cs) \stable"
9.
sudo apt-get update
10.
sudo apt-get install docker-ce docker-ce-cli containerd.io
11.
sudo docker run hello-world
If you had any problems above, consult docker installation instructions https://docs.docker.com/get-docker/ and join the Presearch Nodes telegram channel:
Step IV.) Run commands in Putty to Run Presearch Node on your VPS
For this next step, you’ll need to grab your registration code from nodes.presearch.org/dashboard in order to initialize your node.
Replace your code where it says, "YOUR_CODE_HERE"
1.
Install the new Presearch Node Auto-Updater service (it uses a third party app called Watchtower to auto-update the presearch-node when updates are published) This configures your system to automatically check for updates every 5 minutes (300 seconds).
docker run -d --name presearch-auto-updater --restart=unless-stopped -v /var/run/docker.sock:/var/run/docker.sock containrrr/watchtower --interval 300 presearch-node
2.
Pull Node
docker pull presearch/node
3.
Install the Presearch Node as a service, so it is always running on your computer (no need to manually start/stop anymore). This configures your node to always run as a service (even after system restart) unless you manually stop it (MAKE SURE TO REPLACE WITH YOUR REGISTRATION CODE).
docker run -dt --name presearch-node --restart=unless-stopped -v presearch-node-storage:/app/node -e REGISTRATION_CODE=YOUR_CODE_HERE presearch/node
Step V.) Check Node Status & Useful Commands
1.
If you would like to see the output from your node at any point, just run the following command. You can close the window at any point and your node will keep running:
docker logs -f presearch-node
2.
Other Useful Commands
System Reboot:
sudo reboot
If you have previously run a presearch node, run the following commands to stop the node:
docker stop presearch-node
docker rm presearch-node
If you've ever run the auto-updater, you can stop it too using similar commands:
docker stop presearch-auto-updater
docker rm presearch-auto-updater
This script checks to see if the auto-updater is installed. 1 = installed, 0 = not installed
docker ps | grep presearch-auto-updater | wc -l
The following script (Mac/Linux only) will return a "1" if the node is running and a "0" if it is not.
You could put this in another script to trigger conditional logic based upon that if you wanted:
docker ps | grep presearch-node | wc -l
Check Node Status:
docker ps
docker logs presearch-node
For additional information check out these notes from a Presearch community members:
https://nodeninja.org/knowledge-base/pre/
https://presearch.gitbook.io/presearch-onboarding/
Summary
You should now have a node running on the Presearch network! Refresh the page at
https://nodes.presearch.org/dashboard
See if you're connected over there and stake your node from that page. Run your node, stake PRE to keywords to run ads (essentially free advertising to enthusiastic crypto audience), or just get paid PRE to search. Make your default search provider on Brave Browser and you are double earning BAT and PRE while you browse.
Can't say enough good things about the team as well. They have been super helpful during the closed beta. Get involved everyone! This project is a winner for decentralization and has huge potential to disrupt big tech monopolies & search suppression.
At the time of this writing development is still ongoing so everything here is subject to change or update. It's best to join the Presearch Nodes telegram group, I'll see you over there.
Thank you for your interest in Presearch!
- r0bs0l33t
UPDATES.
Important updates since writing this:
If your node disconnects or if you have to manually stop your node, you can use this one-line command to relaunch everything. Basically try this any time something breaks (make sure to replace your registration code where it says, YOUR_REGISTRATION_CODE_HERE)
One Line Command:
docker stop presearch-node ; docker rm presearch-node ; docker stop presearch-auto-updater ; docker rm presearch-auto-updater ; docker run -d --name presearch-auto-updater --restart=unless-stopped -v /var/run/docker.sock:/var/run/docker.sock containrrr/watchtower --cleanup --interval 300 presearch-node ; docker pull presearch/node ; docker run -dt --name presearch-node --restart=unless-stopped -v presearch-node-storage:/app/node -e REGISTRATION_CODE=YOUR_REGISTRATION_CODE_HERE presearch/node ; docker logs -f presearch-node
If you have previously run a node during the early part of the node beta phase, you may need to run this command to cleanup old docker images that may be taking up precious HD space:
docker image prune -f
Thanks!
Hope that helps! I ended up doing this process like 15 times, so I thought writing it up would be helpful for me in the future. But Brad's nodes are better organized, more technical, and will be more useful going forward for debugging and troubleshooting.
https://nodeninja.org/knowledge-base/pre/