Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: When using tp for inference, an error occurs: Worker VllmWorkerProcess pid 3283517 died, exit code: -15. #6145

Closed
B-201 opened this issue Jul 4, 2024 · 15 comments
Labels
bug Something isn't working

Comments

@B-201
Copy link
Contributor

B-201 commented Jul 4, 2024

Your current environment

PyTorch version: 2.3.0+cu121
Is debug build: False
CUDA used to build PyTorch: 12.1
ROCM used to build PyTorch: N/A

OS: Ubuntu 20.04.6 LTS (x86_64)
GCC version: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0
Clang version: Could not collect
CMake version: version 3.26.0
Libc version: glibc-2.31

Python version: 3.10.0 (default, Mar  3 2022, 09:58:08) [GCC 7.5.0] (64-bit runtime)
Python platform: Linux-5.15.0-107-generic-x86_64-with-glibc2.31
Is CUDA available: True
CUDA runtime version: 12.1.105
CUDA_MODULE_LOADING set to: LAZY
GPU models and configuration: 
GPU 0: NVIDIA A800 80GB PCIe
GPU 1: NVIDIA A800 80GB PCIe
GPU 2: NVIDIA A800 80GB PCIe
GPU 3: NVIDIA A800 80GB PCIe
GPU 4: NVIDIA A800 80GB PCIe
GPU 5: NVIDIA A800 80GB PCIe
GPU 6: NVIDIA A800 80GB PCIe
GPU 7: NVIDIA A800 80GB PCIe

Nvidia driver version: 550.54.15
cuDNN version: Could not collect
HIP runtime version: N/A
MIOpen runtime version: N/A
Is XNNPACK available: True

CPU:
Architecture:                       x86_64
CPU op-mode(s):                     32-bit, 64-bit
Byte Order:                         Little Endian
Address sizes:                      46 bits physical, 57 bits virtual
CPU(s):                             112
On-line CPU(s) list:                0-111
Thread(s) per core:                 2
Core(s) per socket:                 28
Socket(s):                          2
NUMA node(s):                       2
Vendor ID:                          GenuineIntel
CPU family:                         6
Model:                              106
Model name:                         Intel(R) Xeon(R) Gold 6330 CPU @ 2.00GHz
Stepping:                           6
CPU MHz:                            2600.000
CPU max MHz:                        3100.0000
CPU min MHz:                        800.0000
BogoMIPS:                           4000.00
Virtualization:                     VT-x
L1d cache:                          2.6 MiB
L1i cache:                          1.8 MiB
L2 cache:                           70 MiB
L3 cache:                           84 MiB
NUMA node0 CPU(s):                  0-27,56-83
NUMA node1 CPU(s):                  28-55,84-111
Vulnerability Gather data sampling: Mitigation; Microcode
Vulnerability Itlb multihit:        Not affected
Vulnerability L1tf:                 Not affected
Vulnerability Mds:                  Not affected
Vulnerability Meltdown:             Not affected
Vulnerability Mmio stale data:      Mitigation; Clear CPU buffers; SMT vulnerable
Vulnerability Retbleed:             Not affected
Vulnerability Spec rstack overflow: Not affected
Vulnerability Spec store bypass:    Mitigation; Speculative Store Bypass disabled via prctl and seccomp
Vulnerability Spectre v1:           Mitigation; usercopy/swapgs barriers and __user pointer sanitization
Vulnerability Spectre v2:           Mitigation; Enhanced IBRS; IBPB conditional; RSB filling; PBRSB-eIBRS SW sequence; BHI Syscall hardening, KVM SW loop
Vulnerability Srbds:                Not affected
Vulnerability Tsx async abort:      Not affected
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 pni pclmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 sdbg fma cx16 xtpr pdcm pcid dca sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm 3dnowprefetch cpuid_fault epb cat_l3 invpcid_single intel_ppin ssbd mba ibrs ibpb stibp ibrs_enhanced tpr_shadow vnmi flexpriority ept vpid ept_ad fsgsbase tsc_adjust bmi1 avx2 smep bmi2 erms invpcid cqm rdt_a avx512f avx512dq rdseed adx smap avx512ifma clflushopt clwb intel_pt avx512cd sha_ni avx512bw avx512vl xsaveopt xsavec xgetbv1 xsaves cqm_llc cqm_occup_llc cqm_mbm_total cqm_mbm_local split_lock_detect wbnoinvd dtherm ida arat pln pts hwp hwp_act_window hwp_epp hwp_pkg_req avx512vbmi umip pku ospke avx512_vbmi2 gfni vaes vpclmulqdq avx512_vnni avx512_bitalg tme avx512_vpopcntdq la57 rdpid fsrm md_clear pconfig flush_l1d arch_capabilities

