filmov
tv
How-to: Bitcoin Full Node on Ubuntu 22.04

Показать описание
In this video, I talk about how to install and configure a Bitcoin full node using a snap on Ubuntu 22.04.
One important thing I left out of the video is you need to go onto your Internet router and port forward tcp/8333 to your node to allow inbound Bitcoin node connections.
*** Since I recorded the video I've made some tweaks to the log rotation so the below doesn't exactly match the video. ***
The basic steps are:
= Prep OS and install bitcoin core software
sudo su
apt update
apt upgrade
snap install bitcoin-core
= Create an account to run Bitcoin core in even more isolation from the rest of the system
groupadd btc
useradd -g btc -m -s /bin/bash btc
su - btc
= Do a test run:
== If no errors then after 30s:
ctrl-c
= Create the configuration file:
cd ~/snap/bitcoin-core/common
mkdir .bitcoin
externalip=121.98.x.x
externalip=2404:4408:x:x::x
listenonion=0
disablewallet=1
dbcache=2048
= If you created a config file then do another test run:
== If no errors then after 30s:
ctrl-c
= Now setup to run as a daemon:
== Become root again:
exit
[Unit]
Description=Bitcoin daemon
[Service]
User=btc
Group=btc
Type=forking
KillMode=process
Restart=always
TimeoutSec=120
RestartSec=30
[Install]
== Enable and start service
systemctl daemon-reload
= Setup log rotation of debug log
vi /etc/logrotate.d/bitcoind
{
su btc btc
missingok
notifempty
compress
delaycompress
sharedscripts
copytruncate
}
== Check logrotation service is correctly configured
= Check Bitcoin Daemon
su - btc
= This shows disk space used - should grow to begin with, currently 450GB "all up" for me
du -h ~/snap/bitcoin-core/common/.bitcoin/
#bitcoin #ubuntu #howto
Video Content
00:00 Intro
00:11 Why run a Bitcoin full node?
00:51 Requirements
02:22 CPU Load
02:34 Initial setup prep
04:06 Setup separate user to run software
04:32 Initial test run
04:52 Creating a config file
07:28 Create a systemd service
09:39 Setting up log rotation
11:15 Checks and troubleshooting
One important thing I left out of the video is you need to go onto your Internet router and port forward tcp/8333 to your node to allow inbound Bitcoin node connections.
*** Since I recorded the video I've made some tweaks to the log rotation so the below doesn't exactly match the video. ***
The basic steps are:
= Prep OS and install bitcoin core software
sudo su
apt update
apt upgrade
snap install bitcoin-core
= Create an account to run Bitcoin core in even more isolation from the rest of the system
groupadd btc
useradd -g btc -m -s /bin/bash btc
su - btc
= Do a test run:
== If no errors then after 30s:
ctrl-c
= Create the configuration file:
cd ~/snap/bitcoin-core/common
mkdir .bitcoin
externalip=121.98.x.x
externalip=2404:4408:x:x::x
listenonion=0
disablewallet=1
dbcache=2048
= If you created a config file then do another test run:
== If no errors then after 30s:
ctrl-c
= Now setup to run as a daemon:
== Become root again:
exit
[Unit]
Description=Bitcoin daemon
[Service]
User=btc
Group=btc
Type=forking
KillMode=process
Restart=always
TimeoutSec=120
RestartSec=30
[Install]
== Enable and start service
systemctl daemon-reload
= Setup log rotation of debug log
vi /etc/logrotate.d/bitcoind
{
su btc btc
missingok
notifempty
compress
delaycompress
sharedscripts
copytruncate
}
== Check logrotation service is correctly configured
= Check Bitcoin Daemon
su - btc
= This shows disk space used - should grow to begin with, currently 450GB "all up" for me
du -h ~/snap/bitcoin-core/common/.bitcoin/
#bitcoin #ubuntu #howto
Video Content
00:00 Intro
00:11 Why run a Bitcoin full node?
00:51 Requirements
02:22 CPU Load
02:34 Initial setup prep
04:06 Setup separate user to run software
04:32 Initial test run
04:52 Creating a config file
07:28 Create a systemd service
09:39 Setting up log rotation
11:15 Checks and troubleshooting
Комментарии