dstackai / dstack

dstack is an open-source alternative to Kubernetes, designed to simplify development, training, and deployment of AI across any cloud or on-prem. It supports NVIDIA, AMD, and TPU.
https://dstack.ai/docs
Mozilla Public License 2.0
1.32k stars 98 forks source link

[Feature]: Local disks #1351

Open jvstme opened 2 months ago

jvstme commented 2 months ago

Context

Many cloud providers bundle one or several (e.g. 16) local disks with some instance types.

Local disks have these traits:

Here is how major cloud providers implement local disks:

Problem

dstack ignores local disks, so dstack users cannot benefit from their performance and capacity, even though they pay for them.

Possible solutions

Solution 1 — create an LVM volume over the local disks and use it as docker's data_root

This way, users will benefit from local disks' performance automatically, no configuration or special handling is needed. However, if users request more disk capacity in the run configuration than local disks have to offer, dstack will have to store data_root on the OS disk as usual, i.e. the local disks will still be ignored.

Solution 2 — create an LVM volume over the local disks and mount it to a directory within the container

This way, users will be able to use both the fixed local disks and the configurable OS disk, i.e. have flexible disk capacity. However, the environment will be different on instances with and without local disks, so users' code will have to be adjusted to use local disks.

r4victor commented 2 months ago

I think Solution 2 is perfectly fine as long as the local disks' mount point is clearly documented.

peterschmidt85 commented 1 month ago

This issue is stale because it has been open for 30 days with no activity.