<p>In my case, it was the disk running out of space (running Ubuntu Server 24.04). I didn't notice, that the root partition only has 100Gb assigned.</p>
<p><strong>If you have the same issue and you run Ubuntu, this was my solution.</strong> ChatCpt helped me here.</p>
<p>Here's how you can increase the size of the LVM partition /dev/mapper/ubuntu--vg-ubuntu--lv using the lvresize command:</p>
<p>Make sure you have a backup of your important data before proceeding.</p>
<p>Boot your Ubuntu system and open a terminal.</p>
<p>Verify the current size of the LV partition using the lvdisplay command:</p>
<p><code>sudo lvdisplay</code></p>
<p>Look for the LV that corresponds to <code>/dev/mapper/ubuntu--vg-ubuntu--lv</code> to check its current size.</p>
<p>To increase the size of the LV, use the lvresize command with the desired new size. For example, to increase it by 5GB:</p>
<p><code>sudo lvresize -L +5G /dev/mapper/ubuntu--vg-ubuntu--lv</code></p>
<p>Adjust the size (+5G in this case) according to your needs.</p>
<p>Now, if the filesystem on the LV is ext4, you can expand it to utilize the additional space using the resize2fs command:</p>
<p><code>sudo resize2fs /dev/mapper/ubuntu--vg-ubuntu--lv</code>
If the filesystem is different, you'll need to use the respective filesystem-specific command to resize it.</p>
<p>With these steps, you should be able to increase the size of the LVM partition (/dev/mapper/ubuntu--vg-ubuntu--lv) correctly. However, always ensure you have backups and exercise caution when modifying partitions and filesystems to prevent any potential data loss.</p>

CC BY-SA 4.0
2024-05-14T06:24:39.167Z
2024-05-14T06:24:39.167Z
codepleb
<p><strong>SOLVED! UPDATE: The issue was not bitcoin related. I had to increase the root partition of ubuntu, as it wasn't using the full SSD size I had, but only 100 GB and the sync therefore ran out of space and restarted from a certain point.</strong></p>
<p>I connect to my node that I've set up after raspibolt.org (I have a NUC and not a raspberry though, so 32 Bit). I connect to it over SSH and sometimes check the status of the sync. I'm not sure if I read the logs wrong, but they get renewed permanently, so it's not stuck, but it seems like the sync got into some kind of loop where it always restarts. Another node of me synced within 30 hours from 0 to absolute completeness, and it's on the same connection.</p>
<p>I login over SSH and execute this command: <code>tail -f /home/bitcoin/.bitcoin/debug.log</code></p>
<p><code>bitcoind</code> is running as a service, not manual. I wonder if me disconnecting from SSH could somehow halt the blockchain sync?</p>
<p>OS: Ubuntu 24.04</p>
<p>Recent logs (it's always from height 400'000 and TXes from 2026):</p>
<p><a href="https://i.sstatic.net/pmI1Xhfg.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/pmI1Xhfg.png" alt="enter image description here" /></a></p>
<p>Your help is highly appreciated.</p>
<p>I assume that <code>progress=0.110276</code> is the percentage (in decimals) of the sync. It hovers from 0.11 to 0.13 since a day.</p>
<p>Update:</p>
<p>I have no idea if related, but I saw this error. Not sure if it's from the ssh client or pc:</p>
<pre><code>2024-05-12T16:32:00Z UpdateTip: new best=0000000000000000050dc384f0c8f3ed586bf88                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             53f4f94a2da912cf2a6aff54d height=414977 version=0x00000004 log2_work=84.782407 t                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             x=133826461 date='2016-06-06T00:57:37Z' progress=0.131048 cache=1743.6MiB(156232                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             88txo)
2024-05-12T16:32:01Z UpdateTip: new best=000000000000000004b29c6c8e3ff428912c528                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             b3fc4124ccc1314c43e08247d height=414978 version=0x30000000 log2_work=84.782444 t                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             x=133827957 date='2016-06-06T01:11:03Z' progress=0.131049 cache=1744.6MiB(156340                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             76txo)
2024-05-12T16:32:01Z Cache size (1830114096) exceeds total space (1829784384)
2024-05-12T16:32:01Z *** Disk space is too low!
2024-05-12T16:32:01Z Error: Disk space is too low!
2024-05-12T16:32:01Z tor: Thread interrupt
2024-05-12T16:32:01Z Shutdown: In progress...
2024-05-12T16:32:01Z addcon thread exit
2024-05-12T16:32:01Z RemoveLocal(gjzvhraxkhrxjgq7cswsl2xw5zapifxg5fmh5gwhj3ljgvmbqlo7w7yd.onion:8333)
2024-05-12T16:32:01Z *** Failed to connect best block (Disk space is too low!)
2024-05-12T16:32:01Z Error: A fatal internal error occurred, see debug.log for details
2024-05-12T16:32:01Z torcontrol thread exit
2024-05-12T16:32:01Z msghand thread exit
2024-05-12T16:32:01Z txindex thread start
2024-05-12T16:32:01Z txindex: m_interrupt set; exiting ThreadSync
2024-05-12T16:32:01Z txindex thread exit
2024-05-12T16:32:01Z Loading 0 mempool transactions from disk...
2024-05-12T16:32:01Z Imported mempool transactions from disk: 0 succeeded, 0 failed, 0 expired, 0 already there, 0 waiting for initial broadcast
2024-05-12T16:32:01Z initload thread exit
2024-05-12T16:32:01Z net thread exit
2024-05-12T16:32:01Z ERROR: Error while reading proxy response
2024-05-12T16:32:01Z opencon thread exit
2024-05-12T16:32:01Z DumpAnchors: Flush 2 outbound block-relay-only peer addresses to anchors.dat started
2024-05-12T16:32:01Z DumpAnchors: Flush 2 outbound block-relay-only peer addresses to anchors.dat completed (0.00s)
2024-05-12T16:32:01Z scheduler thread exit
2024-05-12T16:32:01Z Cache size (1830114096) exceeds total space (1829784384)
2024-05-12T16:32:01Z *** Disk space is too low!
2024-05-12T16:32:01Z Error: Disk space is too low!
2024-05-12T16:32:01Z ForceFlushStateToDisk: failed to flush state (Disk space is too low!)
2024-05-12T16:32:01Z Cache size (1830114096) exceeds total space (1829784384)
2024-05-12T16:32:01Z *** Disk space is too low!
2024-05-12T16:32:01Z Error: Disk space is too low!
2024-05-12T16:32:01Z ForceFlushStateToDisk: failed to flush state (Disk space is too low!)
2024-05-12T16:32:03Z Shutdown: done
tail: /home/bitcoin/.bitcoin/debug.log: file truncated

</code></pre>
<p>Output of <code>df -h</code> is</p>
<pre><code>tmpfs 1.6G 1.7M 1.6G 1% /run 
efivarfs 192K 115K 73K 62% /sys/firmware/efi/efivars  
/dev/mapper/ubuntu--vg-ubuntu--lv 98G 92G 1.5G 99% / 
tmpfs 7.6G 0 7.6G 0% /dev/shm 
tmpfs 5.0M 0 5.0M 0% /run/lock 
/dev/nvme0n1p2 2.0G 95M 1.7G 6% /boot 
/dev/nvme0n1p1 1.1G 6.2M 1.1G 1% /boot/efi 
tmpfs 1.6G 12K 1.6G 1% /run/user/1000
</code></pre>

CC BY-SA 4.0
2024-05-12T13:20:03.237Z
My best guess is that your `bitcoind` is consuming too much memory, and gets killed by the OS's OOM killer, at which point progress is lost, and redone after restart. Try reducing your `dbcache` value in bitcoin.conf.
Pieter Wuille
CC BY-SA 4.0
2024-05-12T16:36:07.840Z
@PieterWuille Hey I updated my question, as I saw an error. Might it be this? I have 16 GB ram on that machine, that should be sufficient, no? `dbcache` is set to 2000 only.
codepleb
CC BY-SA 4.0
2024-05-12T16:45:12.157Z
Ah, yes, ok; your node is failing to flush to disk because it's running out of disk space, and then on restart redoes everything.
Pieter Wuille
CC BY-SA 4.0
2024-05-12T17:14:48.647Z
But I have a 4 TB SSD?
codepleb
CC BY-SA 4.0
2024-05-12T17:43:01.540Z
You must be running the Bitcoin Core data directory on a filesystem that's much smaller. What does `df -h` say?
Pieter Wuille
CC BY-SA 4.0
2024-05-12T21:40:15.013Z
@PieterWuille Filesystem                       
tmpfs                              1.6G  1.7M  1.6G   1% /run
efivarfs                           192K  115K   73K  62% /sys/firmware/efi/efivars
/dev/mapper/ubuntu--vg-ubuntu--lv   98G   92G  1.5G  99% /
tmpfs                              7.6G     0  7.6G   0% /dev/shm
tmpfs                              5.0M     0  5.0M   0% /run/lock
/dev/nvme0n1p2                     2.0G   95M  1.7G   6% /boot
/dev/nvme0n1p1                     1.1G  6.2M  1.1G   1% /boot/efi
tmpfs                              1.6G   12K  1.6G   1% /run/user/1000
codepleb
CC BY-SA 4.0
2024-05-12T22:21:26.660Z
Looks like your root filesystem is only 100G. Addressing that is probably off topic on this site.
Pieter Wuille
CC BY-SA 4.0
2024-05-13T12:29:07.630Z
I’m voting to close this question because it's about a machine running out of disk space, not a technical question about Bitcoin.
Antoine Poinsot
CC BY-SA 4.0
2024-05-13T14:23:14.663Z
Ok, thanks for your help!
codepleb
CC BY-SA 4.0
2024-05-13T15:41:07.027Z
I managed to increase the size of the root partition! Thank you very much for your help, it seems to go past the 13% now!! 
codepleb
CC BY-SA 4.0
2024-05-13T15:43:58.620Z
@AntoinePoinsot To be honest, I believe I won't be the last one running into this issue. It's not very intuitive that it would stop and lose 2% of the blockchain sync and restart all the time, in my opinion. But I agree, this has nothing to do with bitcoin itself. So if you think closing it is better, I leave it up to you guys.
codepleb
CC BY-SA 4.0
2024-05-13T15:45:38.220Z
@codepleb Bitcoin Core doesn't restart itself; it exits with an error. Something (you, or some automated process on top) is restarting it while ignoring the error.
Pieter Wuille
CC BY-SA 4.0
2024-05-14T06:21:15.713Z
@PieterWuille But it restarts 2% behind the current sync point. Not sure if that is the cache size.
codepleb
CC BY-SA 4.0
2024-05-14T09:52:52.843Z
Yes, it fails to write its progress to disk because out of space.
Pieter Wuille
CC BY-SA 4.0
2024-05-14T21:01:58.047Z
@PieterWuille I fully agree that this is not a bitcoin issue. However, I believe a lot of people might run in the very same issue and get confused. At least ubuntu users should find this thread because of the tag.
codepleb
<blockchain><synchronization><full-node><ubuntu>
Blockchain sync seems to be stuck in a loop?
codepleb
# Blockchain sync seems to be stuck in a loop?

(Asked by: username_0 on 2024-05-12)

**SOLVED! UPDATE: The issue was not bitcoin related. I had to increase the root partition of ubuntu, as it wasn't using the full SSD size I had, but only 100 GB and the sync therefore ran out of space and restarted from a certain point.**

I connect to my node that I've set up after raspibolt.org (I have a NUC and not a raspberry though, so 32 Bit). I connect to it over SSH and sometimes check the status of the sync. I'm not sure if I read the logs wrong, but they get renewed permanently, so it's not stuck, but it seems like the sync got into some kind of loop where it always restarts. Another node of me synced within 30 hours from 0 to absolute completeness, and it's on the same connection.

I login over SSH and execute this command: `tail -f /home/bitcoin/.bitcoin/debug.log`

`bitcoind` is running as a service, not manual. I wonder if me disconnecting from SSH could somehow halt the blockchain sync?

OS: Ubuntu 24.04

Recent logs (it's always from height 400'000 and TXes from 2026):

[![enter image description here](https://i.sstatic.net/pmI1Xhfg.png)](https://i.sstatic.net/pmI1Xhfg.png)

Your help is highly appreciated.

I assume that `progress=0.110276` is the percentage (in decimals) of the sync. It hovers from 0.11 to 0.13 since a day.

Update:

I have no idea if related, but I saw this error. Not sure if it's from the ssh client or pc:

```
2024-05-12T16:32:00Z UpdateTip: new best=0000000000000000050dc384f0c8f3ed586bf88                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             53f4f94a2da912cf2a6aff54d height=414977 version=0x00000004 log2_work=84.782407 t                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             x=133826461 date='2016-06-06T00:57:37Z' progress=0.131048 cache=1743.6MiB(156232                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             88txo)
2024-05-12T16:32:01Z UpdateTip: new best=000000000000000004b29c6c8e3ff428912c528                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             b3fc4124ccc1314c43e08247d height=414978 version=0x30000000 log2_work=84.782444 t                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             x=133827957 date='2016-06-06T01:11:03Z' progress=0.131049 cache=1744.6MiB(156340                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             76txo)
2024-05-12T16:32:01Z Cache size (1830114096) exceeds total space (1829784384)
2024-05-12T16:32:01Z *** Disk space is too low!
2024-05-12T16:32:01Z Error: Disk space is too low!
2024-05-12T16:32:01Z tor: Thread interrupt
2024-05-12T16:32:01Z Shutdown: In progress...
2024-05-12T16:32:01Z addcon thread exit
2024-05-12T16:32:01Z RemoveLocal(gjzvhraxkhrxjgq7cswsl2xw5zapifxg5fmh5gwhj3ljgvmbqlo7w7yd.onion:8333)
2024-05-12T16:32:01Z *** Failed to connect best block (Disk space is too low!)
2024-05-12T16:32:01Z Error: A fatal internal error occurred, see debug.log for details
2024-05-12T16:32:01Z torcontrol thread exit
2024-05-12T16:32:01Z msghand thread exit
2024-05-12T16:32:01Z txindex thread start
2024-05-12T16:32:01Z txindex: m_interrupt set; exiting ThreadSync
2024-05-12T16:32:01Z txindex thread exit
2024-05-12T16:32:01Z Loading 0 mempool transactions from disk...
2024-05-12T16:32:01Z Imported mempool transactions from disk: 0 succeeded, 0 failed, 0 expired, 0 already there, 0 waiting for initial broadcast
2024-05-12T16:32:01Z initload thread exit
2024-05-12T16:32:01Z net thread exit
2024-05-12T16:32:01Z ERROR: Error while reading proxy response
2024-05-12T16:32:01Z opencon thread exit
2024-05-12T16:32:01Z DumpAnchors: Flush 2 outbound block-relay-only peer addresses to anchors.dat started
2024-05-12T16:32:01Z DumpAnchors: Flush 2 outbound block-relay-only peer addresses to anchors.dat completed (0.00s)
2024-05-12T16:32:01Z scheduler thread exit
2024-05-12T16:32:01Z Cache size (1830114096) exceeds total space (1829784384)
2024-05-12T16:32:01Z *** Disk space is too low!
2024-05-12T16:32:01Z Error: Disk space is too low!
2024-05-12T16:32:01Z ForceFlushStateToDisk: failed to flush state (Disk space is too low!)
2024-05-12T16:32:01Z Cache size (1830114096) exceeds total space (1829784384)
2024-05-12T16:32:01Z *** Disk space is too low!
2024-05-12T16:32:01Z Error: Disk space is too low!
2024-05-12T16:32:01Z ForceFlushStateToDisk: failed to flush state (Disk space is too low!)
2024-05-12T16:32:03Z Shutdown: done
tail: /home/bitcoin/.bitcoin/debug.log: file truncated

```

Output of `df -h` is

```
tmpfs 1.6G 1.7M 1.6G 1% /run 
efivarfs 192K 115K 73K 62% /sys/firmware/efi/efivars  
/dev/mapper/ubuntu--vg-ubuntu--lv 98G 92G 1.5G 99% / 
tmpfs 7.6G 0 7.6G 0% /dev/shm 
tmpfs 5.0M 0 5.0M 0% /run/lock 
/dev/nvme0n1p2 2.0G 95M 1.7G 6% /boot 
/dev/nvme0n1p1 1.1G 6.2M 1.1G 1% /boot/efi 
tmpfs 1.6G 12K 1.6G 1% /run/user/1000

```

**Tags:** blockchain, synchronization, full-node, ubuntu

> **Comments:**
> **username_1**: My best guess is that your `bitcoind` is consuming too much memory, and gets killed by the OS's OOM killer, at which point progress is lost, and redone after restart. Try reducing your `dbcache` value in bitcoin.conf.  
> **username_0**: @username_1 Hey I updated my question, as I saw an error. Might it be this? I have 16 GB ram on that machine, that should be sufficient, no? `dbcache` is set to 2000 only.  
> **username_1**: Ah, yes, ok; your node is failing to flush to disk because it's running out of disk space, and then on restart redoes everything.  
> **username_0**: But I have a 4 TB SSD?  
> **username_1**: You must be running the Bitcoin Core data directory on a filesystem that's much smaller. What does `df -h` say?  
> **username_0**: @username_1 Filesystem                        tmpfs                              1.6G  1.7M  1.6G   1% /run efivarfs                           192K  115K   73K  62% /sys/firmware/efi/efivars /dev/mapper/ubuntu--vg-ubuntu--lv   98G   92G  1.5G  99% / tmpfs                              7.6G     0  7.6G   0% /dev/shm tmpfs                              5.0M     0  5.0M   0% /run/lock /dev/nvme0n1p2                     2.0G   95M  1.7G   6% /boot /dev/nvme0n1p1                     1.1G  6.2M  1.1G   1% /boot/efi tmpfs                              1.6G   12K  1.6G   1% /run/user/1000  
> **username_1**: Looks like your root filesystem is only 100G. Addressing that is probably off topic on this site.  
> **username_2**: I’m voting to close this question because it's about a machine running out of disk space, not a technical question about Bitcoin.  
> **username_0**: Ok, thanks for your help!  
> **username_0**: I managed to increase the size of the root partition! Thank you very much for your help, it seems to go past the 13% now!!   
> **username_0**: @username_2 To be honest, I believe I won't be the last one running into this issue. It's not very intuitive that it would stop and lose 2% of the blockchain sync and restart all the time, in my opinion. But I agree, this has nothing to do with bitcoin itself. So if you think closing it is better, I leave it up to you guys.  
> **username_1**: @username_0 Bitcoin Core doesn't restart itself; it exits with an error. Something (you, or some automated process on top) is restarting it while ignoring the error.  
> **username_0**: @username_1 But it restarts 2% behind the current sync point. Not sure if that is the cache size.  
> **username_1**: Yes, it fails to write its progress to disk because out of space.  
> **username_0**: @username_1 I fully agree that this is not a bitcoin issue. However, I believe a lot of people might run in the very same issue and get confused. At least ubuntu users should find this thread because of the tag.  

---

## 1 answers

### Answer by username_0 on 2024-05-14. Score: 0

In my case, it was the disk running out of space (running Ubuntu Server 24.04). I didn't notice, that the root partition only has 100Gb assigned.

**If you have the same issue and you run Ubuntu, this was my solution.** ChatCpt helped me here.

Here's how you can increase the size of the LVM partition /dev/mapper/ubuntu--vg-ubuntu--lv using the lvresize command:

Make sure you have a backup of your important data before proceeding.

Boot your Ubuntu system and open a terminal.

Verify the current size of the LV partition using the lvdisplay command:

`sudo lvdisplay`

Look for the LV that corresponds to `/dev/mapper/ubuntu--vg-ubuntu--lv` to check its current size.

To increase the size of the LV, use the lvresize command with the desired new size. For example, to increase it by 5GB:

`sudo lvresize -L +5G /dev/mapper/ubuntu--vg-ubuntu--lv`

Adjust the size (+5G in this case) according to your needs.

Now, if the filesystem on the LV is ext4, you can expand it to utilize the additional space using the resize2fs command:

`sudo resize2fs /dev/mapper/ubuntu--vg-ubuntu--lv`
If the filesystem is different, you'll need to use the respective filesystem-specific command to resize it.

With these steps, you should be able to increase the size of the LVM partition (/dev/mapper/ubuntu--vg-ubuntu--lv) correctly. However, always ensure you have backups and exercise caution when modifying partitions and filesystems to prevent any potential data loss.


---

