How to Run MultiNode Inference on DeepSeek R1

Learn how to run DeepSeek R1 on a multi-node setup for faster inference. This guide covers setup, deployment, and best practices for efficient scaling.

WhiteFiber Infrastructure Team

15 min read

Published:

October 30, 2026

November 3, 2026

Two GPU server racks linked by illuminated orange connections

Table of Contents

    Last time we looked at DeepSeek R1, we explored what makes the model so powerful. In that post, we covered:

    ‍

    1. The training paradigm behind the "Aha moment" during reinforcement learning that led to its reasoning capabilities
    2. How DeepSeek trained DeepSeek R1 from DeepSeek R1 Zero
    3. How to run the model using SGLang

    ‍

    DeepSeek R1 is a 671-billion-parameter Mixture-of-Experts (MoE) model with 37 billion parameters active per token. Its weights need roughly 1.3 TB of graphics processing unit (GPU) memory in 16-bit brain floating point (BF16). At 8-bit floating point (FP8), they need about 671 GB.

    ‍

    On 80 GB GPUs, multi-node inference was about fitting the model at all. An 8-GPU NVIDIA B300 node carries about 2.3 TB of high-bandwidth memory (HBM), so the full model now fits on one machine. Teams that deploy DeepSeek R1 across nodes today are buying concurrency, key-value (KV) cache for long reasoning traces, and throughput.

    ‍

    In this post, we walk through:

    ‍

    1. Hardware requirements for the full and distilled models
    2. Considerations when choosing a distributed setup for DeepSeek R1
    3. How parallelism strategies split the model across GPUs
    4. Serving the model on a multi-node distributed deployment with SGLang

    ‍

    ‍

    DeepSeek R1 hardware requirements: Full model vs. distilled models

    ‍

    The full 671B model is a data center workload; the distilled models are a workstation workload. Weights are only the floor: DeepSeek lists a 128K-token context window (per DeepSeek's model card), and long reasoning traces fill the rest with KV cache.

    ‍

    ConfigurationGPUsTotal GPU memoryFits full DeepSeek R1?
    Microsoft Azure blog vLLM benchmark (third party): one 8×H100 80 GB node8640 GBNo
    Microsoft Azure blog vLLM benchmark (third party): two 8×H100 80 GB nodes161,280 GBYes at FP8, thin KV cache headroom
    One 8×B300 node8About 2.3 TB HBM3eYes; about 1.6 TB left for KV cache at FP8
    Two 8×B300 nodes16About 4.2 TB HBM3eYes, with room for high concurrency
    GB300 NVL72 rack72About 20.7 TB HBM3eYes, with room for replicas or wide expert parallelism
    VR200 NVL72 rack72About 20.7 TB HBM4Yes, with room for replicas or wide expert parallelism

    ‍

    The distills are smaller Qwen and Llama models fine-tuned on reasoning traces from the full model. Jan's local setup guide lists these minimum video memory (VRAM) figures and recommends 4-bit (Q4) quantization as the default:

    ‍

    Distilled modelMinimum VRAM
    Qwen 1.5B6 GB+
    Qwen 7B or Llama 8B8 GB+
    Qwen 14B or Qwen 32B20 GB+
    Llama 70B48 GB+

    ‍

    Running DeepSeek R1 locally means running a distill. The full model needs data center hardware.

    ‍

    ‍

    Distributed vs. single-node machines for DeepSeek R1

    ‍

    Since DeepSeek R1 runs on a single 8×B300 machine with room to spare, why go distributed? There are two main considerations:

    ‍

    Cost

    One node is enough for the full model. The tradeoff is concurrency and KV cache headroom. Every added node brings more GPUs, network ports, and operational surface area; contact us for current GPU rates.

    ‍

    Speed

    Increasing the number of nodes can increase tokens generated per second for inference. Because of communication overhead between nodes, that gain is aggregate throughput across requests. A single request rarely gets faster when every layer waits on a network hop.

    ‍

    In short, more nodes buy more aggregate throughput across concurrent requests, at the cost of more hardware to operate.

    ‍

    Example: A platform team serves DeepSeek R1 to 300 engineers, with reasoning traces averaging 20K tokens. It has three options:

    1. One 8×B300 node: about 2.3 TB of HBM3e and no inter-node hop. It’s the simplest option until the KV cache fills at peak.
    2. Two 8×B300 nodes: about 4.6 TB, enough for two independent replicas. Concurrency roughly doubles, and so does the hardware to keep healthy.
    3. One VR200 or GB300 NVL72 rack: 72 GPUs and about 20.7 TB of HBM in one NVLink domain. Wide expert parallelism never leaves the low-latency, high-bandwidth NVLink backplane interconnect.

    ‍

    Our default is two replicas, because replicas fail independently. One instance across both nodes, as in the guide below, suits very long contexts.

    ‍

    ‍

    Distributed inference explained: TP, PP, DP and EP

    ‍

    Distributed inference for a large language model (LLM) mixes four strategies, best compared by what each sends over the wire:

    ‍

    1. Tensor parallelism (TP): splits each layer's weights across GPUs. Every layer ends in an all-reduce, so cross-node TP loads the inter-node link constantly.
    2. Pipeline parallelism (PP): assigns consecutive layers to each node. Heavy traffic stays on NVLink, and only activations cross nodes.
    3. Data parallelism (DP): runs full replicas that share nothing during a request. It scales concurrency but can't help a model that doesn't fit.
    4. Expert parallelism (EP): spreads DeepSeek R1's 256 routed experts (plus one shared expert) per MoE layer across GPUs, per DeepSeek's published model configuration. All-to-all exchanges route tokens to their experts, matching the MoE design.

    ‍

    This guide uses --tp 16 across two nodes as a quick proof-of-concept setup. Note on production scaling: Cross-node Tensor Parallelism increases latency because every transformer layer must synchronize over inter-node network links. For production multi-node deployments, stick to TP 8 per node combined with Pipeline Parallelism (PP = number of nodes) or DP Attention with Expert Parallelism (EP).

    ‍

    ‍

    SGLang multi-node setup: Running DeepSeek R1 on two nodes

    ‍

    Multi-node GPU server architecture

    ‍

    1

    Open a Secure Shell (SSH) session on your machine and mount your volume for storage in /mnt/. Next, download DeepSeek R1 to the mounted volume. This may take a while: the FP8 model weights are about 671 GB for raw tensors, or ~690 GB on disk including metadata and scaling factors.

    ‍

    The weights must sit at the same path on both nodes, or on a shared volume.

    ‍

    git clone https://huggingface.co/deepseek-ai/DeepSeek-R1

    ‍

    or

    ‍

    hf download deepseek-ai/DeepSeek-R1 --local-dir <path to /mnt/ dir>

    ‍

    Once complete, install SGLang in a virtual environment.

    ‍

    python -m venv venv
    source venv/bin/activate
    pip install --upgrade pip
    pip install uv
    uv pip install "sglang[all]" --find-links https://flashinfer.ai/whl/cu130/torch2.11/flashinfer-python

    ‍

    These pins reflect early 2025 releases for Compute Unified Device Architecture (CUDA) 12.4 and PyTorch 2.5. B300 GPUs need CUDA 12.9 or later, and current SGLang releases require CUDA 13, so check the current SGLang install docs.

    ‍

    This will complete the machine setup. Be sure to do this for each node, with the same SGLang version on both.

    ‍

    2

    Identify your host Internet Protocol (IP) address

    ‍

    You can find the host IP using vim /etc/hosts or hostname -I. Locate your machine by name, grab the host IP, and save this value for later. We will use this as our host machine IP value when we launch.

    ‍

    3

    Identify your GLOO_SOCKET_IFNAME variable value using ip route get 1.1.1.1 or ip addr to select the active network interface carrying the host IP (e.g. eth0 or mlx5_ib0), avoiding out-of-band management interfaces. Then export it on both nodes, along with NCCL_SOCKET_IFNAME:

    ‍

    export GLOO_SOCKET_IFNAME=<interface>
    export NCCL_SOCKET_IFNAME=<interface>

    ‍

    The NVIDIA Collective Communications Library (NCCL) handles GPU traffic. On InfiniBand (IB) clusters, NCCL moves tensors over IB, and the socket interface mainly carries setup traffic.

    ‍

    With that, we have completed our machine setup and can launch our distributed SGLang server.

    ‍

    4

    Launch the server

    ‍

    From the host node, launch the server with the following command. Replace the host machine IP with the value you saved earlier, and paste the path to the DeepSeek R1 model files in the --model-path parameter.

    ‍

    python3 -m sglang.launch_server --model-path <path to deepseek-R1> --host 0.0.0.0 --tp 16 --dist-init-addr <your host machine ip>:5000 --nnodes 2 --node-rank 0 --trust-remote-code

    ‍

    From the additional node, launch the server with:

    ‍

    python3 -m sglang.launch_server --model-path <path to deepseek-R1> --tp 16 --dist-init-addr <your host machine ip>:5000 --nnodes 2 --node-rank 1 --trust-remote-code

    ‍

    Here, --tp 16 means 2 nodes × 8 B300 GPUs, --dist-init-addr points to the rank 0 node, and --node-rank is 0 or 1.

    ‍

    This will take a few minutes to load. Note that this can be scaled up further by adjusting the nnodes and node-rank values to add more machines. Keep --tp equal to the total GPU count.

    ‍

    5

    Much like we showed in the previous article, we can interact with our new SGLang endpoint using Python or cURL. The server exposes an OpenAI-compatible application programming interface (API) on port 30000 by default.

    ‍

    To send a request with cURL, paste the following command into a new terminal window connected to the distributed network:

    ‍

    curl -s http://<your host machine ip>:30000/v1/chat/completions \
    -H "Content-Type: application/json" \
    -d '{"model": "deepseek-ai/DeepSeek-R1", "messages": [{"role": "user", "content": "What is the capital of France?"}]}'

    ‍

    You can then adjust the results by changing various settings in the -d payload, such as the prompt or temperature.

    ‍

    Alternatively, we can make requests using Python. For simplicity, we will use the requests library for this demo:

    ‍

    import requests
    
    port = 30000
    url = f"http://<your host machine ip>:{port}/v1/chat/completions"
    
    data = { "model": "deepseek-ai/DeepSeek-R1", "messages": [{"role": "user", "content": "What is the capital of France?"}], }
    
    response = requests.post(url, json=data)
    print(response.json())

    ‍

    With this, we should get a long reasoning response to the simple question "What is the capital of France?" Expect it to deliberate about Paris. We recommend testing DeepSeek R1 with harder problem-solving or math tests to see if it fits your deployment use case.

    ‍

    For request formatting options, see the SGLang send requests page.

    ‍

    ‍

    What to expect: Throughput, latency, and reasoning tokens

    ‍

    Reasoning tokens drive capacity planning for DeepSeek R1 more than parameter count does. A benchmark published on Microsoft's Azure blog ran vLLM on two 8×H100 nodes, comparing DeepSeek R1 with Llama 3.1 8B on the same hardware:

    ‍

    1. Output volume: about 31× more tokens per request.
    2. Generation speed: about 54× slower.
    3. Time to first token (TTFT): about 6× slower.
    4. Inter-token latency: about 3× slower.
    5. One simple prompt: a "9.11 vs. 9.8" comparison took 1,162 completion tokens versus 37, and Llama answered wrong.

    ‍

    B300 memory bandwidth changes the absolute speeds, but the token ratio is a property of the model. Size for KV cache and concurrent traces first.

    ‍

    Example: DeepSeek R1 uses a multi-head latent attention (MLA) cache. By our math from the model configuration: 512 + 64 = 576 values per layer, 61 layers, about 70 KB per token in BF16. Note that under pure Tensor Parallelism, the KV cache is duplicated across all GPUs in the TP group, increasing memory usage significantly. To fit this workload cleanly without duplication, enable DP Attention (--attn-dp-size) so each GPU only holds its designated slice of the cache. That's about 2.3 GB per session and roughly 460 GB in total logical KV cache footprint when using DP Attention (--attn-dp-size) to prevent TP ranks from duplicating the cache.

    ‍

    For hardware comparisons, MLPerf Inference includes an independent DeepSeek R1 scenario.

    ‍

    ‍

    Advanced considerations: Interconnect, expert parallelism and vLLM

    ‍

    Network fabric between nodes

    ‍

    Production clusters run NVLink inside the node and IB or Remote Direct Memory Access over Converged Ethernet (RoCE) between nodes (see our Ethernet vs. InfiniBand comparison). In the same H100 benchmark, DeepSeek R1 used about 14% of available IB bandwidth.

    ‍

    Misconfigured interfaces cause trouble long before bandwidth does. On GB300 NVL72, each GPU also gets 800 Gb/s of scale-out bandwidth.

    ‍

    DP Attention and expert parallelism in SGLang

    ‍

    Under pure TP, every GPU keeps a full copy of the MLA cache, because DeepSeek's MLA has only one KV head. SGLang's DP Attention reduces KV cache duplication across TP ranks, enabled with --attn-dp-size in current releases (the older --enable-dp-attention flag is deprecated). Expert parallelism options then spread experts across GPUs.

    ‍

    Our judgment: start with --tp 16, then move to DP Attention plus EP once concurrency becomes the constraint. On B300-class nodes, KV cache context limits usually become the constraint before compute throughput does.

    ‍

    vLLM as an alternative

    ‍

    vLLM runs multi-node inference for DeepSeek R1 through Ray, or natively with --data-parallel-size and --enable-expert-parallel. Multi-node vLLM setups commonly set NCCL_SOCKET_IFNAME (and GLOO_SOCKET_IFNAME when vLLM picks the wrong network interface) to the right interface, per the vLLM docs. Teams already on vLLM should stay; new teams should benchmark both.

    ‍

    Common failure modes

    ‍

    1. Unreachable init address: a firewall blocks port 5000, so rank 1 can't reach --dist-init-addr.
    2. Wrong socket interface: Gloo or NCCL binds to a management interface, and setup hangs.
    3. Mismatched nodes: different model paths or SGLang versions across nodes break startup.
    4. Out-of-memory (OOM) errors: oversized contexts exhaust KV cache, so cap --context-length at the longest real trace.

    ‍

    ‍

    Running multi-node inference on WhiteFiber

    ‍

    For DeepSeek R1, multi-node inference adds throughput and concurrency; it doesn't make a single request faster. We recommend a distributed setup when concurrency or long contexts outgrow one 8×B300 node. For experimenting, the distills run on a single workstation GPU.

    ‍

    We're a GPU cloud provider, and our B300 nodes, GB300 and VR200 NVL72 racks run on InfiniBand and Ethernet fabrics designed alongside the GPUs. Matched storage keeps about 690 GB weight loads from becoming the bottleneck during restarts.

    ‍

    GPU count alone doesn't equal performance: a 16-GPU cluster on a misconfigured fabric can serve fewer traces than one well-tuned node. Customers work with our engineers, not ticket queues, and governance controls for regulated industries are built in from day one.

    ‍

    ‍

    ‍

    ‍

    FAQ

    ‍

    Can DeepSeek R1 run locally?

    The distilled versions (1.5B to 70B parameters) run locally on roughly 6 GB to 48 GB of VRAM, per Jan's guide. The full 671B model needs data center hardware, such as one 8×B300 node.

    ‍

    ‍

    How many GPUs does the full DeepSeek R1 model need?

    On older hardware, a published benchmark needed 16 H100 GPUs across two nodes at FP8. A single 8×B300 node holds the full model, and teams add nodes or move to GB300 NVL72 for concurrency.

    ‍

    ‍

    Is SGLang or vLLM better for multi-node DeepSeek R1?

    Both work: SGLang includes MLA-specific optimizations for DeepSeek models plus DP Attention support, and vLLM suits teams already running it. Benchmark both on real traffic before committing.

    ‍

    ‍

    What network does multi-node inference need between nodes?

    A low-latency IB or RoCE fabric, with GLOO_SOCKET_IFNAME and NCCL_SOCKET_IFNAME set correctly. DeepSeek R1 inference rarely saturates IB bandwidth, but it is sensitive to latency and misconfiguration.

    ‍

    ‍

    ‍

    ‍