Bitcoin Forum
April 30, 2024, 12:02:30 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: [ TUTORIAL ] Run BITCOIN Server on VPS - BitcoinCLI and BitcoinD  (Read 298 times)
texgeek (OP)
Full Member
***
Offline Offline

Activity: 515
Merit: 202

in BTC we trust!


View Profile
July 25, 2018, 12:47:21 PM
Merited by LeGaulois (1)
 #1

Hello guys, just sharing with you , how setup a bitcoind and bitcoin-cli on a simple ubuntu VPS on a cloud.

Tip: not use windows...,you can use ubuntu on amazon aws, digital ocean, interserver.net, and others cloud VPS.


Ubuntu is better to run, but xubuntu and others debians based you can run also.


*** BTC update and OS and install bitcoind together cli . BTC ***


Open The terminal and execute :


sudo apt-get update
sudo apt-get install build-essential
sudo apt-get install libtool autotools-dev autoconf
sudo apt-get install libssl-dev
sudo apt-get install libboost-all-dev
sudo add-apt-repository ppa:bitcoin/bitcoin
sudo apt-get update
sudo apt-get install bitcoind
mkdir ~/.bitcoin/ && cd ~/.bitcoin/

******* BTC Adding conf using vim BTC *****


vim bitcoind.conf

with vim open, you will using text terminal, follow next steps:

give a space
copy  TEXT* of next lines
execute  SHIFT + I or  SHIFIT + INSERT ( this will paste yor text on vim)
go to first line on vim and remove the extra space, inserted before (normal backspace)
press ESC ,you will see ":" , then yoou press wq after enter
this will save the file


******* BTC Config  btcd TEXT* BTC*******



rpcuser=username
rpcpassword=password
testnet=1
rpcport=8332
rpcallowip=127.0.0.1
rpcallowip=EXTERNAL IP*
server=1



The EXTERNAL IP is your ip address external of your vps, you can found it on yoour control panel of your vps


**** BTC Starting service Bitcoind BTC*****


bitcoind &  

(this comand will run bitcoind )


if you close the terminal (the & unlock execution), you can typing more comands using this letter


bitcoind --daemon

(this command above will run on background, you need choose the first with & or the second with --daemon )


---------

Tip, if you want to know if the process is running ?

run this :
 
ps -e | grep bitcoind

( with one line with PID text show , that is running )

----------

BTC Running bitcoin-cli using your bitcoind BTC


bitcoin-cli getblockchaininfo


if everything is fine you will see something like that :



Remenber the command  getinfo is deprecated.

now you can use these comands , if you have success here, just need run a command to see/use blockchain:

- getblockchaininfo: blocks, difficulty, chain
- getnetworkinfo: version, protocolversion, timeoffset, connections, proxy, relayfee, warnings
- getwalletinfo: balance, keypoololdest, keypoolsize, paytxfee, unlocked_until, walletversion



Anything need just ask
Im am a "normal" developer , and can help with configuration if you need


Running on ubuntu July 2018

open to virtual work
1714478550
Hero Member
*
Offline Offline

Posts: 1714478550

View Profile Personal Message (Offline)

Ignore
1714478550
Reply with quote  #2

1714478550
Report to moderator
1714478550
Hero Member
*
Offline Offline

Posts: 1714478550

View Profile Personal Message (Offline)

Ignore
1714478550
Reply with quote  #2

1714478550
Report to moderator
1714478550
Hero Member
*
Offline Offline

Posts: 1714478550

View Profile Personal Message (Offline)

Ignore
1714478550
Reply with quote  #2

1714478550
Report to moderator
It is a common myth that Bitcoin is ruled by a majority of miners. This is not true. Bitcoin miners "vote" on the ordering of transactions, but that's all they do. They can't vote to change the network rules.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
MrCrank
Sr. Member
****
Offline Offline

Activity: 1336
Merit: 258



View Profile
July 28, 2018, 05:43:35 AM
 #2

Useful information.
It's called Bitcoin full node.
Could you make script for autorun bitcoin daemon after start VPS?
HCP
Legendary
*
Offline Offline

Activity: 2086
Merit: 4316

<insert witty quote here>


View Profile
July 29, 2018, 12:22:17 AM
 #3

