node resources
CPU 64 cores ,memory 256G ,HDD 100TB
A good starting point for the heap space is 25% of the systems memory. However, it shouldn’t be set below 1GB and not above 30.5GB, see the limits section below.
In this way, for 256G,Only 30G is used, most of the memory resources are not used, can a server deploy multiple instances, is this good?
In Java, object pointers can be compressed to reduce their size, which is beneficial for performance. However, compressed OOPs are only effective up to a heap size of around 30 GiB. Beyond this limit, the JVM switches to 64-bit pointers, which increases memory consumption and can reduce performance. Keeping the heap size under 30 GiB ensures that compressed OOPs can be used effectively.
CrateDB uses memory for more than just its JVM heap. It uses off-heap buffers for better network communication and relies on the operating system’s file system cache for faster file access (mmap). The JVM itself also needs some memory. Therefore, it’s normal for CrateDB to use more memory than the amount set for just heap. Especially with large HDDs it might be beneficial to have more off-heap memory for caching available.
While you can run multiple CrateDB nodes on the same VM, they can’t share a common data folder. A benefit of e.g. running 3 nodes on one VM could be the ability to run rolling upgrades. Performance wise it largely depends on the use case.