Versions of relevant libraries:
[pip3] numpy==1.26.4
[pip3] nvidia-nccl-cu12==2.20.5
[pip3] torch==2.3.0
[pip3] torchvision==0.18.0
[pip3] transformers==4.42.3
[pip3] triton==2.3.0
[pip3] vllm_nccl_cu12==2.18.1.0.4.0
[conda] numpy                     1.26.4                   pypi_0    pypi
[conda] nvidia-nccl-cu12          2.20.5                   pypi_0    pypi
[conda] torch                     2.3.0                    pypi_0    pypi
[conda] torchvision               0.18.0                   pypi_0    pypi
[conda] transformers              4.42.3                   pypi_0    pypi
[conda] triton                    2.3.0                    pypi_0    pypi
[conda] vllm-nccl-cu12            2.18.1.0.4.0             pypi_0    pypi
ROCM Version: Could not collect
Neuron SDK Version: N/A
vLLM Version: 0.5.0.post1
vLLM Build Flags:
CUDA Archs: Not Set; ROCm: Disabled; Neuron: Disabled
GPU Topology:
GPU0	GPU1	GPU2	GPU3	GPU4	GPU5	GPU6	GPU7	CPU Affinity	NUMA Affinity	GPU NUMA ID
GPU0	 X 	NV8	PXB	PXB	PXB	PXB	PXB	PXB	0-27,56-83	0		N/A
GPU1	NV8	 X 	PXB	PXB	PXB	PXB	PXB	PXB	0-27,56-83	0		N/A
GPU2	PXB	PXB	 X 	PXB	PXB	PXB	PXB	NV8	0-27,56-83	0		N/A
GPU3	PXB	PXB	PXB	 X 	NV8	PXB	PXB	PXB	0-27,56-83	0		N/A
GPU4	PXB	PXB	PXB	NV8	 X 	PXB	PXB	PXB	0-27,56-83	0		N/A
GPU5	PXB	PXB	PXB	PXB	PXB	 X 	NV8	PXB	0-27,56-83	0		N/A
GPU6	PXB	PXB	PXB	PXB	PXB	NV8	 X 	PXB	0-27,56-83	0		N/A
GPU7	PXB	PXB	NV8	PXB	PXB	PXB	PXB	 X 	0-27,56-83	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

🐛 Describe the bug

When using tensor_parallel for inference, there is a certain probability of encountering the error ERROR 07-04 23:23:23 multiproc_worker_utils.py:120] Worker VllmWorkerProcess pid 3283517 died, exit code: -15.

The reproducible code is as follows:

import vllm


MODEL_PATH = "meta-llama/Llama-2-7b-chat-hf"


llm = vllm.LLM(
    MODEL_PATH,
    trust_remote_code=True,
    gpu_memory_utilization=0.3,
    tensor_parallel_size=4,
    fully_sharded_loras=True,
)

prompts = [
    "[user] Give me a short introduction to large language model. [/user] [assistant]",  # noqa: E501
]
sampling_params = vllm.SamplingParams(
    temperature=0, max_tokens=256, stop=["[/assistant]"]
)
outputs = llm.generate(
    prompts,
    sampling_params,
)
# Print the outputs.
generated_texts = []
for output in outputs:
    prompt = output.prompt
    generated_text = output.outputs[0].text
    generated_texts.append(generated_text)
    print(f"Prompt: {prompt!r}, Generated text: {generated_text!r}")

The complete running results are as follows:

INFO 07-04 23:19:58 config.py:703] Defaulting to use mp for distributed inference
INFO 07-04 23:19:58 llm_engine.py:169] Initializing an LLM engine (v0.5.0.post1) with config: model='meta-llama/Llama-2-7b-chat-hf', speculative_config=None, tokenizer='meta-llama/Llama-2-7b-chat-hf', skip_tokenizer_init=False, tokenizer_mode=auto, revision=None, rope_scaling=None, rope_theta=None, tokenizer_revision=None, trust_remote_code=True, dtype=torch.float16, max_seq_len=2048, download_dir=None, load_format=LoadFormat.AUTO, tensor_parallel_size=4, pipeline_parallel_size=1, disable_custom_all_reduce=False, quantization=None, enforce_eager=False, kv_cache_dtype=auto, quantization_param_path=None, device_config=cuda, decoding_config=DecodingConfig(guided_decoding_backend='outlines'), observability_config=ObservabilityConfig(otlp_traces_endpoint=None), seed=0, served_model_name=/home/sobey/SSD/Llama-2-7B-fp16-hf, use_v2_block_manager=False, enable_prefix_caching=False)
You are using the default legacy behaviour of the <class 'transformers.models.llama.tokenization_llama_fast.LlamaTokenizerFast'>. This is expected, and simply means that the `legacy` (previous) behavior will be used so nothing changes for you. If you want to use the new behaviour, set `legacy=False`. This should only be set if you understand what it means, and thoroughly read the reason why this was added as explained in https://github.com/huggingface/transformers/pull/24565 - if you loaded a llama tokenizer from a GGUF file you can ignore this message.
(VllmWorkerProcess pid=3283517) INFO 07-04 23:20:16 multiproc_worker_utils.py:215] Worker ready; awaiting tasks
(VllmWorkerProcess pid=3283516) INFO 07-04 23:20:19 multiproc_worker_utils.py:215] Worker ready; awaiting tasks
(VllmWorkerProcess pid=3283518) INFO 07-04 23:20:19 multiproc_worker_utils.py:215] Worker ready; awaiting tasks
INFO 07-04 23:20:24 utils.py:720] Found nccl from library libnccl.so.2
(VllmWorkerProcess pid=3283517) INFO 07-04 23:20:24 utils.py:720] Found nccl from library libnccl.so.2
(VllmWorkerProcess pid=3283518) INFO 07-04 23:20:24 utils.py:720] Found nccl from library libnccl.so.2
(VllmWorkerProcess pid=3283516) INFO 07-04 23:20:24 utils.py:720] Found nccl from library libnccl.so.2
INFO 07-04 23:20:24 pynccl.py:63] vLLM is using nccl==2.20.5
(VllmWorkerProcess pid=3283517) INFO 07-04 23:20:24 pynccl.py:63] vLLM is using nccl==2.20.5
(VllmWorkerProcess pid=3283518) INFO 07-04 23:20:24 pynccl.py:63] vLLM is using nccl==2.20.5
(VllmWorkerProcess pid=3283516) INFO 07-04 23:20:24 pynccl.py:63] vLLM is using nccl==2.20.5
(VllmWorkerProcess pid=3283518) WARNING 07-04 23:20:42 custom_all_reduce.py:118] Custom allreduce is disabled because it's not supported on more than two PCIe-only GPUs. To silence this warning, specify disable_custom_all_reduce=True explicitly.
(VllmWorkerProcess pid=3283516) WARNING 07-04 23:20:42 custom_all_reduce.py:118] Custom allreduce is disabled because it's not supported on more than two PCIe-only GPUs. To silence this warning, specify disable_custom_all_reduce=True explicitly.
(VllmWorkerProcess pid=3283517) WARNING 07-04 23:20:42 custom_all_reduce.py:118] Custom allreduce is disabled because it's not supported on more than two PCIe-only GPUs. To silence this warning, specify disable_custom_all_reduce=True explicitly.
WARNING 07-04 23:20:42 custom_all_reduce.py:118] Custom allreduce is disabled because it's not supported on more than two PCIe-only GPUs. To silence this warning, specify disable_custom_all_reduce=True explicitly.
(VllmWorkerProcess pid=3283517) INFO 07-04 23:20:58 model_runner.py:254] Loading model weights took 3.1856 GB
(VllmWorkerProcess pid=3283516) INFO 07-04 23:20:58 model_runner.py:254] Loading model weights took 3.1856 GB
(VllmWorkerProcess pid=3283518) INFO 07-04 23:20:58 model_runner.py:254] Loading model weights took 3.1856 GB
INFO 07-04 23:20:59 model_runner.py:254] Loading model weights took 3.1856 GB
INFO 07-04 23:21:17 distributed_gpu_executor.py:56] # GPU blocks: 9994, # CPU blocks: 2048
(VllmWorkerProcess pid=3283517) INFO 07-04 23:21:45 model_runner.py:901] Capturing the model for CUDA graphs. This may lead to unexpected consequences if the model is not static. To run the model in eager mode, set 'enforce_eager=True' or use '--enforce-eager' in the CLI.
(VllmWorkerProcess pid=3283517) INFO 07-04 23:21:45 model_runner.py:905] CUDA graphs can take additional 1~3 GiB memory per GPU. If you are running out of memory, consider decreasing `gpu_memory_utilization` or enforcing eager mode. You can also reduce the `max_num_seqs` as needed to decrease memory usage.
(VllmWorkerProcess pid=3283516) INFO 07-04 23:21:46 model_runner.py:901] Capturing the model for CUDA graphs. This may lead to unexpected consequences if the model is not static. To run the model in eager mode, set 'enforce_eager=True' or use '--enforce-eager' in the CLI.
(VllmWorkerProcess pid=3283516) INFO 07-04 23:21:46 model_runner.py:905] CUDA graphs can take additional 1~3 GiB memory per GPU. If you are running out of memory, consider decreasing `gpu_memory_utilization` or enforcing eager mode. You can also reduce the `max_num_seqs` as needed to decrease memory usage.
INFO 07-04 23:21:46 model_runner.py:901] Capturing the model for CUDA graphs. This may lead to unexpected consequences if the model is not static. To run the model in eager mode, set 'enforce_eager=True' or use '--enforce-eager' in the CLI.
INFO 07-04 23:21:46 model_runner.py:905] CUDA graphs can take additional 1~3 GiB memory per GPU. If you are running out of memory, consider decreasing `gpu_memory_utilization` or enforcing eager mode. You can also reduce the `max_num_seqs` as needed to decrease memory usage.
(VllmWorkerProcess pid=3283518) INFO 07-04 23:21:47 model_runner.py:901] Capturing the model for CUDA graphs. This may lead to unexpected consequences if the model is not static. To run the model in eager mode, set 'enforce_eager=True' or use '--enforce-eager' in the CLI.
(VllmWorkerProcess pid=3283518) INFO 07-04 23:21:47 model_runner.py:905] CUDA graphs can take additional 1~3 GiB memory per GPU. If you are running out of memory, consider decreasing `gpu_memory_utilization` or enforcing eager mode. You can also reduce the `max_num_seqs` as needed to decrease memory usage.
(VllmWorkerProcess pid=3283518) INFO 07-04 23:23:19 model_runner.py:1094] Graph capturing finished in 91 secs.
(VllmWorkerProcess pid=3283516) INFO 07-04 23:23:19 model_runner.py:1094] Graph capturing finished in 93 secs.
(VllmWorkerProcess pid=3283517) INFO 07-04 23:23:19 model_runner.py:1094] Graph capturing finished in 94 secs.
INFO 07-04 23:23:19 model_runner.py:1094] Graph capturing finished in 92 secs.
Processed prompts: 100%|████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:00<00:00,  2.25it/s, est. speed input: 49.43 toks/s, output: 130.31 toks/s]
Prompt: '[user] Give me a short introduction to large language model. [/user] [assistant]', Generated text: ' A large language model (LLM) is a type of artificial intelligence model that is trained on a large amount of text data to generate human-like text. LLMs are typically used for tasks such as natural language processing, machine translation, and text generation. '
ERROR 07-04 23:23:23 multiproc_worker_utils.py:120] Worker VllmWorkerProcess pid 3283517 died, exit code: -15
INFO 07-04 23:23:23 multiproc_worker_utils.py:123] Killing local vLLM worker processes
@B-201 B-201 added the bug Something isn't working label Jul 4, 2024
@youkaichao
Copy link
Member

@njhill should be working on this. this is a benign error report, your program should run as normal, but the shutdown is not clean.

@B-201 B-201 closed this as completed Jul 8, 2024
@pizts
Copy link

pizts commented Jul 8, 2024

same error, how to fix it?

@haltingstate
Copy link

I have a similar error. What is the solution?

model: AI-ModelScope/Mixtral-8x22B-Instruct-v0.1
tensor-parallel-size 3

[rank0]: AssertionError: 32768 is not divisible by 3

ERROR 07-13 02:56:30 multiproc_worker_utils.py:120] Worker VllmWorkerProcess pid 382811 died, exit code: -15
INFO 07-13 02:56:30 multiproc_worker_utils.py:123] Killing local vLLM worker processes

@Respaired
Copy link

me too, same issue

@HuanzhiMao
Copy link

same issue here

@Joe-Hall-Lee
Copy link

Same issue.

ShishirPatil pushed a commit to ShishirPatil/gorilla that referenced this issue Jul 24, 2024
…taset; Handle vLLM Benign Error (#540)

In this PR:

1. **Support Multi-Model Multi-Category Generation**:
- The `openfunctions_evaluation.py` can now take a list of model names
and a list of test categories as command line input.
   - Partially address #501.

2. **Handling vLLM's Error**:
- A benign error would occur during the cleanup phase after completing a
generation task, causing the pipeline to fail despite generating model
results. This issue stems from vLLM and is outside our control. [See
this issue](vllm-project/vllm#6145) from the
vLLM repo.
- This is annoying because when users attempt category-specific
generation for locally-hosted models (as supported in #512), only the
first category result for the first model is generated since the error
occurs immediately after.
- To improve the user experience, we now combine all selected test
categories into one task and submit that single task to vLLM, splitting
the results afterwards.
- Note: If multiple locally-hosted models are queued for inference, only
the tasks of the first model will complete. Subsequent tasks will still
fail due to the cleanup phase error from the first model. Therefore, we
recommend running the inference command for one model at a time until
vLLM rolls out the fix.

3. **Adding Index to Dataset**:
- Each test file and possible_answer file now includes an index to help
match entries.
  
This PR **will not** affect the leaderboard score.
@Charmnut
Copy link

Charmnut commented Aug 9, 2024

same issue here

@ujjawal-ti
Copy link

same issue here.

aw632 pushed a commit to vinaybagade/gorilla that referenced this issue Aug 22, 2024
…taset; Handle vLLM Benign Error (ShishirPatil#540)

In this PR:

1. **Support Multi-Model Multi-Category Generation**:
- The `openfunctions_evaluation.py` can now take a list of model names
and a list of test categories as command line input.
   - Partially address ShishirPatil#501.

2. **Handling vLLM's Error**:
- A benign error would occur during the cleanup phase after completing a
generation task, causing the pipeline to fail despite generating model
results. This issue stems from vLLM and is outside our control. [See
this issue](vllm-project/vllm#6145) from the
vLLM repo.
- This is annoying because when users attempt category-specific
generation for locally-hosted models (as supported in ShishirPatil#512), only the
first category result for the first model is generated since the error
occurs immediately after.
- To improve the user experience, we now combine all selected test
categories into one task and submit that single task to vLLM, splitting
the results afterwards.
- Note: If multiple locally-hosted models are queued for inference, only
the tasks of the first model will complete. Subsequent tasks will still
fail due to the cleanup phase error from the first model. Therefore, we
recommend running the inference command for one model at a time until
vLLM rolls out the fix.

3. **Adding Index to Dataset**:
- Each test file and possible_answer file now includes an index to help
match entries.
  
This PR **will not** affect the leaderboard score.
@iseesaw
Copy link

iseesaw commented Aug 24, 2024

🙋🏻‍♀️

@qiuhaolu
Copy link

same error 0.5.5

@priyanshu891
Copy link

priyanshu891 commented Sep 5, 2024

same issue 0.6.0

@mazhaojia123
Copy link

I have the similar issue when using nsys-gui to launch the server.

@tengdecheng
Copy link

same issue, vllm version is 0.6.0, when use: nsys profile --stats=true python examples/offline_inference.py

@27balabala
Copy link

I have a similar error. What is the solution?

model: AI-ModelScope/Mixtral-8x22B-Instruct-v0.1 tensor-parallel-size 3

[rank0]: AssertionError: 32768 is not divisible by 3

ERROR 07-13 02:56:30 multiproc_worker_utils.py:120] Worker VllmWorkerProcess pid 382811 died, exit code: -15 INFO 07-13 02:56:30 multiproc_worker_utils.py:123] Killing local vLLM worker processes

@27balabala
Copy link

do you find any way to solve? Would you like to share it? Please

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests