# Understanding the node space calculation (not)

**URL:** <https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983>\
**Category:** troubleshooting\
**Tags:** hashstore, used-space\
**Created:** [October 28, 2026, 6:27am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983 "2026-10-28T06:27:19Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![jammerdan](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/jammerdan/32/1121_2.png) [@jammerdan](https://forum.storj.io/u/jammerdan)\
**Post date:** [October 28, 2026, 6:27am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/1 "2026-10-28T06:27:19Z")

</div>

One node didn’t have ingress. So I checked out the (free) space that it was advertising.  
And to me the results look weird:

 ![Screenshot_2026-10-28_070406](https://storj-s3.bcdn.literatehosting.net/original/3X/7/9/7966940ea5f872c9358a769c47b5c6728b34e3f0.jpeg)

 ![Screenshot_2026-10-28_070947](https://storj-s3.bcdn.literatehosting.net/original/3X/1/6/1697d9284186e45a27799698909a37465a236d25.jpeg)  
 ![Screenshot_2026-10-28_070050](https://storj-s3.bcdn.literatehosting.net/original/3X/3/1/3136621729283bc571d5507f640171368232b55c.jpeg)

All the same node, the only change I did is to modify the allocated space. +100 GB reduces for some reaseon the used space by 1.4TB which is then available as free space and the node receives ingress again.  
To me this seems like a strange calculation.

---

<div class="post-metadata">

**Author:** ![Alexey](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/alexey/32/41_2.png) [@Alexey](https://forum.storj.io/u/Alexey)\
**Post date:** [October 28, 2026, 7:08am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/2 "2026-10-28T07:08:21Z")

</div>

This started a recalculation, because you were forced to restart the node.  
Perhaps you might just restart it to have the same result?

---

<div class="post-metadata">

**Author:** ![jammerdan](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/jammerdan/32/1121_2.png) [@jammerdan](https://forum.storj.io/u/jammerdan)\
**Post date:** [October 29, 2026, 4:14am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/3 "2026-10-29T04:14:18Z")

</div>

> [@Alexey](#):
>
> Perhaps you might just restart it to have the same result?

I don’t know if I’m understanding you correctly. Are you suggesting to restart the node?

---

<div class="post-metadata">

**Author:** ![Alexey](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/alexey/32/41_2.png) [@Alexey](https://forum.storj.io/u/Alexey)\
**Post date:** [October 29, 2026, 4:30am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/4 "2026-10-29T04:30:12Z")

</div>

When you changed the allocation, you restarted the node, so you could have just restarted it instead, and the allocation change would have had nothing to do with it.

---

<div class="post-metadata">

**Author:** ![jammerdan](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/jammerdan/32/1121_2.png) [@jammerdan](https://forum.storj.io/u/jammerdan)\
**Post date:** [October 29, 2026, 4:59am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/5 "2026-10-29T04:59:11Z")

</div>

> [@Alexey](#):
>
> and the allocation change would have had nothing to do with it

So you are saying a restart without changing the allocation would have also showed 1.4TB as free? Well the question is, if there is 1.4TB free why does it not show it in the first place but only after a restart be it with or without change of allocation?

---

<div class="post-metadata">

**Author:** ![jammerdan](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/jammerdan/32/1121_2.png) [@jammerdan](https://forum.storj.io/u/jammerdan)\
**Post date:** [October 29, 2026, 5:25am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/6 "2026-10-29T05:25:32Z")

</div>

I have just reverted the change. First screenshot is as it was running since yesterday, second is the space display after reducing allocation by 100GB:

 ![Screenshot_2026-10-29_053320](https://storj-s3.bcdn.literatehosting.net/original/3X/1/e/1ee512761f0d0b595fc6e75f0c656c69f782cb22.jpeg)  
 ![Screenshot_2026-10-29_062222](https://storj-s3.bcdn.literatehosting.net/original/3X/5/4/54d11d54d7384d137b0a4031092fd6c801d3d658.jpeg)

Edit: And no ingress again.

---

<div class="post-metadata">

**Author:** ![Alexey](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/alexey/32/41_2.png) [@Alexey](https://forum.storj.io/u/Alexey)\
**Post date:** [October 29, 2026, 6:31am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/7 "2026-10-29T06:31:25Z")

</div>

How much free space is actually available on this node? And how much is actually used?

---

<div class="post-metadata">

**Author:** ![jammerdan](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/jammerdan/32/1121_2.png) [@jammerdan](https://forum.storj.io/u/jammerdan)\
**Post date:** [October 29, 2026, 7:06am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/8 "2026-10-29T07:06:28Z")

</div>

> [@Alexey](#):
>
> How much free space is actually available on this node?

Do you mean disk space? More than 10TB free on the disk.  
What I don’t get is: I **increase** the allocated space and it **reduces** the used space and **increases** the free space both disproportionately to the increase in allocated space.

---

<div class="post-metadata">

**Author:** ![Alexey](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/alexey/32/41_2.png) [@Alexey](https://forum.storj.io/u/Alexey)\
**Post date:** [October 29, 2026, 7:19am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/9 "2026-10-29T07:19:06Z")

</div>

There is a reason, I just want to figure it out. How much is actually used?

---

<div class="post-metadata">

**Author:** ![Julio](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/julio/32/1132_2.png) [@Julio](https://forum.storj.io/u/Julio)\
**Post date:** [October 29, 2026, 7:24am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/10 "2026-10-29T07:24:58Z")

</div>

“and the allocation change would have had nothing to do with it.” That’s illogical captain.  
It would have been running a long time already, thus the example.

That bug is several months old… 6 or 7 months? The concerning thing would be if hours after startijng it would revert to that, but it’s a bug because to starts on start up. I believe when they were last tinkering in that section of code they screwed that up, ie: the disk size fix - whenever they tried to last fix that debacle.

Maybe the 100 Gigs is related to the necessary/recommended free space for transition to hashstore…my memory is fuzzy, try it +/- 25-50GB of that delta from 1st example.

.2 cents,  
Julio

---

<div class="post-metadata">

**Author:** ![Alexey](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/alexey/32/41_2.png) [@Alexey](https://forum.storj.io/u/Alexey)\
**Post date:** [October 29, 2026, 8:40am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/11 "2026-10-29T08:40:08Z")

</div>

Do you have the same result?  
If you feel that’s a bug - please fill it on our GitHub.

---

<div class="post-metadata">

**Author:** ![jammerdan](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/jammerdan/32/1121_2.png) [@jammerdan](https://forum.storj.io/u/jammerdan)\
**Post date:** [October 30, 2026, 5:59am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/12 "2026-10-30T05:59:49Z")

</div>

> [@Alexey](#):
>
> How much is actually used?

It is showing 3.9TB.

---

<div class="post-metadata">

**Author:** ![Alexey](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/alexey/32/41_2.png) [@Alexey](https://forum.storj.io/u/Alexey)\
**Post date:** [October 30, 2026, 6:32am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/13 "2026-10-30T06:32:39Z")

</div>

I guess, 3.9T? Then it’s 4.28TB, pretty close to what’s showed when you modified the allocation.  
Could you please try to increase on 5-10-25GB?

I wonder from where these 1.3TB are coming from? Looks like it’s showed the free space as used.

Seems the 🤖 helped to find the answer, and this is not a bug:

> **In other words, the “100GB” is not a fixed global default minimum. It is a dynamically calculated operational reserve; it can be 0, 10GB, 100GB, etc., depending on table size and config.**
>
> > [@](#):
> >
> > Because that 100GB is very likely not a hardcoded “minimum reserved space” at all. It is the hashstore compaction reserve, which is calculated dynamically from the current hashstore table size.
> > 
> > The key distinction is:
> > 
> > - default minimum node capacity requirement in Storj: 500GB
> > - hashstore “reserved” space: a runtime safety margin for compaction / temp files
> > - that reserve is not fixed to 100GB; it can be 0, 10GB, 100GB, etc., depending on table size and config
> > 
> > What the code does:
> > 
> > - the hashstore config defaults to `RewriteMultiple: 10`
> > - the reserve is computed from table size
> > - `computeSpaceUsage()` adds `stats.FreeRequired` into the reserved amount
> > 
> > Code evidence:
> > 
> > ```go
> > Compaction: CompactionCfg{
> > MaxLogSize: 1073741824,
> > ExpiresDays: 7,
> > AliveFraction: 0.25,
> > ProbabilityPower: 2.0,
> > RewriteMultiple: 10,
> > 
> > ```
> > 
> > ```go
> > func (hsb *HashStoreBackend) computeSpaceUsage() (subs monitor.SpaceUsage) {
> > for _, db := range hsb.dbsCopy() {
> > stats, _, _ := db.Stats()
> > subs.UsedTotal += int64(stats.LenLogs + stats.TableSize)
> > subs.UsedForPieces += int64(stats.LenSet - stats.LenTrash)
> > subs.UsedForTrash += int64(stats.LenTrash)
> > subs.UsedForMetadata += int64(stats.TableSize)
> > subs.UsedReclaimable += int64(stats.LenLogs - stats.LenSet)
> > subs.Reserved += int64(stats.FreeRequired)
> > }
> > return subs
> > }
> > 
> > ```
> > 
> > And in tests they literally model a 100GB reserve as a hashstore-side safety margin:
> > 
> > ```go
> > // allocated=2TB, hashstore uses 500GB (UsedTotal), reserved=100GB
> > // computed available = 2TB - 500GB - 100GB = 1.4TB
> > // but actual free disk = 300GB, so available should be capped to 300GB.
> > 
> > ```
> > 
> > So if someone on the forum sees “100GB reserved,” it is usually because:
> > 
> > - the node is using hashstore heavily,
> > - the hashstore table is large,
> > - Storj needs extra free space for compaction / rewrite safety,
> > - and the node’s available space calculation subtracts that hidden `Reserved` amount.
> > 
> > In other words, the “100GB” is not a fixed global default minimum. It is a dynamically calculated operational reserve, and the actual fixed minimum is still the node disk requirement of 500GB, not 100GB.
> > 
> > If you want, I can also walk through the exact formula for `FreeRequired` and show how a particular table size turns into ~100GB.

> **The node is not saying “actual disk free is 0 because 5.5TB vs 5.6TB”; it is saying “under the effective allocation formula, after subtracting used space and required reserve, there is no room left.” That is a very different metric.**
>
> > [@](#):
> >
> > Because the code is not using “actual free disk” as the main calculation; it uses:
> > 
> > ```go
> > // effective is the safety-checked allocation used to compute available space;
> > // it may be lower than configured if PreFlightCheck found the disk was tight.
> > effective := s.allocatedDiskSpace
> > if isLowerThanAllocated(storageStatus.DiskTotal, effective) {
> > effective = storageStatus.DiskTotal
> > }
> > 
> > available := effective - (usedForPieces + usedForTrash) - hashSpaceUsage.UsedTotal - hashSpaceUsage.Reserved
> > if available < 0 {
> > overused = -available
> > available = 0
> > }
> > if storageStatus.DiskFree > 0 && storageStatus.DiskFree < available {
> > available = storageStatus.DiskFree
> > }
> > 
> > ```
> > 
> > So the “free space” can suddenly hit 0 when:
> > 
> > - current used data is already close to the effective allocation,
> > - plus hashstore adds its own `UsedTotal`,
> > - plus `Reserved` is subtracted as “must stay free” for compaction work.
> > 
> > This means:
> > 
> > - `Allocated` = configured allocation
> > - `Effective` = maybe reduced during startup checks
> > - `Used` = pieces + trash + hashstore data
> > - `Available` = effective - used - reserved
> > - if that becomes negative or zero, the node is treated as overused and `Available` is clamped to 0
> > 
> > Also note the difference:
> > 
> > - `Free` = actual disk free space on the whole disk
> > - `Available` = free space inside the allocated budget
> > 
> > So a jump from “1.3TB available” to “0” is not a magical cutoff; it’s simply the moment the formula crosses zero:
> > 
> > `effective - used - reserved <= 0`
> > 
> > At that point, the node is basically “no room left inside allocated space,” and the code explicitly sets:
> > 
> > ```go
> > if available < 0 {
> > overused = -available
> > available = 0
> > }
> > 
> > ```
> > 
> > That is exactly why the number can drop to zero around a small threshold change.
> > 
> > And there is another important nuance: startup safety logic can reduce `allocatedDiskSpace`:
> > 
> > ```go
> > if freeDiskSpace < s.allocatedDiskSpace-totalUsed {
> > s.allocatedDiskSpace = freeDiskSpace + totalUsed
> > }
> > 
> > ```
> > 
> > So the node may report a lower `Effective` allocation than the user configured, which makes the “0 free” threshold appear suddenly.
> > 
> > In plain English: the node is not saying “actual disk free is 0 because 5.5TB vs 5.6TB”; it is saying “under the effective allocation formula, after subtracting used space and required reserve, there is no room left.” That is a very different metric.
> > 
> > If you want, I can also show how to translate a concrete example like “5.5TB allocation” into the exact numbers that would produce `Available = 0`.

---

<div class="post-metadata">

**Author:** ![jammerdan](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/jammerdan/32/1121_2.png) [@jammerdan](https://forum.storj.io/u/jammerdan)\
**Post date:** [October 30, 2026, 6:52am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/14 "2026-10-30T06:52:25Z")

</div>

> [@Alexey](#):
>
> I guess, 3.9T? Then it’s 4.28TB

Yes it is reporting 4.3T as si.

> [@Alexey](#):
>
> Seems the 🤖 helped to find the answer, and this is not a bug:

I don’t understand the details of the rest you quoted. But I understand that you are saying it is not a bug.  
So if that’s the case, then the value for used space doesn’t show the space SNO gets paid for anymore? Correct? Because otherwise it could not fluctuate from 5.53TB to 4.22TB? So meaning it has become useless?  
And if it is not a bug, the node grabs an (unpaid?) “safety margin” of 1.38TB in my case when allocated space drops under a certain threshold resulting in no more ingress?

An this is how it is supposed to be, correct?

---

<div class="post-metadata">

**Author:** ![Alexey](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/alexey/32/41_2.png) [@Alexey](https://forum.storj.io/u/Alexey)\
**Post date:** [October 30, 2026, 6:55am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/15 "2026-10-30T06:55:30Z")

</div>

Your node is paid for the used space (3.9T ~ 4.28TB minus trash and minus reclaimable), plus used egress, it’s not paid for a free space. Details you can see in the payout history.

By the way, what’s showed in the estimation table?

---

<div class="post-metadata">

**Author:** ![jammerdan](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/jammerdan/32/1121_2.png) [@jammerdan](https://forum.storj.io/u/jammerdan)\
**Post date:** [October 30, 2026, 7:03am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/16 "2026-10-30T07:03:05Z")

</div>

> [@Alexey](#):
>
> Your node is paid for the used space (3.9T ~ 4.28TB minus trash and minus reclaimable)

So from the screenshots above, with an allocation of 5.5TB the value of used space of 5.53TB does not reflect the space that I am getting paid for.  
In reality the used space is 4.22TB that I get paid for. But with a setting of 5.5TB allocated, the node does not receive any more ingress. So 1.3TB of space cannot get utilized because Storj sets this as safety marging for the nodes health. Correct?

So in reality Storj occupies 1.3TB unpaid more than you could normally expect. Correct?

---

<div class="post-metadata">

**Author:** ![Alexey](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/alexey/32/41_2.png) [@Alexey](https://forum.storj.io/u/Alexey)\
**Post date:** [October 30, 2026, 7:14am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/17 "2026-10-30T07:14:45Z")

</div>

Please show the screenshot from the Payout information - the estimation table for the current period.  
Also - the Payout History.

---

<div class="post-metadata">

**Author:** ![jammerdan](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/jammerdan/32/1121_2.png) [@jammerdan](https://forum.storj.io/u/jammerdan)\
**Post date:** [October 31, 2026, 4:17am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/18 "2026-10-31T04:17:39Z")

</div>

Here you go:

 ![Screenshot_2026-10-31_051510](https://storj-s3.bcdn.literatehosting.net/original/3X/a/a/aa7a17732dba5935a6c14156017489884bc22f68.jpeg)  
 ![Screenshot_2026-10-31_051443](https://storj-s3.bcdn.literatehosting.net/original/3X/5/9/59142ea72854f68e4e07661b2999682beb506675.jpeg)

---

<div class="post-metadata">

**Author:** ![Alexey](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/alexey/32/41_2.png) [@Alexey](https://forum.storj.io/u/Alexey)\
**Post date:** [October 31, 2026, 6:25am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/19 "2026-10-31T06:25:49Z")

</div>

As you can see, it shows the paid amount correctly, and it’s not 5.53TB. So for the payout estimation it is better to check this table, not the donut usage graph.  
By the way, is the Average Used This Month graph has any gaps?

---

<div class="post-metadata">

**Author:** ![jammerdan](https://storj.bcdn.literatehosting.com/user_avatar/forum.storj.io/jammerdan/32/1121_2.png) [@jammerdan](https://forum.storj.io/u/jammerdan)\
**Post date:** [October 31, 2026, 6:41am UTC](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983/20 "2026-10-31T06:41:09Z")

</div>

> [@Alexey](#):
>
> it shows the paid amount correctly, and it’s not 5.53TB. So for the payout estimation it is better to check this table, not the donut usage graph.

So 5.53TB is not correct but 5.53TB are being displayed. How is this not a bug?  
But it is not just a display problem. We know the real used space is around 4.22TB but the node does not receive ingress, although with allocated space of 5.5TB there are 1.3TB of space available that cannot be used, thus are occupied by the node but not paid. And when you look at it appears to be paid but it is not.  
This seems to be very specific for the setting to allocate 5.5TB for this node. When I set it to 5.6TB then magically the used space is correct and the free space that was missing, shows up and most important the node receives ingress again.

[Next page](https://forum.storj.io/t/understanding-the-node-space-calculation-not/32983.md?page=2)
