How to Install an IPFS Node on a Virtual Private Server

in #onelovedtube6 years ago (edited)

IPFS is a peer to peer file sharing network similar to torrents. The software can create a decentralized network boosting speed and redundancy with multiple nodes. Decentralized networks also reduce bandwidth costs for the end content provider. The protocol is currently used by websites like, Dlive, Dsound, and Dtube. While it is still under development, you can still install and test it out for yourself if you would like.

I recommend using a minimum of 2gb ram. Their are many paid hosting options, or you can host the files on your own connection and hardware. I recommend having a minimum of 10mbps upload for IPFS. One popular host within the steem community is Privex, they have been active supporters of steem by running nodes. Some other budget options are Digital Ocean, OVH, and Kimsufi. These providers start around $2.50 USD per month, giving 10gb of disk space and 2TB of traffic.

You will need a terminal emulator if you are on windows like Putty to make the connection to the server. I used Ubuntu 14.04 for the operating system.


sudo apt-get update

sudo apt-get install golang-go -y

wget https://dist.ipfs.io/go-ipfs/v0.4.14/go-ipfs_v0.4.14_linux-386.tar.gz

tar xvfz go-ipfs_v0.4.14_linux-386.tar.gz

sudo mv go-ipfs/ipfs /usr/local/bin/ipfs

sudo adduser ipfs
su ipfs

ipfs init

ipfs config --json Discovery.MDNS.Enabled false

ipfs config --json Swarm.AddrFilters '[
"/ip4/10.0.0.0/ipcidr/8",
"/ip4/100.64.0.0/ipcidr/10",
"/ip4/169.254.0.0/ipcidr/16",
"/ip4/172.16.0.0/ipcidr/12",
"/ip4/192.0.0.0/ipcidr/24",
"/ip4/192.0.0.0/ipcidr/29",
"/ip4/192.0.0.8/ipcidr/32",
"/ip4/192.0.0.170/ipcidr/32",
"/ip4/192.0.0.171/ipcidr/32",
"/ip4/192.0.2.0/ipcidr/24",
"/ip4/192.168.0.0/ipcidr/16",
"/ip4/198.18.0.0/ipcidr/15",
"/ip4/198.51.100.0/ipcidr/24",
"/ip4/203.0.113.0/ipcidr/24",
"/ip4/240.0.0.0/ipcidr/4"
]'

<- edit config file in located in "/.ipfs" and change strategy to "pinned" as and change "10gb" to how much space you want the node to consume.
unknown.png
< start ipfs
ipfs daemon &

<- Log in to the root account and run the command below if you would like to run ipfs during boot.

sed -i -e '$i /bin/su ipfs -c "/usr/local/bin/ipfs daemon &"\n' /etc/rc.local

Useful commands:

< add a file on ipfs network
ipfs get hash
< pin a file to keep it on the server
ipfs pin add hash
< update the operating system
sudo apt-get update
sudo apt-get upgrade
< full list of ipfs commands
https://ipfs.io/docs/commands/
< guide for vps by ipfs https://ipfs.io/blog/22-run-ipfs-on-a-vps/
< in case you do an upgrade on ipfs and need to migrate
https://github.com/ipfs/fs-repo-migrations/blob/master/run.md
< show disk space
df -h
< show running processes and memory use
top
< check ipfs bandwidth usage
ipfs stats bw
< tool to pin dtube links
https://github.com/johnn3y/ipfs-pin-steem
< video resources

IPFS install on Mac

IPFS install on Windows

Sort:  

🚀 This is a stellar post! 🚀

I will be featuring it in my weekly #technology and #science curation post for the @minnowsupport project and the Creators' Guild! The @creatorsguild is a new group of Steem bloggers and content creators looking to improve the overall quality of their niche.

If you wish not to be featured in the curation post this Saturday, please let me know. Keep up the hard work, and I hope to see you at the Creators' Guild!


Also, if you have a free witness vote and like what I am doing for the Steem blockchain it would be an honor to have your vote for my witness server. Either click this SteemConnect link or head over to steemit.com/~witnesses and enter my username it the box at the bottom.

Congratulations! This post has been upvoted from the communal account, @minnowsupport, by Graylan | gray00 from the Minnow Support Project. It's a witness project run by aggroed, ausbitbank, teamsteem, theprophet0, someguy123, neoxian, followbtcnews, and netuoso. The goal is to help Steemit grow by supporting Minnows. Please find us at the Peace, Abundance, and Liberty Network (PALnet) Discord Channel. It's a completely public and open space to all members of the Steemit community who voluntarily choose to be there.

If you would like to delegate to the Minnow Support Project you can do so by clicking on the following links: 50SP, 100SP, 250SP, 500SP, 1000SP, 5000SP.
Be sure to leave at least 50SP undelegated on your account.

Congratulations @gray00! You have completed some achievement on Steemit and have been rewarded with new badge(s) :

Award for the number of comments received

Click on any badge to view your own Board of Honor on SteemitBoard.
For more information about SteemitBoard, click here

If you no longer want to receive notifications, reply to this comment with the word STOP

Upvote this notification to help all Steemit users. Learn why here!

Do not miss the last announcement from @steemitboard!

Coin Marketplace

STEEM 0.20
TRX 0.12
JST 0.029
BTC 60813.09
ETH 3389.90
USDT 1.00
SBD 2.52