Could you make script for autorun bitcoin daemon after start VPS?
You can probably just use cron for this... it has settings that allow you to run commands after startup.

Also, given that a lot of VPS services charge based on the storage/bandwidth being used... running a Bitcoin Node on a VPS could get quite expensive given the current size of the blockchain Tongue

█████████████████████████
████▐██▄█████████████████
████▐██████▄▄▄███████████
████▐████▄█████▄▄████████
████▐█████▀▀▀▀▀███▄██████
████▐███▀████████████████
████▐█████████▄█████▌████
████▐██▌█████▀██████▌████
████▐██████████▀████▌████
█████▀███▄█████▄███▀█████
███████▀█████████▀███████
██████████▀███▀██████████
█████████████████████████
.
BC.GAME
▄▄░░░▄▀▀▄████████
▄▄▄
██████████████
█████░░▄▄▄▄████████
▄▄▄▄▄▄▄▄▄██▄██████▄▄▄▄████
▄███▄█▄▄██████████▄████▄████
███████████████████████████▀███
▀████▄██▄██▄░░░░▄████████████
▀▀▀█████▄▄▄███████████▀██
███████████████████▀██
███████████████████▄██
▄███████████████████▄██
█████████████████████▀██
██████████████████████▄
.
..CASINO....SPORTS....RACING..
█░░░░░░█░░░░░░█
▀███▀░░▀███▀░░▀███▀
▀░▀░░░░▀░▀░░░░▀░▀
░░░░░░░░░░░░
▀██████████
░░░░░███░░░░
░░█░░░███▄█░░░
░░██▌░░███░▀░░██▌
░█░██░░███░░░█░██
░█▀▀▀█▌░███░░█▀▀▀█▌
▄█▄░░░██▄███▄█▄░░▄██▄
▄███▄
░░░░▀██▄▀


▄▄████▄▄
▄███▀▀███▄
██████████
▀███▄░▄██▀
▄▄████▄▄░▀█▀▄██▀▄▄████▄▄
▄███▀▀▀████▄▄██▀▄███▀▀███▄
███████▄▄▀▀████▄▄▀▀███████
▀███▄▄███▀░░░▀▀████▄▄▄███▀
▀▀████▀▀████████▀▀████▀▀
boulderchain
Jr. Member
*
Offline Offline

Activity: 59
Merit: 5


View Profile
July 29, 2018, 01:36:24 PM
 #4

Many people will not be happy about the vim section ;-)
 
 Nevertheless, good tutorial. I would not allow rpc for external ips, instead just connect via ssh and send your commands on the server. In addition it is recommended to allow incoming traffic (for rpc or ssh) only from your ip (if you have a static ip).

★ PRiVCY ➢ Own Your Privacy! ➢ Best privacy crypto-market! ★
✈✈✈[PoW/PoS]✅[Tor]✅[Airdrop]✈✈✈ (https://privcy.io/)
starmyc
Full Member
***
Offline Offline

Activity: 198
Merit: 130

Some random software engineer


View Profile
July 29, 2018, 01:43:27 PM
Merited by HCP (5)
 #5

Could you make script for autorun bitcoin daemon after start VPS?
You can probably just use cron for this... it has settings that allow you to run commands after startup.

The best is still to make use of the provided bitcoind.service file for systemd.

Most likely it is already bundled in the ubuntu's bitcoind package.

As root, the following should work:

Code:
# cp bitcoind.service /lib/systemd/system/bitcoind.service
# systemctl enable bitcoind
# systemctl start bitcoind
# systemctl status bitcoind

It will register it in systemd & making it as a service to start at boot. There is no need of a third party script.

Hi, I'm just some random software engineer.
You can check my projects: Bitcoin & altcoin balances/addresses listing dumps: https://balances.crypto-nerdz.org/
texgeek (OP)
Full Member
***
Offline Offline

Activity: 515
Merit: 202

in BTC we trust!


View Profile
July 31, 2018, 03:11:08 AM
 #6

Useful information.
It's called Bitcoin full node.
Could you make script for autorun bitcoin daemon after start VPS?


I will create a docker image and a shell script to start all node.

Thanks for idea. Smiley

open to virtual work
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!