Skip to content

[Bug]: cannot startup two Qwen/Qwen2.5-0.5B-Instruct on a 8G 4060ti #19125

@xuechenwang-cienet

Description

@xuechenwang-cienet

Your current environment

The output of python collect_env.py
INFO 06-04 12:04:41 [__init__.py:243] Automatically detected platform cuda.
Collecting environment information...
==============================
        System Info
==============================
OS                           : Ubuntu 22.04.5 LTS (x86_64)
GCC version                  : (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0
Clang version                : Could not collect
CMake version                : version 3.22.1
Libc version                 : glibc-2.35

==============================
       PyTorch Info
==============================
PyTorch version              : 2.7.0+cu126
Is debug build               : False
CUDA used to build PyTorch   : 12.6
ROCM used to build PyTorch   : N/A

==============================
      Python Environment
==============================
Python version               : 3.10.12 (main, Feb  4 2025, 14:57:36) [GCC 11.4.0] (64-bit runtime)
Python platform              : Linux-6.8.0-58-generic-x86_64-with-glibc2.35

==============================
       CUDA / GPU Info
==============================
Is CUDA available            : True
CUDA runtime version         : 12.4.131
CUDA_MODULE_LOADING set to   : LAZY
GPU models and configuration : GPU 0: NVIDIA GeForce RTX 4060 Ti
Nvidia driver version        : 550.54.15
cuDNN version                : Probably one of the following:
/usr/lib/x86_64-linux-gnu/libcudnn.so.8.2.4
/usr/lib/x86_64-linux-gnu/libcudnn_adv_infer.so.8.2.4
/usr/lib/x86_64-linux-gnu/libcudnn_adv_train.so.8.2.4
/usr/lib/x86_64-linux-gnu/libcudnn_cnn_infer.so.8.2.4
/usr/lib/x86_64-linux-gnu/libcudnn_cnn_train.so.8.2.4
/usr/lib/x86_64-linux-gnu/libcudnn_ops_infer.so.8.2.4
/usr/lib/x86_64-linux-gnu/libcudnn_ops_train.so.8.2.4
HIP runtime version          : N/A
MIOpen runtime version       : N/A
Is XNNPACK available         : True

==============================
          CPU Info
==============================
Architecture:                         x86_64
CPU op-mode(s):                       32-bit, 64-bit
Address sizes:                        39 bits physical, 48 bits virtual
Byte Order:                           Little Endian
CPU(s):                               16
On-line CPU(s) list:                  0-15
Vendor ID:                            GenuineIntel
Model name:                           13th Gen Intel(R) Core(TM) i5-13400
CPU family:                           6
Model:                                191
Thread(s) per core:                   2
Core(s) per socket:                   10
Socket(s):                            1
Stepping:                             2
CPU max MHz:                          2500.0000
CPU min MHz:                          800.0000
BogoMIPS:                             4992.00
Flags:                                fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc art arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf tsc_known_freq pni pclmulqdq dtes64 monitor ds_cpl vmx est tm2 ssse3 sdbg fma cx16 xtpr pdcm sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm 3dnowprefetch cpuid_fault ssbd ibrs ibpb stibp ibrs_enhanced tpr_shadow flexpriority ept vpid ept_ad fsgsbase tsc_adjust bmi1 avx2 smep bmi2 erms invpcid rdseed adx smap clflushopt clwb intel_pt sha_ni xsaveopt xsavec xgetbv1 xsaves split_lock_detect user_shstk avx_vnni dtherm arat pln pts hwp hwp_notify hwp_act_window hwp_epp hwp_pkg_req hfi vnmi umip pku ospke waitpkg gfni vaes vpclmulqdq rdpid movdiri movdir64b fsrm md_clear serialize arch_lbr ibt flush_l1d arch_capabilities
Virtualization:                       VT-x
L1d cache:                            416 KiB (10 instances)
L1i cache:                            448 KiB (10 instances)
L2 cache:                             9.5 MiB (7 instances)
L3 cache:                             20 MiB (1 instance)
NUMA node(s):                         1
NUMA node0 CPU(s):                    0-15
Vulnerability Gather data sampling:   Not affected
Vulnerability Itlb multihit:          Not affected
Vulnerability L1tf:                   Not affected
Vulnerability Mds:                    Not affected
Vulnerability Meltdown:               Not affected
Vulnerability Mmio stale data:        Not affected
Vulnerability Reg file data sampling: Mitigation; Clear Register File
Vulnerability Retbleed:               Not affected
Vulnerability Spec rstack overflow:   Not affected
Vulnerability Spec store bypass:      Mitigation; Speculative Store Bypass disabled via prctl
Vulnerability Spectre v1:             Mitigation; usercopy/swapgs barriers and __user pointer sanitization
Vulnerability Spectre v2:             Mitigation; Enhanced / Automatic IBRS; IBPB conditional; RSB filling; PBRSB-eIBRS SW sequence; BHI BHI_DIS_S
Vulnerability Srbds:                  Not affected
Vulnerability Tsx async abort:        Not affected

==============================
Versions of relevant libraries
==============================
[pip3] numpy==2.1.3
[pip3] nvidia-cublas-cu12==12.6.4.1
[pip3] nvidia-cuda-cupti-cu12==12.6.80
[pip3] nvidia-cuda-nvrtc-cu12==12.6.77
[pip3] nvidia-cuda-runtime-cu12==12.6.77
[pip3] nvidia-cudnn-cu12==9.5.1.17
[pip3] nvidia-cufft-cu12==11.3.0.4
[pip3] nvidia-cufile-cu12==1.11.1.6
[pip3] nvidia-curand-cu12==10.3.7.77
[pip3] nvidia-cusolver-cu12==11.7.1.2
[pip3] nvidia-cusparse-cu12==12.5.4.2
[pip3] nvidia-cusparselt-cu12==0.6.3
[pip3] nvidia-nccl-cu12==2.26.2
[pip3] nvidia-nvjitlink-cu12==12.6.85
[pip3] nvidia-nvtx-cu12==12.6.77
[pip3] pyzmq==26.4.0
[pip3] torch==2.7.0
[pip3] torchaudio==2.7.0
[pip3] torchvision==0.22.0
[pip3] transformers==4.51.2
[pip3] triton==3.3.0
[conda] Could not collect

==============================
         vLLM Info
==============================
ROCM Version                 : Could not collect
Neuron SDK Version           : N/A
vLLM Version                 : 0.9.0.1
vLLM Build Flags:
  CUDA Archs: Not Set; ROCm: Disabled; Neuron: Disabled
GPU Topology:
        GPU0    CPU Affinity    NUMA Affinity   GPU NUMA ID
GPU0     X      0-15    0               N/A

Legend:

  X    = Self
  SYS  = Connection traversing PCIe as well as the SMP interconnect between NUMA nodes (e.g., QPI/UPI)
  NODE = Connection traversing PCIe as well as the interconnect between PCIe Host Bridges within a NUMA node
  PHB  = Connection traversing PCIe as well as a PCIe Host Bridge (typically the CPU)
  PXB  = Connection traversing multiple PCIe bridges (without traversing the PCIe Host Bridge)
  PIX  = Connection traversing at most a single PCIe bridge
  NV#  = Connection traversing a bonded set of # NVLinks

==============================
     Environment Variables
==============================
LD_LIBRARY_PATH=/usr/local/cuda-12.4/lib64
CUDA_HOME=/usr/local/cuda-12.4
CUDA_HOME=/usr/local/cuda-12.4
NCCL_CUMEM_ENABLE=0
PYTORCH_NVML_BASED_CUDA_CHECK=1
TORCHINDUCTOR_COMPILE_THREADS=1
CUDA_MODULE_LOADING=LAZY

The output of nvidia-smi
python -m vllm.entrypoints.openai.api_server --model Qwen/Qwen2.5-0.5B-Instruct --gpu_memory_utilization 0.4
Wed Jun  4 12:06:48 2025       
+-----------------------------------------------------------------------------------------+
| NVIDIA-SMI 550.54.15              Driver Version: 550.54.15      CUDA Version: 12.4     |
|-----------------------------------------+------------------------+----------------------+
| GPU  Name                 Persistence-M | Bus-Id          Disp.A | Volatile Uncorr. ECC |
| Fan  Temp   Perf          Pwr:Usage/Cap |           Memory-Usage | GPU-Util  Compute M. |
|                                         |                        |               MIG M. |
|=========================================+========================+======================|
|   0  NVIDIA GeForce RTX 4060 Ti     Off |   00000000:01:00.0 Off |                  N/A |
|  0%   33C    P8              9W /  160W |    3578MiB /   8188MiB |      0%      Default |
|                                         |                        |                  N/A |
+-----------------------------------------+------------------------+----------------------+
                                                                                         
+-----------------------------------------------------------------------------------------+
| Processes:                                                                              |
|  GPU   GI   CI        PID   Type   Process name                              GPU Memory |
|        ID   ID                                                               Usage      |
|=========================================================================================|
|    0   N/A  N/A      2261      C   ...ev/llm_server/vllm/.venv/bin/python       3572MiB |
+-----------------------------------------------------------------------------------------+

🐛 Describe the bug

I want to run two small model on my 8GB GPU.
"gpu_memory_utilization" should be help me to allocate memory for those 2 vLLM instance.

So I conducted an experiment to verify this function.

Steps summary:

Step1, start Qwen/Qwen2.5-0.5B-Instruct with gpu_memory_utilization 0.4.
Step2, observe the VRAM usage with nvidia-smi, 3578MiB/8188MiB has already been occupied.
Step3, start another vLLM instance with the same arguments, and listening on another port. But got exception: "No available memory for the cache blocks."
Step4, increase gpu_memory_utilization to 0.8 and start another vLLM instance with listening on another port. Both of 2 vLLM instances could work. 6768MiB/8188MiB  has been occupied by 2 instances.

According to the user manual, and if I understand correctly.
The gpu_memory_utilization of 2 vLLMs, 0.4+0.4 should be correct, but the actual situation is 0.4+0.8.

I guess that the denominator of gpu_memory_utilization is the available VRAM size, rather than the total VRAM size.
I think this is a bug.

Steps and logs:

Step1, start Qwen/Qwen2.5-0.5B-Instruct with gpu_memory_utilization 0.4.
python -m vllm.entrypoints.openai.api_server --model Qwen/Qwen2.5-0.5B-Instruct --gpu_memory_utilization 0.4
Step2, observe the VRAM usage with nvidia-smi,3578MiB/8188MiB has already been occupied.
xcwang@xcwang-B760M-POWER:~/dev/llm_server/vllm$ nvidia-smi 
Wed Jun  4 12:17:02 2025       
+-----------------------------------------------------------------------------------------+
| NVIDIA-SMI 550.54.15              Driver Version: 550.54.15      CUDA Version: 12.4     |
|-----------------------------------------+------------------------+----------------------+
| GPU  Name                 Persistence-M | Bus-Id          Disp.A | Volatile Uncorr. ECC |
| Fan  Temp   Perf          Pwr:Usage/Cap |           Memory-Usage | GPU-Util  Compute M. |
|                                         |                        |               MIG M. |
|=========================================+========================+======================|
|   0  NVIDIA GeForce RTX 4060 Ti     Off |   00000000:01:00.0 Off |                  N/A |
|  0%   33C    P8              8W /  160W |    3578MiB /   8188MiB |      0%      Default |
|                                         |                        |                  N/A |
+-----------------------------------------+------------------------+----------------------+
                                                                                         
+-----------------------------------------------------------------------------------------+
| Processes:                                                                              |
|  GPU   GI   CI        PID   Type   Process name                              GPU Memory |
|        ID   ID                                                               Usage      |
|=========================================================================================|
|    0   N/A  N/A      2261      C   ...ev/llm_server/vllm/.venv/bin/python       3572MiB |
+-----------------------------------------------------------------------------------------+
xcwang@xcwang-B760M-POWER:~/dev/llm_server/vllm$ 
Step3, start another vLLM instance with the same arguments, and listening on another port.

Got exception:

ValueError: No available memory for the cache blocks. Try increasing `gpu_memory_utilization` when initializing the engine.

Full logs:

(.venv) xcwang@xcwang-B760M-POWER:~/dev/llm_server/vllm$ python -m vllm.entrypoints.openai.api_server --model Qwen/Qwen2.5-0.5B-Instruct --gpu_memory_utilization 0.4 --port 11536
INFO 06-04 12:00:20 [__init__.py:243] Automatically detected platform cuda.
INFO 06-04 12:00:22 [__init__.py:31] Available plugins for group vllm.general_plugins:
INFO 06-04 12:00:22 [__init__.py:33] - lora_filesystem_resolver -> vllm.plugins.lora_resolvers.filesystem_resolver:register_filesystem_resolver
INFO 06-04 12:00:22 [__init__.py:36] All plugins in this group will be loaded. Set `VLLM_PLUGINS` to control which plugins to load.
INFO 06-04 12:00:23 [api_server.py:1289] vLLM API server version 0.9.0.1
INFO 06-04 12:00:23 [cli_args.py:300] non-default args: {'port': 11536, 'model': 'Qwen/Qwen2.5-0.5B-Instruct', 'gpu_memory_utilization': 0.4}
INFO 06-04 12:00:30 [config.py:793] This model supports multiple tasks: {'score', 'embed', 'generate', 'reward', 'classify'}. Defaulting to 'generate'.
INFO 06-04 12:00:30 [config.py:2118] Chunked prefill is enabled with max_num_batched_tokens=2048.
INFO 06-04 12:00:34 [__init__.py:243] Automatically detected platform cuda.
INFO 06-04 12:00:37 [core.py:438] Waiting for init message from front-end.
INFO 06-04 12:00:37 [__init__.py:31] Available plugins for group vllm.general_plugins:
INFO 06-04 12:00:37 [__init__.py:33] - lora_filesystem_resolver -> vllm.plugins.lora_resolvers.filesystem_resolver:register_filesystem_resolver
INFO 06-04 12:00:37 [__init__.py:36] All plugins in this group will be loaded. Set `VLLM_PLUGINS` to control which plugins to load.
INFO 06-04 12:00:37 [core.py:65] Initializing a V1 LLM engine (v0.9.0.1) with config: model='Qwen/Qwen2.5-0.5B-Instruct', speculative_config=None, tokenizer='Qwen/Qwen2.5-0.5B-Instruct', skip_tokenizer_init=False, tokenizer_mode=auto, revision=None, override_neuron_config={}, tokenizer_revision=None, trust_remote_code=False, dtype=torch.bfloat16, max_seq_len=32768, download_dir=None, load_format=auto, tensor_parallel_size=1, pipeline_parallel_size=1, disable_custom_all_reduce=False, quantization=None, enforce_eager=False, kv_cache_dtype=auto,  device_config=cuda, decoding_config=DecodingConfig(backend='auto', disable_fallback=False, disable_any_whitespace=False, disable_additional_properties=False, reasoning_backend=''), observability_config=ObservabilityConfig(show_hidden_metrics_for_version=None, otlp_traces_endpoint=None, collect_detailed_traces=None), seed=0, served_model_name=Qwen/Qwen2.5-0.5B-Instruct, num_scheduler_steps=1, multi_step_stream_outputs=True, enable_prefix_caching=True, chunked_prefill_enabled=True, use_async_output_proc=True, pooler_config=None, compilation_config={"level": 3, "custom_ops": ["none"], "splitting_ops": ["vllm.unified_attention", "vllm.unified_attention_with_output"], "compile_sizes": [], "inductor_compile_config": {"enable_auto_functionalized_v2": false}, "use_cudagraph": true, "cudagraph_num_of_warmups": 1, "cudagraph_capture_sizes": [512, 504, 496, 488, 480, 472, 464, 456, 448, 440, 432, 424, 416, 408, 400, 392, 384, 376, 368, 360, 352, 344, 336, 328, 320, 312, 304, 296, 288, 280, 272, 264, 256, 248, 240, 232, 224, 216, 208, 200, 192, 184, 176, 168, 160, 152, 144, 136, 128, 120, 112, 104, 96, 88, 80, 72, 64, 56, 48, 40, 32, 24, 16, 8, 4, 2, 1], "max_capture_size": 512}
2025-06-04 12:00:37,853 - INFO - flashinfer.jit: Prebuilt kernels not found, using JIT backend
WARNING 06-04 12:00:38 [utils.py:2671] Methods determine_num_available_blocks,device_config,get_cache_block_size_bytes,initialize_cache not implemented in <vllm.v1.worker.gpu_worker.Worker object at 0x7b0102e19ba0>
INFO 06-04 12:00:38 [parallel_state.py:1064] rank 0 in world size 1 is assigned as DP rank 0, PP rank 0, TP rank 0, EP rank 0
INFO 06-04 12:00:38 [topk_topp_sampler.py:48] Using FlashInfer for top-p & top-k sampling.
INFO 06-04 12:00:38 [gpu_model_runner.py:1531] Starting to load model Qwen/Qwen2.5-0.5B-Instruct...
INFO 06-04 12:00:38 [cuda.py:217] Using Flash Attention backend on V1 engine.
INFO 06-04 12:00:38 [backends.py:35] Using InductorAdaptor
Loading safetensors checkpoint shards:   0% Completed | 0/1 [00:00<?, ?it/s]
Loading safetensors checkpoint shards: 100% Completed | 1/1 [00:00<00:00,  7.01it/s]
Loading safetensors checkpoint shards: 100% Completed | 1/1 [00:00<00:00,  7.00it/s]

INFO 06-04 12:00:38 [default_loader.py:280] Loading weights took 0.16 seconds
INFO 06-04 12:00:38 [gpu_model_runner.py:1549] Model loading took 0.9271 GiB and 0.321312 seconds
INFO 06-04 12:00:44 [backends.py:459] Using cache directory: /home/xcwang/.cache/vllm/torch_compile_cache/3112b147ed/rank_0_0 for vLLM's torch.compile
INFO 06-04 12:00:44 [backends.py:469] Dynamo bytecode transform time: 5.56 s
INFO 06-04 12:00:48 [backends.py:132] Directly load the compiled graph(s) for shape None from the cache, took 3.756 s
INFO 06-04 12:00:49 [monitor.py:33] torch.compile takes 5.56 s in total
2025-06-04 12:00:49,201 - INFO - flashinfer.jit: Loading JIT ops: sampling
/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/torch/utils/cpp_extension.py:2356: UserWarning: TORCH_CUDA_ARCH_LIST is not set, all archs for visible cards are included for compilation. 
If this is not desired, please set os.environ['TORCH_CUDA_ARCH_LIST'].
  warnings.warn(
/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/torch/utils/cpp_extension.py:2356: UserWarning: TORCH_CUDA_ARCH_LIST is not set, all archs for visible cards are included for compilation. 
If this is not desired, please set os.environ['TORCH_CUDA_ARCH_LIST'].
  warnings.warn(
2025-06-04 12:00:49,218 - INFO - flashinfer.jit: Finished loading JIT ops: sampling
ERROR 06-04 12:00:49 [core.py:500] EngineCore failed to start.
ERROR 06-04 12:00:49 [core.py:500] Traceback (most recent call last):
ERROR 06-04 12:00:49 [core.py:500]   File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/engine/core.py", line 491, in run_engine_core
ERROR 06-04 12:00:49 [core.py:500]     engine_core = EngineCoreProc(*args, **kwargs)
ERROR 06-04 12:00:49 [core.py:500]   File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/engine/core.py", line 390, in __init__
ERROR 06-04 12:00:49 [core.py:500]     super().__init__(vllm_config, executor_class, log_stats,
ERROR 06-04 12:00:49 [core.py:500]   File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/engine/core.py", line 78, in __init__
ERROR 06-04 12:00:49 [core.py:500]     self._initialize_kv_caches(vllm_config)
ERROR 06-04 12:00:49 [core.py:500]   File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/engine/core.py", line 141, in _initialize_kv_caches
ERROR 06-04 12:00:49 [core.py:500]     kv_cache_configs = [
ERROR 06-04 12:00:49 [core.py:500]   File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/engine/core.py", line 142, in <listcomp>
ERROR 06-04 12:00:49 [core.py:500]     get_kv_cache_config(vllm_config, kv_cache_spec_one_worker,
ERROR 06-04 12:00:49 [core.py:500]   File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/core/kv_cache_utils.py", line 703, in get_kv_cache_config
ERROR 06-04 12:00:49 [core.py:500]     check_enough_kv_cache_memory(vllm_config, kv_cache_spec, available_memory)
ERROR 06-04 12:00:49 [core.py:500]   File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/core/kv_cache_utils.py", line 532, in check_enough_kv_cache_memory
ERROR 06-04 12:00:49 [core.py:500]     raise ValueError("No available memory for the cache blocks. "
ERROR 06-04 12:00:49 [core.py:500] ValueError: No available memory for the cache blocks. Try increasing `gpu_memory_utilization` when initializing the engine.
Process EngineCore_0:
Traceback (most recent call last):
  File "/usr/lib/python3.10/multiprocessing/process.py", line 314, in _bootstrap
    self.run()
  File "/usr/lib/python3.10/multiprocessing/process.py", line 108, in run
    self._target(*self._args, **self._kwargs)
  File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/engine/core.py", line 504, in run_engine_core
    raise e
  File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/engine/core.py", line 491, in run_engine_core
    engine_core = EngineCoreProc(*args, **kwargs)
  File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/engine/core.py", line 390, in __init__
    super().__init__(vllm_config, executor_class, log_stats,
  File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/engine/core.py", line 78, in __init__
    self._initialize_kv_caches(vllm_config)
  File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/engine/core.py", line 141, in _initialize_kv_caches
    kv_cache_configs = [
  File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/engine/core.py", line 142, in <listcomp>
    get_kv_cache_config(vllm_config, kv_cache_spec_one_worker,
  File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/core/kv_cache_utils.py", line 703, in get_kv_cache_config
    check_enough_kv_cache_memory(vllm_config, kv_cache_spec, available_memory)
  File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/core/kv_cache_utils.py", line 532, in check_enough_kv_cache_memory
    raise ValueError("No available memory for the cache blocks. "
ValueError: No available memory for the cache blocks. Try increasing `gpu_memory_utilization` when initializing the engine.
[rank0]:[W604 12:00:49.471117014 ProcessGroupNCCL.cpp:1476] Warning: WARNING: destroy_process_group() was not called before program exit, which can leak resources. For more info, please see https://pytorch.org/docs/stable/distributed.html#shutdown (function operator())
Traceback (most recent call last):
  File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.10/runpy.py", line 86, in _run_code
    exec(code, run_globals)
  File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/entrypoints/openai/api_server.py", line 1376, in <module>
    uvloop.run(run_server(args))
  File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/uvloop/__init__.py", line 82, in run
    return loop.run_until_complete(wrapper())
  File "uvloop/loop.pyx", line 1518, in uvloop.loop.Loop.run_until_complete
  File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/uvloop/__init__.py", line 61, in wrapper
    return await main
  File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/entrypoints/openai/api_server.py", line 1324, in run_server
    async with build_async_engine_client(args) as engine_client:
  File "/usr/lib/python3.10/contextlib.py", line 199, in __aenter__
    return await anext(self.gen)
  File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/entrypoints/openai/api_server.py", line 153, in build_async_engine_client
    async with build_async_engine_client_from_engine_args(
  File "/usr/lib/python3.10/contextlib.py", line 199, in __aenter__
    return await anext(self.gen)
  File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/entrypoints/openai/api_server.py", line 185, in build_async_engine_client_from_engine_args
    async_llm = AsyncLLM.from_vllm_config(
  File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/engine/async_llm.py", line 157, in from_vllm_config
    return cls(
  File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/engine/async_llm.py", line 123, in __init__
    self.engine_core = core_client_class(
  File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/engine/core_client.py", line 734, in __init__
    super().__init__(
  File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/engine/core_client.py", line 418, in __init__
    self._wait_for_engine_startup(output_address, parallel_config)
  File "/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/vllm/v1/engine/core_client.py", line 484, in _wait_for_engine_startup
    raise RuntimeError("Engine core initialization failed. "
RuntimeError: Engine core initialization failed. See root cause above. Failed core proc(s): {}
(.venv) xcwang@xcwang-B760M-POWER:~/dev/llm_server/vllm$ 
Step4, increase gpu_memory_utilization to 0.8 and start another vLLM instance with listening on another port. Both of 2 vLLM instances could work. 6768MiB/8188MiB has been occupied by 2 instances.
(.venv) xcwang@xcwang-B760M-POWER:~/dev/llm_server/vllm$ python -m vllm.entrypoints.openai.api_server --model Qwen/Qwen2.5-0.5B-Instruct --gpu_memory_utilization 0.8 --port 11536

INFO 06-04 12:22:58 [__init__.py:243] Automatically detected platform cuda.
INFO 06-04 12:23:00 [__init__.py:31] Available plugins for group vllm.general_plugins:
INFO 06-04 12:23:00 [__init__.py:33] - lora_filesystem_resolver -> vllm.plugins.lora_resolvers.filesystem_resolver:register_filesystem_resolver
INFO 06-04 12:23:00 [__init__.py:36] All plugins in this group will be loaded. Set `VLLM_PLUGINS` to control which plugins to load.
INFO 06-04 12:23:01 [api_server.py:1289] vLLM API server version 0.9.0.1
INFO 06-04 12:23:02 [cli_args.py:300] non-default args: {'port': 11536, 'model': 'Qwen/Qwen2.5-0.5B-Instruct', 'gpu_memory_utilization': 0.8}
INFO 06-04 12:23:08 [config.py:793] This model supports multiple tasks: {'generate', 'classify', 'score', 'reward', 'embed'}. Defaulting to 'generate'.
INFO 06-04 12:23:09 [config.py:2118] Chunked prefill is enabled with max_num_batched_tokens=2048.
INFO 06-04 12:23:13 [__init__.py:243] Automatically detected platform cuda.
INFO 06-04 12:23:16 [core.py:438] Waiting for init message from front-end.
INFO 06-04 12:23:16 [__init__.py:31] Available plugins for group vllm.general_plugins:
INFO 06-04 12:23:16 [__init__.py:33] - lora_filesystem_resolver -> vllm.plugins.lora_resolvers.filesystem_resolver:register_filesystem_resolver
INFO 06-04 12:23:16 [__init__.py:36] All plugins in this group will be loaded. Set `VLLM_PLUGINS` to control which plugins to load.
INFO 06-04 12:23:16 [core.py:65] Initializing a V1 LLM engine (v0.9.0.1) with config: model='Qwen/Qwen2.5-0.5B-Instruct', speculative_config=None, tokenizer='Qwen/Qwen2.5-0.5B-Instruct', skip_tokenizer_init=False, tokenizer_mode=auto, revision=None, override_neuron_config={}, tokenizer_revision=None, trust_remote_code=False, dtype=torch.bfloat16, max_seq_len=32768, download_dir=None, load_format=auto, tensor_parallel_size=1, pipeline_parallel_size=1, disable_custom_all_reduce=False, quantization=None, enforce_eager=False, kv_cache_dtype=auto,  device_config=cuda, decoding_config=DecodingConfig(backend='auto', disable_fallback=False, disable_any_whitespace=False, disable_additional_properties=False, reasoning_backend=''), observability_config=ObservabilityConfig(show_hidden_metrics_for_version=None, otlp_traces_endpoint=None, collect_detailed_traces=None), seed=0, served_model_name=Qwen/Qwen2.5-0.5B-Instruct, num_scheduler_steps=1, multi_step_stream_outputs=True, enable_prefix_caching=True, chunked_prefill_enabled=True, use_async_output_proc=True, pooler_config=None, compilation_config={"level": 3, "custom_ops": ["none"], "splitting_ops": ["vllm.unified_attention", "vllm.unified_attention_with_output"], "compile_sizes": [], "inductor_compile_config": {"enable_auto_functionalized_v2": false}, "use_cudagraph": true, "cudagraph_num_of_warmups": 1, "cudagraph_capture_sizes": [512, 504, 496, 488, 480, 472, 464, 456, 448, 440, 432, 424, 416, 408, 400, 392, 384, 376, 368, 360, 352, 344, 336, 328, 320, 312, 304, 296, 288, 280, 272, 264, 256, 248, 240, 232, 224, 216, 208, 200, 192, 184, 176, 168, 160, 152, 144, 136, 128, 120, 112, 104, 96, 88, 80, 72, 64, 56, 48, 40, 32, 24, 16, 8, 4, 2, 1], "max_capture_size": 512}
2025-06-04 12:23:16,304 - INFO - flashinfer.jit: Prebuilt kernels not found, using JIT backend
WARNING 06-04 12:23:16 [utils.py:2671] Methods determine_num_available_blocks,device_config,get_cache_block_size_bytes,initialize_cache not implemented in <vllm.v1.worker.gpu_worker.Worker object at 0x7ec3f9215b10>
INFO 06-04 12:23:16 [parallel_state.py:1064] rank 0 in world size 1 is assigned as DP rank 0, PP rank 0, TP rank 0, EP rank 0
INFO 06-04 12:23:16 [topk_topp_sampler.py:48] Using FlashInfer for top-p & top-k sampling.
INFO 06-04 12:23:16 [gpu_model_runner.py:1531] Starting to load model Qwen/Qwen2.5-0.5B-Instruct...
INFO 06-04 12:23:16 [cuda.py:217] Using Flash Attention backend on V1 engine.
INFO 06-04 12:23:16 [backends.py:35] Using InductorAdaptor
Loading safetensors checkpoint shards:   0% Completed | 0/1 [00:00<?, ?it/s]
Loading safetensors checkpoint shards: 100% Completed | 1/1 [00:00<00:00,  6.87it/s]
Loading safetensors checkpoint shards: 100% Completed | 1/1 [00:00<00:00,  6.86it/s]

INFO 06-04 12:23:17 [default_loader.py:280] Loading weights took 0.16 seconds
INFO 06-04 12:23:17 [gpu_model_runner.py:1549] Model loading took 0.9271 GiB and 0.326160 seconds
INFO 06-04 12:23:22 [backends.py:459] Using cache directory: /home/xcwang/.cache/vllm/torch_compile_cache/3112b147ed/rank_0_0 for vLLM's torch.compile
INFO 06-04 12:23:22 [backends.py:469] Dynamo bytecode transform time: 5.56 s
INFO 06-04 12:23:26 [backends.py:132] Directly load the compiled graph(s) for shape None from the cache, took 3.830 s
INFO 06-04 12:23:27 [monitor.py:33] torch.compile takes 5.56 s in total
2025-06-04 12:23:27,744 - INFO - flashinfer.jit: Loading JIT ops: sampling
/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/torch/utils/cpp_extension.py:2356: UserWarning: TORCH_CUDA_ARCH_LIST is not set, all archs for visible cards are included for compilation. 
If this is not desired, please set os.environ['TORCH_CUDA_ARCH_LIST'].
  warnings.warn(
/home/xcwang/dev/llm_server/vllm/.venv/lib/python3.10/site-packages/torch/utils/cpp_extension.py:2356: UserWarning: TORCH_CUDA_ARCH_LIST is not set, all archs for visible cards are included for compilation. 
If this is not desired, please set os.environ['TORCH_CUDA_ARCH_LIST'].
  warnings.warn(
2025-06-04 12:23:27,758 - INFO - flashinfer.jit: Finished loading JIT ops: sampling
INFO 06-04 12:23:27 [kv_cache_utils.py:637] GPU KV cache size: 91,472 tokens
INFO 06-04 12:23:27 [kv_cache_utils.py:640] Maximum concurrency for 32,768 tokens per request: 2.79x
INFO 06-04 12:23:41 [gpu_model_runner.py:1933] Graph capturing finished in 13 secs, took 0.38 GiB
INFO 06-04 12:23:41 [core.py:167] init engine (profile, create kv cache, warmup model) took 24.14 seconds
INFO 06-04 12:23:41 [loggers.py:134] vllm cache_config_info with initialization after num_gpu_blocks is: 5717
WARNING 06-04 12:23:41 [config.py:1339] Default sampling parameters have been overridden by the model's Hugging Face generation config recommended from the model creator. If this is not intended, please relaunch vLLM instance with `--generation-config vllm`.
INFO 06-04 12:23:41 [serving_chat.py:117] Using default chat sampling params from model: {'repetition_penalty': 1.1, 'temperature': 0.7, 'top_k': 20, 'top_p': 0.8}
INFO 06-04 12:23:41 [serving_completion.py:65] Using default completion sampling params from model: {'repetition_penalty': 1.1, 'temperature': 0.7, 'top_k': 20, 'top_p': 0.8}
INFO 06-04 12:23:41 [api_server.py:1336] Starting vLLM API server on http://0.0.0.0:11536
INFO 06-04 12:23:41 [launcher.py:28] Available routes are:
INFO 06-04 12:23:41 [launcher.py:36] Route: /openapi.json, Methods: HEAD, GET
INFO 06-04 12:23:41 [launcher.py:36] Route: /docs, Methods: HEAD, GET
INFO 06-04 12:23:41 [launcher.py:36] Route: /docs/oauth2-redirect, Methods: HEAD, GET
INFO 06-04 12:23:41 [launcher.py:36] Route: /redoc, Methods: HEAD, GET
INFO 06-04 12:23:41 [launcher.py:36] Route: /health, Methods: GET
INFO 06-04 12:23:41 [launcher.py:36] Route: /load, Methods: GET
INFO 06-04 12:23:41 [launcher.py:36] Route: /ping, Methods: POST
INFO 06-04 12:23:41 [launcher.py:36] Route: /ping, Methods: GET
INFO 06-04 12:23:41 [launcher.py:36] Route: /tokenize, Methods: POST
INFO 06-04 12:23:41 [launcher.py:36] Route: /detokenize, Methods: POST
INFO 06-04 12:23:41 [launcher.py:36] Route: /v1/models, Methods: GET
INFO 06-04 12:23:41 [launcher.py:36] Route: /version, Methods: GET
INFO 06-04 12:23:41 [launcher.py:36] Route: /v1/chat/completions, Methods: POST
INFO 06-04 12:23:41 [launcher.py:36] Route: /v1/completions, Methods: POST
INFO 06-04 12:23:41 [launcher.py:36] Route: /v1/embeddings, Methods: POST
INFO 06-04 12:23:41 [launcher.py:36] Route: /pooling, Methods: POST
INFO 06-04 12:23:41 [launcher.py:36] Route: /classify, Methods: POST
INFO 06-04 12:23:41 [launcher.py:36] Route: /score, Methods: POST
INFO 06-04 12:23:41 [launcher.py:36] Route: /v1/score, Methods: POST
INFO 06-04 12:23:41 [launcher.py:36] Route: /v1/audio/transcriptions, Methods: POST
INFO 06-04 12:23:41 [launcher.py:36] Route: /rerank, Methods: POST
INFO 06-04 12:23:41 [launcher.py:36] Route: /v1/rerank, Methods: POST
INFO 06-04 12:23:41 [launcher.py:36] Route: /v2/rerank, Methods: POST
INFO 06-04 12:23:41 [launcher.py:36] Route: /invocations, Methods: POST
INFO 06-04 12:23:41 [launcher.py:36] Route: /metrics, Methods: GET
INFO:     Started server process [3235]
INFO:     Waiting for application startup.
INFO:     Application startup complete.
xcwang@xcwang-B760M-POWER:~/dev/llm_server/vllm$ nvidia-smi 
Wed Jun  4 12:24:51 2025       
+-----------------------------------------------------------------------------------------+
| NVIDIA-SMI 550.54.15              Driver Version: 550.54.15      CUDA Version: 12.4     |
|-----------------------------------------+------------------------+----------------------+
| GPU  Name                 Persistence-M | Bus-Id          Disp.A | Volatile Uncorr. ECC |
| Fan  Temp   Perf          Pwr:Usage/Cap |           Memory-Usage | GPU-Util  Compute M. |
|                                         |                        |               MIG M. |
|=========================================+========================+======================|
|   0  NVIDIA GeForce RTX 4060 Ti     Off |   00000000:01:00.0 Off |                  N/A |
|  0%   34C    P8              8W /  160W |    6768MiB /   8188MiB |      0%      Default |
|                                         |                        |                  N/A |
+-----------------------------------------+------------------------+----------------------+
                                                                                         
+-----------------------------------------------------------------------------------------+
| Processes:                                                                              |
|  GPU   GI   CI        PID   Type   Process name                              GPU Memory |
|        ID   ID                                                               Usage      |
|=========================================================================================|
|    0   N/A  N/A      2261      C   ...ev/llm_server/vllm/.venv/bin/python       3572MiB |
|    0   N/A  N/A      3282      C   ...ev/llm_server/vllm/.venv/bin/python       3188MiB |
+-----------------------------------------------------------------------------------------+
xcwang@xcwang-B760M-POWER:~/dev/llm_server/vllm$ 

Before submitting a new issue...

  • Make sure you already searched for relevant issues, and asked the chatbot living at the bottom right corner of the documentation page, which can answer lots of frequently asked questions.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions