# Why Aerospike use only 100gb of disk

**URL:** <https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939>\
**Category:** Tuning\
**Created:** [April 1, 2024, 2:23pm UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939 "2024-04-01T14:23:47Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![kuntypasa](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/kuntypasa/32/2230_2.png) [@kuntypasa](https://discuss.aerospike.com/u/kuntypasa)\
**Post date:** [April 1, 2024, 2:23pm UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/1 "2024-04-01T14:23:47Z")

</div>

I have a cluster , over 3 vm. Each vm have 500 gb disk space for related namespace. But i see on amc , around %20 disk used . Avail% is most of the time under %20. What is the problem ? Please help me. Best regards.

---

<div class="post-metadata">

**Author:** ![kuntypasa](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/kuntypasa/32/2230_2.png) [@kuntypasa](https://discuss.aerospike.com/u/kuntypasa)\
**Post date:** [April 1, 2024, 2:24pm UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/2 "2024-04-01T14:24:49Z")

</div>

![image](https://us1.discourse-cdn.com/flex019/uploads/aerospike/original/2X/4/42fadba2a0fe917b571ac36fcbb615e9aa08f9a1.png)

---

<div class="post-metadata">

**Author:** ![kuntypasa](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/kuntypasa/32/2230_2.png) [@kuntypasa](https://discuss.aerospike.com/u/kuntypasa)\
**Post date:** [April 1, 2024, 2:27pm UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/3 "2024-04-01T14:27:07Z")

</div>

![image](https://us1.discourse-cdn.com/flex019/uploads/aerospike/original/2X/2/201b35e44c97a5b5fbbb5aeaf8b8bbf2c00a1402.png)

---

<div class="post-metadata">

**Author:** ![pgupta](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/pgupta/32/2351_2.png) [@pgupta](https://discuss.aerospike.com/u/pgupta)\
**Post date:** [April 1, 2024, 9:39pm UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/4 "2024-04-01T21:39:41Z")

</div>

This is a symptom of defrag not running. I cannot see based on your config why that would happen. In fact, your defrag is set to be more on the aggressive side. `defrag-lwm-pct 70` where we typically recommend 50. It is a dynamic parameter - so you must check if at some point did you set it to a low value? lower than 50? You can use one of the admin tools to get the running configuration of the server nodes. Not sure which server version you are using. In older versions: asinfo -v “get-config:context=namespace;id=your\_namespace\_name” should get that info.

The other case where defrag will not run is if the block is still in the post-write-queue. Here too, going by your config, you have not set it to a higher number. So it is at 256 blocks, each block at 1M - so max 256Mb of the approx 15 GB data in each device. (You have 6 devices, each device gets its own post-write-queue). But that too is a dynamic parameter. So check that as well.

---

<div class="post-metadata">

**Author:** ![kuntypasa](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/kuntypasa/32/2230_2.png) [@kuntypasa](https://discuss.aerospike.com/u/kuntypasa)\
**Post date:** [April 2, 2024, 8:56am UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/5 "2024-04-02T08:56:31Z")

</div>

Thank you for reply. Here is full conf.

```auto
# Aerospike database configuration file for use with systemd.

service {
        proto-fd-max 15000
}

logging {
        console {
                context any info
        }
}

network {
        service {
                address any
                port 3000
        }

        heartbeat {
                #mode multicast
                #multicast-group 239.1.99.222
                #port 9918

                # To use unicast-mesh heartbeats, remove the 3 lines above, and see
                # aerospike_mesh.conf for alternative.
                #
                mode mesh
                port 3002 # Heartbeat port for this node.
                mesh-seed-address-port 10.90.235.220 3002
                mesh-seed-address-port 10.90.235.222 3002

                interval 150
                timeout 10
        }

        fabric {
                port 3001
        }

        info {
                port 3003
        }
}

namespace ubflight_eng {
    replication-factor 2
    memory-size 16G
    default-ttl 3h
    nsup-period 600

    storage-engine device {
        device /dev/sdb1
        device /dev/sdb2
        device /dev/sdb3
        device /dev/sdb4
        device /dev/sdc1
        device /dev/sdd1
        compression lz4

        scheduler-mode noop
        write-block-size 1M
        max-write-cache 128M
        defrag-lwm-pct 70
        data-in-memory false
    }
}

namespace ubflight_datasrv {
    replication-factor 2
    memory-size 1G
    default-ttl 1d
    nsup-period 600

    storage-engine device {
        #device /dev/sdb3
        file /data/ubflight.datasrv.dat
        filesize 5G
         compression lz4
        scheduler-mode noop
        write-block-size 512K
        max-write-cache 128M
        defrag-lwm-pct 65
        data-in-memory true
    }
}

namespace flightChn {
    replication-factor 2
    memory-size 4G
    default-ttl 1d
    nsup-period 600

    storage-engine device {
        #file /data/flight.chn.dat
        #filesize 5G
        device /dev/sde1
        compression lz4
        scheduler-mode noop
        write-block-size 2M
        max-write-cache 128M
        defrag-lwm-pct 65
        data-in-memory false # Store data in memory in addition to file.
     }
}

```

---

<div class="post-metadata">

**Author:** ![kuntypasa](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/kuntypasa/32/2230_2.png) [@kuntypasa](https://discuss.aerospike.com/u/kuntypasa)\
**Post date:** [April 2, 2024, 8:57am UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/6 "2024-04-02T08:57:48Z")

</div>

Aerospike vers 6.1.0.1

Thanks

---

<div class="post-metadata">

**Author:** ![pgupta](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/pgupta/32/2351_2.png) [@pgupta](https://discuss.aerospike.com/u/pgupta)\
**Post date:** [April 2, 2024, 5:32pm UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/7 "2024-04-02T17:32:16Z")

</div>

1. Is this Enterprise Edition?
2. config files is the configuration you started with. Would like to validate that nothing was changed dynamically. Can you share the output of asadm similar to below:

```auto
$ asadm -e "show config like defrag"
Seed: [('127.0.0.1', 3000, None)]
Config_file: /home/training/.aerospike/astools.conf, /etc/aerospike/astools.conf
~~~~~~~~~~test Namespace Configuration (2024-04-02 17:31:37 UTC)~~~~~~~~~~
Node |ip-172-31-69-162.ec2.internal:3000
storage-engine.defrag-lwm-pct |50
storage-engine.defrag-queue-min |0
storage-engine.defrag-sleep |1000
storage-engine.defrag-startup-minimum|0

```

and

```auto
$ asadm -e "show config like post"
Seed: [('127.0.0.1', 3000, None)]
Config_file: /home/training/.aerospike/astools.conf, /etc/aerospike/astools.conf
~~~~~~~test Namespace Configuration (2024-04-02 17:31:48 UTC)~~~~~~~
Node |ip-172-31-69-162.ec2.internal:3000
storage-engine.post-write-queue|256
Number of rows: 2

```

---

<div class="post-metadata">

**Author:** ![kuntypasa](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/kuntypasa/32/2230_2.png) [@kuntypasa](https://discuss.aerospike.com/u/kuntypasa)\
**Post date:** [April 2, 2024, 6:04pm UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/8 "2024-04-02T18:04:19Z")

</div>

![image](https://us1.discourse-cdn.com/flex019/uploads/aerospike/original/2X/b/b6c61f6c0fcea6a758e1c44a34eb81ef019f2f4a.png)

---

<div class="post-metadata">

**Author:** ![kuntypasa](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/kuntypasa/32/2230_2.png) [@kuntypasa](https://discuss.aerospike.com/u/kuntypasa)\
**Post date:** [April 2, 2024, 6:05pm UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/9 "2024-04-02T18:05:02Z")

</div>

![image](https://us1.discourse-cdn.com/flex019/uploads/aerospike/original/2X/e/e6e3c7fcb7fd2c61bad8e2c3233be7d6212f3cd9.png)

---

<div class="post-metadata">

**Author:** ![kuntypasa](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/kuntypasa/32/2230_2.png) [@kuntypasa](https://discuss.aerospike.com/u/kuntypasa)\
**Post date:** [April 2, 2024, 6:33pm UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/10 "2024-04-02T18:33:03Z")

</div>

Version Aerospike Community Edition build 6.0.0.3

Thank you so much

---

<div class="post-metadata">

**Author:** ![pgupta](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/pgupta/32/2351_2.png) [@pgupta](https://discuss.aerospike.com/u/pgupta)\
**Post date:** [April 2, 2024, 6:38pm UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/11 "2024-04-02T18:38:59Z")

</div>

Bit confused, can you share output of: `$ asadm -e info`

---

<div class="post-metadata">

**Author:** ![kuntypasa](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/kuntypasa/32/2230_2.png) [@kuntypasa](https://discuss.aerospike.com/u/kuntypasa)\
**Post date:** [April 2, 2024, 7:10pm UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/12 "2024-04-02T19:10:40Z")

</div>

> [@pgupta](#):
>
> -e info

 ![image](https://us1.discourse-cdn.com/flex019/uploads/aerospike/original/2X/5/5e072ef0b43cfee48897e281d7537dfdfbdc0f77.png)

when i use this command , all nodes are going down , im so confused

---

<div class="post-metadata">

**Author:** ![pgupta](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/pgupta/32/2351_2.png) [@pgupta](https://discuss.aerospike.com/u/pgupta)\
**Post date:** [April 2, 2024, 7:18pm UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/13 "2024-04-02T19:18:49Z")

</div>

You are using Community Edition. It only allows you to configure maximum two namespaces. That may be your issue. [Known Limitations | Aerospike Documentation](https://aerospike.com/docs/reference/limitations)

 ![Screenshot 2024-04-02 at 12.19.43 PM](https://us1.discourse-cdn.com/flex019/uploads/aerospike/original/2X/c/c82456d52a0c25196279ab5013394dd47260803f.png)

---

<div class="post-metadata">

**Author:** ![kuntypasa](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/kuntypasa/32/2230_2.png) [@kuntypasa](https://discuss.aerospike.com/u/kuntypasa)\
**Post date:** [April 3, 2024, 6:22am UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/14 "2024-04-03T06:22:17Z")

</div>

Thank you much , i try remove datasrv namespace , it look useless with 0/0 master/replica objects.

---

<div class="post-metadata">

**Author:** ![kuntypasa](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/kuntypasa/32/2230_2.png) [@kuntypasa](https://discuss.aerospike.com/u/kuntypasa)\
**Post date:** [April 3, 2024, 9:03pm UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/15 "2024-04-03T21:03:28Z")

</div>

> [@kuntypasa](#):
>
> `write-block-size 1M`

Hi again , which size is the best practice for flash datastore disks ?

---

<div class="post-metadata">

**Author:** ![pgupta](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/pgupta/32/2351_2.png) [@pgupta](https://discuss.aerospike.com/u/pgupta)\
**Post date:** [April 4, 2024, 4:44pm UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/17 "2024-04-04T16:44:38Z")

</div>

Allowed block size in in powers of 2. (…128KB … 256KB/512KB/1M/2M/4M/8M max) Depends on your max record size and generation of SSDs.

1. Aerospike will not split your records across multiple write-blocks - so if you expect records of size few hundred KBs, 1M is your choice.
2. SSDs till many years ago showed best I/O performance at 128KB block size transfers. So that was recommended for users who had average records about 1.5KB is size. (This is how the default parameters for ACT test for characterizing SSDs are set.)
3. From disk utilization point of view, if you have 50KB records, and use 128KB block size - each block will have 28KB un-utilized - 2 x 50 = 100, can’t fit the 3rd record.
4. The larger the block size (8MB max allowed), currently, the more intense the block i/o when Aerospike moves blocks of data for defrag and other operations internally. So, keeping the block size smaller helps in that respect currently.

Hope that helps your decide the right block size.

---

<div class="post-metadata">

**Author:** ![kuntypasa](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/kuntypasa/32/2230_2.png) [@kuntypasa](https://discuss.aerospike.com/u/kuntypasa)\
**Post date:** [April 5, 2024, 6:33am UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/18 "2024-04-05T06:33:21Z")

</div>

Thank you Sir. It was very explanatory

---

<div class="post-metadata">

**Author:** ![kuntypasa](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/kuntypasa/32/2230_2.png) [@kuntypasa](https://discuss.aerospike.com/u/kuntypasa)\
**Post date:** [April 5, 2024, 6:37am UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/19 "2024-04-05T06:37:41Z")

</div>

By the way, we solved our problem. I reduced the number of partitions of the sdb disk to 1. Now we have 1 partition on each 1 disk.

![image](https://us1.discourse-cdn.com/flex019/uploads/aerospike/original/2X/2/2a2288735bc8b49d2e2aa160ddb6f9a7f730bef4.png)

---

<div class="post-metadata">

**Author:** ![kuntypasa](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/kuntypasa/32/2230_2.png) [@kuntypasa](https://discuss.aerospike.com/u/kuntypasa)\
**Post date:** [April 5, 2024, 6:50am UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/20 "2024-04-05T06:50:36Z")

</div>

And the result

 ![image](https://us1.discourse-cdn.com/flex019/uploads/aerospike/original/2X/8/85321da9eb34ea94971ae0640487e585b6109879.png)

---

<div class="post-metadata">

**Author:** ![pgupta](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.aerospike.com/pgupta/32/2351_2.png) [@pgupta](https://discuss.aerospike.com/u/pgupta)\
**Post date:** [April 5, 2024, 6:54am UTC](https://discuss.aerospike.com/t/why-aerospike-use-only-100gb-of-disk/10939/21 "2024-04-05T06:54:00Z")

</div>

Nice. BTW, I noted you have configured compression. If you are using Community Edition (CE), it will be silently ignored. See this link for what is supported by CE vs SE or EE (licensed versions).

> **[Aerospike Database Features and Editions](https://aerospike.com/products/features-and-editions/)**
>
> From a free community edition to Enterprise and a fully managed services solution, Aerospike offers multiple pricing models to fit any size organization.
