Deploying a 2.8T MoE Model Locally: Can 8 GPUs Handle the VRAM Requirements?

    This article explores the feasibility of deploying a 2.8T Mixture of Experts (MoE) model on an 8-GPU setup. It analyzes model precision, memory constraints, and the performance trade-offs of CPU offloading. Additionally, it provides practical guidelines for downloading, vLLM configuration, KV cache estimation, quantization, deployment options, and an infrastructure selection checklist.

    1. Calculating Model Precision

    The model has 2.8 trillion parameters. If stored in BF16 (2 bytes per parameter), the weights would require approximately 5.6TB. However, the released weight files total 1.56TB, averaging about 0.56 bytes per parameter (roughly 4.5 bits). This indicates that the released weights have undergone mixed-precision or low-bit quantization, with most parameters likely near 4-bit. The exact precision should be verified against the model card and configuration files, as file size is only an estimation basis.

    2. Can 8 GPUs Hold All Weights?

    Eight 80GB GPUs provide a combined 640GB of VRAM. The 1.56TB weight files exceed this by about 920GB, not accounting for KV cache, activations, and framework overhead. Even with eight 192GB GPUs (1,536GB total), the full weights still cannot fit entirely in VRAM.

    Therefore, “starting with 8 GPUs” only indicates a sufficient GPU count, not sufficient VRAM. To run on 8 GPUs, a portion of the weights must be offloaded to host memory or NVMe drives and loaded into the GPUs on demand.

    3. The Speed Cost of Offloading

    In MoE models, only a subset of parameters is activated per token. This model activates 104B parameters per token, which translates to about 58GB at an average of 0.56 bytes per parameter.

    If all activated parameters come from host memory, they must be transferred via the PCIe bus. Assuming a PCIe 4.0 x16 effective bandwidth of around 25GB/s, the transfer time for a single token’s parameters would be about 2.3 seconds. This is a worst-case upper bound. In actual operation, tokens within the same batch share popular experts, and experts residing in VRAM do not need to be transferred repeatedly, resulting in significantly lower latency.

    Even so, offloading solutions are more suited for throughput-prioritized batch serving and are less friendly to low-latency interactive scenarios. Before going live, test Time to First Token (TTFT) and Tokens Per Second (TPS) using real request distributions.

    4. Download and Storage

    Downloading 1.56TB depends on bandwidth. At 100MB/s, it takes about 4.3 hours. At a 1Gbps link (effective ~110MB/s), about 4 hours. At 10Gbps, about 0.4 hours.

    Recommended download steps:

    1. Obtain SHA256 checksums for each shard from official release channels. Compare them individually after download, and re-download any failed shards.
    2. Use tools that support resume and multi-threaded sharding, such as aria2. This allows continuing from where it left off after an interruption.
    3. Store the model on an NVMe SSD. At 5GB/s read speed, loading 1.56TB takes about 5 minutes. On a standard 500MB/s network storage, it takes about 52 minutes. Cold start time directly depends on this step.

    5. Inference Framework Configuration

    Parameter names and versions vary across inference frameworks. Taking vLLM as an example, before launching, verify current version parameters using vllm serve --help and ensure the version matches the model release notes.

    1. vllm serve /mnt/nvme/model \
    2. --tensor-parallel-size 8 \
    3. --pipeline-parallel-size 1 \
    4. --enable-expert-parallel \
    5. --max-model-len 100000 \
    6. --kv-cache-dtype fp8 \
    7. --gpu-memory-utilization 0.90 \
    8. --cpu-offload-gb 200

    Parameter explanations: --tensor-parallel-size 8 means 8 GPUs participate in tensor parallelism, and expert parallelism shares these same 8 GPUs, making the total GPU count 8 with pipeline parallelism set to 1. --cpu-offload-gb 200 specifies the capacity each GPU can offload to host memory, totaling 1600GB across 8 GPUs. Host memory should be at least 2TB, leaving room for OS and cache. --max-model-len 100000 corresponds to a 100,000-token context. --kv-cache-dtype fp8 stores the KV Cache in 8-bit, reducing VRAM usage.

    6. KV Cache Estimation

    KV Cache consumption can be calculated using the following formula:

    KV Cache Bytes = 2 × Number of Layers × Number of KV Heads × Head Dimension × Bytes per Element × Context Length × Concurrent Requests

    The “2” represents the two caches for K and V. The number of layers, KV heads, and head dimension must be read from the model config file, not estimated. Each element takes 2 bytes in BF16 and 1 byte in FP8, halving the total usage.

    PagedAttention divides the KV Cache into fixed-size blocks allocated on demand, reducing VRAM fragmentation and improving utilization. It does not reduce the total demand, which is still determined by the formula above. When context length and concurrency increase simultaneously, VRAM will be exhausted first, so both must be included in the calculation.

    7. Quantization Precision and Rollback

    FP8 or INT8 quantization introduces precision loss, varying by task. Before deployment, compare results before and after quantization on your evaluation set, paying special attention to precision-sensitive tasks like coding, math reasoning, and tool calling.

    Rollback strategy: Keep the previous version’s weights and configuration files, using a symbolic link to point to the current version directory. If issues arise, switch the link back to the old directory and restart the service. Record the hash of the config file before each switch for traceability.

    8. License and Data Compliance

    Open-source licenses usually have explicit restrictions on commercial use, redistribution, and scale of use. Verify each clause before deployment. Private deployment keeps data within the enterprise intranet, but inference logs, caches, and monitoring data also contain sensitive information and must be desensitized and retained to the same standards.

    9. Choosing a Deployment Method

    Self-hosted GPU servers require the highest upfront investment, keep data entirely local, and may offer lower long-term unit costs, making them suitable for stable, high-load businesses.

    Renting cloud GPU instances requires low upfront investment and offers flexible scaling, but incurs continuous rental fees. Ensure that the instance’s VRAM, host memory, and local NVMe meet previous calculations when purchasing.

    Pay-as-you-go model services require no operations and are suitable for experiments and low-frequency calls. However, data must leave the local environment, and the model version and quantization method are determined by the provider, leaving users unable to roll back themselves.

    10. Selection Checklist

    1. Can VRAM plus host memory cover weights, KV Cache, and system overhead?
    2. Can the business tolerate the latency introduced by offloading?
    3. Is the time required for download, verification, and loading within an acceptable range?
    4. Does the license permit the intended use and user scale?
    5. Is the inference framework version consistent with the model release notes?
    6. Has an evaluation comparison been completed before and after quantization?
    7. Is a rollback version retained and available?

    Conclusion

    In summary, running such models on 8 GPUs is feasible, provided you accept the throughput limitations from offloading and collectively plan host memory, NVMe, and network capabilities.