Author

Topic: How to update Bitcoin Core from 0.18.0.0 on Pi3 (ubuntu) (Read 250 times)

legendary
Activity: 2870
Merit: 7490
Crypto Swap Exchange
I just realize size of /boot partition is very small, usually it should be around 250-500MB.

it shouldn't be this complicated to get the latest bitcoin core from Ubuntu packages.

I agree, in my case, 3 command is enough. Perhaps the fact OP have installed Bitcoin from snap and another repository complicate things.
legendary
Activity: 2870
Merit: 7490
Crypto Swap Exchange
--snip--
I guess /dev/mmcblk0p1 needs more room? Shame the upgrade process doesn't offer to do this.
Anyone know how to increase the size of /dev/mmcblk0p1?

There are many tools such as gparted to increase size of a partition or manage partition. Be very careful since you might break your partition easily.

On a side note, have you tried what i did or follow guide from output of sudo do-release-upgrade ?
legendary
Activity: 1568
Merit: 6660
bitcoincleanup.com / bitmixlist.org
~

Now that we have your OS version (16.04 LTS) and your CPU architecture (armhf), I think I know why you can't seem to get the latest Bitcoin core.

At bitcoin-0.20.1 package listing from Luke-jr's PPA, we have these build results: https://launchpad.net/~luke-jr/+archive/ubuntu/bitcoincore/+packages



The problem here, is that bitcoin-0.20.1 failed to build on Xenial and armhf combination, so there is no bitcoin package for those system. That is why when you tried to install bitcoin with `sudo apt-get install bitcoin`, it said it couldn't find any package with that name. Because there isn't one that exists for your system.

There is a working bitcoin package with 18.04 LTS and armhf architecture and also for 20.04 LTS /armhf. LTS versions can only upgrade to newer LTS versions anyway, so the other releases like 19.04 and 19.10 can't be used.

There's no space left on your boot mount, so it's impossible to upgrade to a newer version. So instead you should download it from bitcoincore.org like DaveF mentioned.

I just realize size of /boot partition is very small, usually it should be around 250-500MB.

OP is running on a Raspberry Pi so I'm guessing threre is limited storage space on them, and 500MB can easily fit 7 or 8 kernels so it makes sense why they wanted to reduce that space to allocate to other partitions.
member
Activity: 131
Merit: 29
Code:
lsb_release -a
returns:
Code:
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 16.04.7 LTS
Release:        16.04
Codename:       xenial
legendary
Activity: 1568
Merit: 6660
bitcoincleanup.com / bitmixlist.org
I tried
Code:
sudo apt autoremove
which didn't free up any space, and I didn't bother with compressing anything.

I'll try gparted.

Actually wait, before you do that, I noticed there is no unallocated space on your disk. So to increase the size of /dev/mmcblk0p1 partiton (/boot mount), you have to shrink other partitions to make unallocated space. And even then that space has to be contiguous with the mmcblk0p1 partition.

I recommend against doing this, it's too easy to get this wrong and break your Ubuntu installation, it shouldn't be this complicated to get the latest bitcoin core from Ubuntu packages.

Can you run

Code:
lsb_release -a

and paste the output here so we can see which ubuntu version you're on? If it says command not found, then run apt-get install lsb-release to get it.
member
Activity: 131
Merit: 29
I tried
Code:
sudo apt autoremove
which didn't free up any space, and I didn't bother with compressing anything.

I'll try gparted.
member
Activity: 131
Merit: 29
I ran:
Code:
sudo do-release-upgrade

but it returns:
Code:
Calculating the changes
  MarkInstall libpam-cap [ armhf ] < none -> 1:2.25-1.2 > ( libs ) FU=1

Not enough free disk space

The upgrade has aborted. The upgrade needs a total of 49.5 M free
space on disk '/boot'. Please free at least an additional 5,374 k of
disk space on '/boot'. You can remove old kernels using 'sudo apt
autoremove' and you could also set COMPRESS=xz in
/etc/initramfs-tools/initramfs.conf to reduce the size of your
initramfs.

So I ran:
Code:
df -h
which returns:
Code:
Filesystem      Size  Used Avail Use% Mounted on
/dev/root        15G  6.1G  8.4G  43% /
devtmpfs        483M     0  483M   0% /dev
tmpfs           487M     0  487M   0% /dev/shm
tmpfs           487M   14M  474M   3% /run
tmpfs           5.0M  4.0K  5.0M   1% /run/lock
tmpfs           487M     0  487M   0% /sys/fs/cgroup
/dev/loop1       83M   83M     0 100% /snap/core/9805
/dev/loop0       91M   91M     0 100% /snap/bitcoin-core/83
/dev/loop2       83M   83M     0 100% /snap/core/9995
/dev/mmcblk0p1   63M   21M   43M  34% /boot
/dev/sda1       917G  513G  358G  59% /home/drew/.bitcoin
tmpfs            98M     0   98M   0% /run/user/1000

I guess /dev/mmcblk0p1 needs more room? Shame the upgrade process doesn't offer to do this.
Anyone know how to increase the size of /dev/mmcblk0p1?

Thanks
legendary
Activity: 3472
Merit: 3217
Playbet.io - Crypto Casino and Sportsbook
~snip~

Can you add and post the system information of your device?

If it is running the latest version of ubuntu or older version?

Since the ranochigo suggested above works to you and you've got Bitcoin Core version v0.18.1.0 then try this

Code:
sudo apt-get dist-upgrade

If not then do this next step.

Currently, the latest version of Ubuntu is "Ubuntu 20.10 (Groovy Gorilla)"

Try this(This method is for an old version of Ubuntu but it might work also on the latest version)

- Copy this
Code:
deb http://ppa.launchpad.net/luke-jr/bitcoincore/ubuntu groovy main
deb-src http://ppa.launchpad.net/luke-jr/bitcoincore/ubuntu groovy main
Quote
Step 4: Open a terminal and type:


sudo gedit /etc/apt/sources.list
This will open a text editor containing the list of archives that your system is currently using. Scroll to the bottom of the file and paste the lines you copied in the step above.

Save the file and exit the text editor.

Step 5: Then copy this

Code:
E76343E19921CAF7F6FA2B9F480495056EC244E1

Step 6: Now you need to add that key to your system so Ubuntu can verify the packages from the PPA. In your terminal, enter:


sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys E76343E19921CAF7F6FA2B9F480495056EC244E1
Replace E76343E19921CAF7F6FA2B9F480495056EC244E1 with whatever you copied in the step 5.

This will now pull down the PPA's key and add it to your system.

Important: This is not an endorsement of any of the software in PPAs. You must make sure you trust the PPA owner before installing their software.

Step 7: Now, as a one-off, you should tell your system to pull down the latest list of software from each archive it knows about, including the PPA you just added:


sudo apt-get update
Now you're ready to start installing software from the PPA! If you already have the software installed and you're adding the PPA to get a more recent/different version, you may just need to run:


sudo apt-get dist-upgrade

Just edited some steps above and got the source from here https://help.launchpad.net/Packaging/PPA/InstallingSoftware
And the source.list entries from luke-jr under "Technical details about this PPA" here https://launchpad.net/~luke-jr/+archive/ubuntu/bitcoincore

If it doesn't work and you are using a lower version than "Ubuntu 20.10 (Groovy Gorilla)" try to choose other entries under "Technical details about this PPA" Then repeat the procedure above or you might need to update your Ubuntu to the latest version.
member
Activity: 131
Merit: 29
Hi NotATether, I tried
Code:
sudo add-apt-repository ppa:luke-jr/bitcoincore
sudo apt-get update
sudo apt-get install bitcoin
but the last line returned
Code:
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package bitcoin
I also tried
Code:
sudo apt-get install bitcoincore
with the same result.

Hi ETFbitcoin, yes, I did run sudo apt-get upgrade after I last ran sudo apt-get update.
legendary
Activity: 1568
Merit: 6660
bitcoincleanup.com / bitmixlist.org
What is the version number of Ubuntu that's running on your Pi?

If you are running the arm64 version of Ubuntu there are 0.20.1 releases in Luke-Jr/bitcoin for Xenial, Bionic, and Focal (20.04 LTS). Add the repo like this:

Code:
sudo add-apt-repository ppa:luke-jr/bitcoincore
sudo apt-get update

And then install bitcoin with
Code:
sudo apt-get install bitcoin



The repository included with the Ubuntu is quite outdated.

On my Bionic server there isn't a bitcoin package included the default repos. There's a bitcoin/bitcoin PPA that's out of date and not maintained anymore, there's also one from Luke-Jr (by the way very kind of him to package these builds), there's an official snap package for Bitcoin and there's also the one you get from bitcoincore.org. I wonder why the bitcoin developers haven't pushed an official build to an Ubuntu repo like universe. Has any such effort been made before, and if so what were the problems with getting it in?
member
Activity: 131
Merit: 29
Code:
which bitcoind
returned
Code:
/usr/bin/bitcoind

I say bitcoind because that's what's running and that's what I started.
member
Activity: 131
Merit: 29
Quote
Have you confirmed that Bitcoin Core is from Luke-Jr's repository, not from Snap?
How do I see which of these two I'm running?
legendary
Activity: 3500
Merit: 6320
Crypto Swap Exchange
You can also cheat and just download the binaries from bitcoin.org and use them.
The latest version is here:

wget https://bitcoincore.org/bin/bitcoin-core-0.20.1/bitcoin-0.20.1-arm-linux-gnueabihf.tar.gz

Yes, it's not as automated as just running the install and the link changes with every version but it's not that much more work.
And you don't wind up hunting down some odd issue when it does not install

-Dave
member
Activity: 131
Merit: 29
Interesting - I followed those commands and now I've got Bitcoin Core version v0.18.1.0.
legendary
Activity: 3038
Merit: 4418
Crypto Swap Exchange
The repository included with the Ubuntu is quite outdated.

If you want to use the latest Bitcoin Core, you can use Luke-Jr's repository instead. To add the repo,
Code:
sudo add-apt-repository ppa:luke-jr/bitcoincore
sudo apt-get update
member
Activity: 131
Merit: 29
So I tried sudo apt-get update && apt-get upgrade bitcoind but it thinks that 0.18.0.0 is the latest.

How do I update it to 0.20.0? To be honest I don't really have any need to update it, but I suppose it's best that I do..

---

Slightly off topic - the original reason that I was looking to upgrade to the latest version was because bitcoin-cli commands weren't working, returning:
Quote
error: Could not connect to the server 127.0.0.1:8332 Make sure the bitcoind server is running and that you are connecting to the correct RPC port.
After running sudo snap install bitcoin-core, the bitcoin-cli commands now work, even though it's still running 0.18.0.0 when I start bitcoind.

Thanks
Jump to: