Vesions ignore & ld: library not found for -l...

1.递归删除指定目录下的 .git、.svn 文件
find . -name .git | xargs rm -fr
find . -name .svn | xargs rm -rf


第一条倒还不常用,因为用 git 做版本管理的时候,
只在根目录下生成一个 .git 目录,删掉这一个就行了~
因此,删除 .git 字需要 rm -rf .git 命令就够了。

第二条才是真的,svn 做版本管理的时候,受管理的每个目录下面都会有一个 .svn 隐藏目录。
因此,如果要去掉 svn 文件的话,则上面的第二条命令乃不二之选~

2.Versions for Mac 忽略文件设置
一、打开配置文件 mvim ~/.subversion/config
二、找到 global-ignores 一行,去掉注释,编辑成:
global-ignores = build *~.nib *.so *.pbxuser *.mode(在此添加呢要忽略的文件后缀)
三、找到 enable-auto-props = yes 把注释去掉
(让立即生效?这条没有试过,当时按第二条改了以后发现还是没有反应)

3.ld: library not found for -lcurl
XCode 里面有时候会报出如下的错误(今天我就遇到了一遭):
clang: warning: argument unused during compilation: '-websockets'
ld: library not found for -lcurl
clang: error: linker command failed with exit code 1 (use -v to see invocation)

解决方案:
第一时间点击 XCode 工程文件,在 Build Phases 中查看 “Link binary With Libraries” 
如果不出所料,你应该能发现有一到数个的条目是用红色字体来显示的。
什么意思?被工程引用的这些文件,其物理文件已经不处于之前所记录的地方了。
怎么办?右键点击红色条目,选择 “Reveal in Project Navigator”,
此时大抵能在左侧栏中定位到缺失文件所在的路径,接下来就好办了,找到缺失的文件,挪回它应该待的地方。

4.ld: library not found for -lcurl
现象:在编译工程时,有时会遇到类似“ld: library not found for -l…” 的错误提示。
原因:通常这是由于工程在编译时找不到需要的链接库而导致的。
解决方法:
一般可以通过如下的方法解决,在工程的 Target 中选中要执行编译的某个target,
然后 “get info”,打开 Build 设置页面,在 “Library Search Path” 中添加缺失链接库的所在文件夹的路径即可。

5.安装 Versions for Mac 以后,全局忽略的列表中默认是包含 *.a 文件类型的
这样可能会导致一些问题,就拿 cocosd-x 库来说吧,
cocos2d-x 创建的模板工程中就包含着三个 .a 类型的文件:libcurl.alibwebp.alibwebsockets.a
如果用 Versions 来做版本管理的话,这些 .a 文件就可能被跳过。
当其他人从 svn 服务器 checkout 该工程进行编译的时候,就可能会出现上一点中所描述的情形。

6.svn 默认 ignore(忽略)一些文件,例如 “*.o”,怎么取消这种默认忽略让文件能正常提交呢?
切换到指定目录,使用 “svn add * --force --no-ignore” 命令即可。
其中,“--no-ignore” 是取消忽略,“* --force” 是添加当前目录及所有子目录下的所有文件。

7.受版本控制的工程,对其做粘贴目录的操作须谨慎!
如果粘贴进去的某个目录中也包含了 .svn 隐藏目录,就可能会导致目标工程的版本控制出错,
直观的表现就是某目录下明明存在一些文件,但在 Versions 中却看不到,日常的 svn 操作也可能会受到一定的影响。

怎么解决这个问题?在控制台下切换到出问题的目录,使用 “find . -name .svn | xargs rm -rf” 命令即可。



bash: docker: command not found [root@ac6b15bb1f77 mas]# python -m vllm.entrypoints.openai.api_server \ > --model /models/z50051264/summary/Qwen2.5-7B-awq/ \ > --max-num-seqs=256 \ > --max-model-len=4096 \ > --max-num-batched-tokens=4096 \ > --tensor-parallel-size=1 \ > --block-size=128 \ > --host=0.0.0.0 \ > --port=8080 \ > --gpu-memory-utilization=0.9 \ > --trust-remote-code \ > --served-model-name=zzz \ > --quantization awq INFO 07-25 03:09:14 [__init__.py:39] Available plugins for group vllm.platform_plugins: INFO 07-25 03:09:14 [__init__.py:41] - ascend -> vllm_ascend:register INFO 07-25 03:09:14 [__init__.py:44] All plugins in this group will be loaded. Set `VLLM_PLUGINS` to control which plugins to load. INFO 07-25 03:09:14 [__init__.py:235] Platform plugin ascend is activated WARNING 07-25 03:09:15 [_custom_ops.py:20] Failed to import from vllm._C with ModuleNotFoundError("No module named 'vllm._C'") INFO 07-25 03:09:18 [importing.py:63] Triton not installed or not compatible; certain GPU-related functions will not be available. WARNING 07-25 03:09:19 [registry.py:413] Model architecture DeepSeekMTPModel is already registered, and will be overwritten by the new model class vllm_ascend.models.deepseek_mtp:CustomDeepSeekMTP. WARNING 07-25 03:09:19 [registry.py:413] Model architecture Qwen2VLForConditionalGeneration is already registered, and will be overwritten by the new model class vllm_ascend.models.qwen2_vl:AscendQwen2VLForConditionalGeneration. WARNING 07-25 03:09:19 [registry.py:413] Model architecture Qwen2_5_VLForConditionalGeneration is already registered, and will be overwritten by the new model class vllm_ascend.models.qwen2_5_vl:AscendQwen2_5_VLForConditionalGeneration. WARNING 07-25 03:09:19 [registry.py:413] Model architecture DeepseekV2ForCausalLM is already registered, and will be overwritten by the new model class vllm_ascend.models.deepseek_v2:CustomDeepseekV2ForCausalLM. WARNING 07-25 03:09:19 [registry.py:413] Model architecture DeepseekV3ForCausalLM is already registered, and will be overwritten by the new model class vllm_ascend.models.deepseek_v2:CustomDeepseekV3ForCausalLM. WARNING 07-25 03:09:19 [registry.py:413] Model architecture Qwen3MoeForCausalLM is already registered, and will be overwritten by the new model class vllm_ascend.models.qwen3_moe:CustomQwen3MoeForCausalLM. INFO 07-25 03:09:20 [api_server.py:1395] vLLM API server version 0.9.2 INFO 07-25 03:09:20 [cli_args.py:325] non-default args: {'host': '0.0.0.0', 'port': 8080, 'model': '/models/z50051264/summary/Qwen2.5-7B-awq/', 'trust_remote_code': True, 'max_model_len': 4096, 'quantization': 'awq', 'served_model_name': ['zzz'], 'block_size': 128, 'max_num_batched_tokens': 4096, 'max_num_seqs': 256} INFO 07-25 03:09:34 [config.py:841] This model supports multiple tasks: {'generate', 'classify', 'embed', 'reward'}. Defaulting to 'generate'. INFO 07-25 03:09:34 [config.py:1472] Using max model len 4096 WARNING 07-25 03:09:35 [config.py:960] ascend quantization is not fully optimized yet. The speed can be slower than non-quantized models. INFO 07-25 03:09:35 [config.py:2285] Chunked prefill is enabled with max_num_batched_tokens=4096. INFO 07-25 03:09:35 [platform.py:174] PIECEWISE compilation enabled on NPU. use_inductor not supported - using only ACL Graph mode INFO 07-25 03:09:35 [utils.py:321] Calculated maximum supported batch sizes for ACL graph: 66 INFO 07-25 03:09:35 [utils.py:336] Adjusted ACL graph batch sizes for Qwen2ForCausalLM model (layers: 28): 67 → 66 sizes INFO 07-25 03:09:45 [__init__.py:39] Available plugins for group vllm.platform_plugins: INFO 07-25 03:09:45 [__init__.py:41] - ascend -> vllm_ascend:register INFO 07-25 03:09:45 [__init__.py:44] All plugins in this group will be loaded. Set `VLLM_PLUGINS` to control which plugins to load. INFO 07-25 03:09:45 [__init__.py:235] Platform plugin ascend is activated WARNING 07-25 03:09:46 [_custom_ops.py:20] Failed to import from vllm._C with ModuleNotFoundError("No module named 'vllm._C'") INFO 07-25 03:09:50 [importing.py:63] Triton not installed or not compatible; certain GPU-related functions will not be available. INFO 07-25 03:09:50 [core.py:526] Waiting for init message from front-end. WARNING 07-25 03:09:50 [registry.py:413] Model architecture DeepSeekMTPModel is already registered, and will be overwritten by the new model class vllm_ascend.models.deepseek_mtp:CustomDeepSeekMTP. WARNING 07-25 03:09:50 [registry.py:413] Model architecture Qwen2VLForConditionalGeneration is already registered, and will be overwritten by the new model class vllm_ascend.models.qwen2_vl:AscendQwen2VLForConditionalGeneration. WARNING 07-25 03:09:50 [registry.py:413] Model architecture Qwen2_5_VLForConditionalGeneration is already registered, and will be overwritten by the new model class vllm_ascend.models.qwen2_5_vl:AscendQwen2_5_VLForConditionalGeneration. WARNING 07-25 03:09:50 [registry.py:413] Model architecture DeepseekV2ForCausalLM is already registered, and will be overwritten by the new model class vllm_ascend.models.deepseek_v2:CustomDeepseekV2ForCausalLM. WARNING 07-25 03:09:50 [registry.py:413] Model architecture DeepseekV3ForCausalLM is already registered, and will be overwritten by the new model class vllm_ascend.models.deepseek_v2:CustomDeepseekV3ForCausalLM. WARNING 07-25 03:09:50 [registry.py:413] Model architecture Qwen3MoeForCausalLM is already registered, and will be overwritten by the new model class vllm_ascend.models.qwen3_moe:CustomQwen3MoeForCausalLM. INFO 07-25 03:09:50 [core.py:69] Initializing a V1 LLM engine (v0.9.2) with config: model='/models/z50051264/summary/Qwen2.5-7B-awq/', speculative_config=None, tokenizer='/models/z50051264/summary/Qwen2.5-7B-awq/', skip_tokenizer_init=False, tokenizer_mode=auto, revision=None, override_neuron_config={}, tokenizer_revision=None, trust_remote_code=True, dtype=torch.bfloat16, max_seq_len=4096, download_dir=None, load_format=auto, tensor_parallel_size=1, pipeline_parallel_size=1, disable_custom_all_reduce=True, quantization=ascend, enforce_eager=False, kv_cache_dtype=auto, device_config=npu, 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=zzz, 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,"debug_dump_path":"","cache_dir":"","backend":"","custom_ops":["all"],"splitting_ops":["vllm.unified_attention","vllm.unified_attention_with_output","vllm.unified_ascend_attention_with_output"],"use_inductor":false,"compile_sizes":[],"inductor_compile_config":{},"inductor_passes":{},"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,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],"cudagraph_copy_inputs":false,"full_cuda_graph":false,"max_capture_size":512,"local_cache_dir":null} ERROR 07-25 03:09:53 [core.py:586] EngineCore failed to start. ERROR 07-25 03:09:53 [core.py:586] Traceback (most recent call last): ERROR 07-25 03:09:53 [core.py:586] File "/vllm-workspace/vllm/vllm/v1/engine/core.py", line 577, in run_engine_core ERROR 07-25 03:09:53 [core.py:586] engine_core = EngineCoreProc(*args, **kwargs) ERROR 07-25 03:09:53 [core.py:586] File "/vllm-workspace/vllm/vllm/v1/engine/core.py", line 404, in __init__ ERROR 07-25 03:09:53 [core.py:586] super().__init__(vllm_config, executor_class, log_stats, ERROR 07-25 03:09:53 [core.py:586] File "/vllm-workspace/vllm/vllm/v1/engine/core.py", line 75, in __init__ ERROR 07-25 03:09:53 [core.py:586] self.model_executor = executor_class(vllm_config) ERROR 07-25 03:09:53 [core.py:586] File "/vllm-workspace/vllm/vllm/executor/executor_base.py", line 53, in __init__ ERROR 07-25 03:09:53 [core.py:586] self._init_executor() ERROR 07-25 03:09:53 [core.py:586] File "/vllm-workspace/vllm/vllm/executor/uniproc_executor.py", line 47, in _init_executor ERROR 07-25 03:09:53 [core.py:586] self.collective_rpc("init_device") ERROR 07-25 03:09:53 [core.py:586] File "/vllm-workspace/vllm/vllm/executor/uniproc_executor.py", line 57, in collective_rpc ERROR 07-25 03:09:53 [core.py:586] answer = run_method(self.driver_worker, method, args, kwargs) ERROR 07-25 03:09:53 [core.py:586] File "/vllm-workspace/vllm/vllm/utils/__init__.py", line 2736, in run_method ERROR 07-25 03:09:53 [core.py:586] return func(*args, **kwargs) ERROR 07-25 03:09:53 [core.py:586] File "/vllm-workspace/vllm/vllm/worker/worker_base.py", line 606, in init_device ERROR 07-25 03:09:53 [core.py:586] self.worker.init_device() # type: ignore ERROR 07-25 03:09:53 [core.py:586] File "/vllm-workspace/vllm-ascend/vllm_ascend/worker/worker_v1.py", line 132, in init_device ERROR 07-25 03:09:53 [core.py:586] NPUPlatform.set_device(device) ERROR 07-25 03:09:53 [core.py:586] File "/vllm-workspace/vllm-ascend/vllm_ascend/platform.py", line 98, in set_device ERROR 07-25 03:09:53 [core.py:586] torch.npu.set_device(device) ERROR 07-25 03:09:53 [core.py:586] File "/usr/local/python3.10.17/lib/python3.10/site-packages/torch_npu/npu/utils.py", line 80, in set_device ERROR 07-25 03:09:53 [core.py:586] torch_npu._C._npu_setDevice(device_id) ERROR 07-25 03:09:53 [core.py:586] RuntimeError: SetPrecisionMode:build/CMakeFiles/torch_npu.dir/compiler_depend.ts:156 NPU function error: at_npu::native::AclSetCompileopt(aclCompileOpt::ACL_PRECISION_MODE, precision_mode), error code is 500001 ERROR 07-25 03:09:53 [core.py:586] [ERROR] 2025-07-25-03:09:53 (PID:977, Device:0, RankID:-1) ERR00100 PTA call acl api failed ERROR 07-25 03:09:53 [core.py:586] [Error]: The internal ACL of the system is incorrect. ERROR 07-25 03:09:53 [core.py:586] Rectify the fault based on the error information in the ascend log. ERROR 07-25 03:09:53 [core.py:586] EC0010: [PID: 977] 2025-07-25-03:09:53.177.260 Failed to import Python module [AttributeError: `np.float_` was removed in the NumPy 2.0 release. Use `np.float64` instead..]. ERROR 07-25 03:09:53 [core.py:586] Solution: Check that all required components are properly installed and the specified Python path matches the Python installation directory. (If the path does not match the directory, run set_env.sh in the installation package.) ERROR 07-25 03:09:53 [core.py:586] TraceBack (most recent call last): ERROR 07-25 03:09:53 [core.py:586] AOE Failed to call InitCannKB[FUNC:Initialize][FILE:python_adapter_manager.cc][LINE:47] ERROR 07-25 03:09:53 [core.py:586] Failed to initialize TeConfigInfo. ERROR 07-25 03:09:53 [core.py:586] [GraphOpt][InitializeInner][InitTbeFunc] Failed to init tbe.[FUNC:InitializeTeFusion][FILE:tbe_op_store_adapter.cc][LINE:1889] ERROR 07-25 03:09:53 [core.py:586] [GraphOpt][InitializeInner][InitTeFusion]: Failed to initialize TeFusion.[FUNC:InitializeInner][FILE:tbe_op_store_adapter.cc][LINE:1856] ERROR 07-25 03:09:53 [core.py:586] [SubGraphOpt][PreCompileOp][InitAdapter] InitializeAdapter adapter [tbe_op_adapter] failed! Ret [4294967295][FUNC:InitializeAdapter][FILE:op_store_adapter_manager.cc][LINE:79] ERROR 07-25 03:09:53 [core.py:586] [SubGraphOpt][PreCompileOp][Init] Initialize op store adapter failed, OpsStoreName[tbe-custom].[FUNC:Initialize][FILE:op_store_adapter_manager.cc][LINE:120] ERROR 07-25 03:09:53 [core.py:586] [FusionMngr][Init] Op store adapter manager init failed.[FUNC:Initialize][FILE:fusion_manager.cc][LINE:115] ERROR 07-25 03:09:53 [core.py:586] PluginManager InvokeAll failed.[FUNC:Initialize][FILE:ops_kernel_manager.cc][LINE:83] ERROR 07-25 03:09:53 [core.py:586] OpsManager initialize failed.[FUNC:InnerInitialize][FILE:gelib.cc][LINE:259] ERROR 07-25 03:09:53 [core.py:586] GELib::InnerInitialize failed.[FUNC:Initialize][FILE:gelib.cc][LINE:184] ERROR 07-25 03:09:53 [core.py:586] GEInitialize failed.[FUNC:GEInitialize][FILE:ge_api.cc][LINE:371] ERROR 07-25 03:09:53 [core.py:586] [Initialize][Ge]GEInitialize failed. ge result = 4294967295[FUNC:ReportCallError][FILE:log_inner.cpp][LINE:161] ERROR 07-25 03:09:53 [core.py:586] [Init][Compiler]Init compiler failed[FUNC:ReportInnerError][FILE:log_inner.cpp][LINE:145] ERROR 07-25 03:09:53 [core.py:586] [Set][Options]OpCompileProcessor init failed![FUNC:ReportInnerError][FILE:log_inner.cpp][LINE:145] ERROR 07-25 03:09:53 [core.py:586] Process EngineCore_0: Traceback (most recent call last): File "/usr/local/python3.10.17/lib/python3.10/multiprocessing/process.py", line 314, in _bootstrap self.run() File "/usr/local/python3.10.17/lib/python3.10/multiprocessing/process.py", line 108, in run self._target(*self._args, **self._kwargs) File "/vllm-workspace/vllm/vllm/v1/engine/core.py", line 590, in run_engine_core raise e File "/vllm-workspace/vllm/vllm/v1/engine/core.py", line 577, in run_engine_core engine_core = EngineCoreProc(*args, **kwargs) File "/vllm-workspace/vllm/vllm/v1/engine/core.py", line 404, in __init__ super().__init__(vllm_config, executor_class, log_stats, File "/vllm-workspace/vllm/vllm/v1/engine/core.py", line 75, in __init__ self.model_executor = executor_class(vllm_config) File "/vllm-workspace/vllm/vllm/executor/executor_base.py", line 53, in __init__ self._init_executor() File "/vllm-workspace/vllm/vllm/executor/uniproc_executor.py", line 47, in _init_executor self.collective_rpc("init_device") File "/vllm-workspace/vllm/vllm/executor/uniproc_executor.py", line 57, in collective_rpc answer = run_method(self.driver_worker, method, args, kwargs) File "/vllm-workspace/vllm/vllm/utils/__init__.py", line 2736, in run_method return func(*args, **kwargs) File "/vllm-workspace/vllm/vllm/worker/worker_base.py", line 606, in init_device self.worker.init_device() # type: ignore File "/vllm-workspace/vllm-ascend/vllm_ascend/worker/worker_v1.py", line 132, in init_device NPUPlatform.set_device(device) File "/vllm-workspace/vllm-ascend/vllm_ascend/platform.py", line 98, in set_device torch.npu.set_device(device) File "/usr/local/python3.10.17/lib/python3.10/site-packages/torch_npu/npu/utils.py", line 80, in set_device torch_npu._C._npu_setDevice(device_id) RuntimeError: SetPrecisionMode:build/CMakeFiles/torch_npu.dir/compiler_depend.ts:156 NPU function error: at_npu::native::AclSetCompileopt(aclCompileOpt::ACL_PRECISION_MODE, precision_mode), error code is 500001 [ERROR] 2025-07-25-03:09:53 (PID:977, Device:0, RankID:-1) ERR00100 PTA call acl api failed [Error]: The internal ACL of the system is incorrect. Rectify the fault based on the error information in the ascend log. EC0010: [PID: 977] 2025-07-25-03:09:53.177.260 Failed to import Python module [AttributeError: `np.float_` was removed in the NumPy 2.0 release. Use `np.float64` instead..]. Solution: Check that all required components are properly installed and the specified Python path matches the Python installation directory. (If the path does not match the directory, run set_env.sh in the installation package.) TraceBack (most recent call last): AOE Failed to call InitCannKB[FUNC:Initialize][FILE:python_adapter_manager.cc][LINE:47] Failed to initialize TeConfigInfo. [GraphOpt][InitializeInner][InitTbeFunc] Failed to init tbe.[FUNC:InitializeTeFusion][FILE:tbe_op_store_adapter.cc][LINE:1889] [GraphOpt][InitializeInner][InitTeFusion]: Failed to initialize TeFusion.[FUNC:InitializeInner][FILE:tbe_op_store_adapter.cc][LINE:1856] [SubGraphOpt][PreCompileOp][InitAdapter] InitializeAdapter adapter [tbe_op_adapter] failed! Ret [4294967295][FUNC:InitializeAdapter][FILE:op_store_adapter_manager.cc][LINE:79] [SubGraphOpt][PreCompileOp][Init] Initialize op store adapter failed, OpsStoreName[tbe-custom].[FUNC:Initialize][FILE:op_store_adapter_manager.cc][LINE:120] [FusionMngr][Init] Op store adapter manager init failed.[FUNC:Initialize][FILE:fusion_manager.cc][LINE:115] PluginManager InvokeAll failed.[FUNC:Initialize][FILE:ops_kernel_manager.cc][LINE:83] OpsManager initialize failed.[FUNC:InnerInitialize][FILE:gelib.cc][LINE:259] GELib::InnerInitialize failed.[FUNC:Initialize][FILE:gelib.cc][LINE:184] GEInitialize failed.[FUNC:GEInitialize][FILE:ge_api.cc][LINE:371] [Initialize][Ge]GEInitialize failed. ge result = 4294967295[FUNC:ReportCallError][FILE:log_inner.cpp][LINE:161] [Init][Compiler]Init compiler failed[FUNC:ReportInnerError][FILE:log_inner.cpp][LINE:145] [Set][Options]OpCompileProcessor init failed![FUNC:ReportInnerError][FILE:log_inner.cpp][LINE:145] Traceback (most recent call last): File "/usr/local/python3.10.17/lib/python3.10/runpy.py", line 196, in _run_module_as_main return _run_code(code, main_globals, None, File "/usr/local/python3.10.17/lib/python3.10/runpy.py", line 86, in _run_code exec(code, run_globals) File "/vllm-workspace/vllm/vllm/entrypoints/openai/api_server.py", line 1495, in <module> uvloop.run(run_server(args)) File "/usr/local/python3.10.17/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 "/usr/local/python3.10.17/lib/python3.10/site-packages/uvloop/__init__.py", line 61, in wrapper return await main File "/vllm-workspace/vllm/vllm/entrypoints/openai/api_server.py", line 1431, in run_server await run_server_worker(listen_address, sock, args, **uvicorn_kwargs) File "/vllm-workspace/vllm/vllm/entrypoints/openai/api_server.py", line 1451, in run_server_worker async with build_async_engine_client(args, client_config) as engine_client: File "/usr/local/python3.10.17/lib/python3.10/contextlib.py", line 199, in __aenter__ return await anext(self.gen) File "/vllm-workspace/vllm/vllm/entrypoints/openai/api_server.py", line 158, in build_async_engine_client async with build_async_engine_client_from_engine_args( File "/usr/local/python3.10.17/lib/python3.10/contextlib.py", line 199, in __aenter__ return await anext(self.gen) File "/vllm-workspace/vllm/vllm/entrypoints/openai/api_server.py", line 194, in build_async_engine_client_from_engine_args async_llm = AsyncLLM.from_vllm_config( File "/vllm-workspace/vllm/vllm/v1/engine/async_llm.py", line 162, in from_vllm_config return cls( File "/vllm-workspace/vllm/vllm/v1/engine/async_llm.py", line 124, in __init__ self.engine_core = EngineCoreClient.make_async_mp_client( File "/vllm-workspace/vllm/vllm/v1/engine/core_client.py", line 96, in make_async_mp_client return AsyncMPClient(*client_args) File "/vllm-workspace/vllm/vllm/v1/engine/core_client.py", line 666, in __init__ super().__init__( File "/vllm-workspace/vllm/vllm/v1/engine/core_client.py", line 403, in __init__ with launch_core_engines(vllm_config, executor_class, File "/usr/local/python3.10.17/lib/python3.10/contextlib.py", line 142, in __exit__ next(self.gen) File "/vllm-workspace/vllm/vllm/v1/engine/utils.py", line 434, in launch_core_engines wait_for_engine_startup( File "/vllm-workspace/vllm/vllm/v1/engine/utils.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): {} [ERROR] 2025-07-25-03:09:59 (PID:707, Device:-1, RankID:-1) ERR99999 UNKNOWN applicaiton exception 分析报错
最新发布
07-26
<think>根据用户的问题和错误信息,用户遇到了两个APT错误:1.E:Can'tselectcandidateversionfrompackagelibc-devasithasnocandidate2.E:Version'2.31-0ubuntu9.7'for'libc6'wasnotfound用户正在尝试在Ubuntu20.04上离线安装Nginx,但在处理libc6-dev依赖时遇到问题。错误表明系统无法找到指定版本的libc6(2.31-0ubuntu9.7)以及libc-dev没有候选版本。可能的原因:1.离线环境中没有包含所需版本的libc6和libc-dev包。2.用户指定的版本(2.31-0ubuntu9.7)在Ubuntu20.04的软件源中不可用(但实际上该版本是存在的,可能是由于离线环境未正确准备)。3.软件源配置不正确,导致系统无法找到正确的包。解决方案:我们将分为两个部分:在线环境准备和离线环境安装。第一步:在线环境准备(有网络连接)在能够访问互联网的Ubuntu20.04系统上准备离线安装包。1.检查可用的libc6版本:在终端中运行:`apt-cacheshowlibc6|grepVersion`查看可用的版本。通常,Ubuntu20.04的libc6版本为2.31-0ubuntu9.x(例如2.31-0ubuntu9.7)。2.如果确定需要版本为2.31-0ubuntu9.7,则下载该版本及其开发包:```bash#创建目录mkdiroffline-packagescdoffline-packages#下载libc6和libc6-devsudoapt-getdownloadlibc6=2.31-0ubuntu9.7\libc6-dev=2.31-0ubuntu9.7\libc6-dbg=2.31-0ubuntu9.7#同时下载nginx所需的依赖sudoapt-getdownloadbuild-essentiallibpcre3-devzlib1g-devlibssl-dev```3.如果上述下载过程中提示找不到版本,可以尝试不指定版本号,让apt自动选择:```bashsudoapt-getdownloadlibc6libc6-devlibc6-dbgbuild-essentiallibpcre3-devzlib1g-devlibssl-dev```4.将下载的.deb文件(在offline-packages目录中)复制到离线系统。第二步:离线环境安装在离线系统上,我们将手动安装这些包。1.切换到存放.deb文件的目录。2.安装libc6和libc6-dev:```bashsudodpkg-ilibc6*.deblibc6-dev*.deb```3.如果安装过程中遇到依赖问题,可以尝试使用`--ignore-depends`或`--force-depends`选项(谨慎使用):```bashsudodpkg-i--force-dependslibc6*.deblibc6-dev*.deb```4.安装其他依赖:```bashsudodpkg-i*.deb```5.如果安装过程中报告依赖关系问题,可以尝试修复:```bashsudoapt-getinstall-f```注意:这个命令需要网络连接。在没有网络的情况下,只能手动安装所有依赖包。考虑到用户处于离线环境,可能无法运行`apt-getinstall-f`,因此必须确保在在线环境准备阶段下载所有依赖包。补充建议:如果用户无法下载指定版本的libc6,可能是因为Ubuntu的软件源中没有该版本(虽然该版本在20.04的更新源中应该是存在的)。可以尝试以下命令更新软件源列表(在在线机器上):```bashsudoapt-getupdate```然后再次尝试下载。如果仍然无法下载指定版本,则可能需要检查软件源配置(/etc/apt/sources.list),确保包含了`focal-updates`和`focal-security`仓库,因为2.31-0ubuntu9.7是在更新仓库中。软件源配置示例(/etc/apt/sources.list):```debhttp://archive.ubuntu.com/ubuntufocalmainrestricteduniversemultiversedebhttp://archive.ubuntu.com/ubuntufocal-updatesmainrestricteduniversemultiversedebhttp://archive.ubuntu.com/ubuntufocal-securitymainrestricteduniversemultiverse```修改后运行`sudoapt-getupdate`。如果用户不需要特定版本,则可以不指定版本号,下载默认版本。如果以上方法都无法解决问题,考虑在离线机器上使用源码编译Nginx,这样就不需要系统的libc6-dev包(但需要确保系统已经安装了一个可用的libc6-dev版本)。但是根据用户之前的错误信息,他需要特定版本的libc6(2.31-0ubuntu9.7),所以重点还是下载这个版本。另外,用户还提到了“libc-dev”没有候选版本。注意:在Ubuntu中,libc-dev是一个虚拟包,由libc6-dev提供。所以解决libc6-dev的安装问题即可。总结步骤:1.在在线机器上配置正确的软件源。2.更新软件列表:`sudoapt-getupdate`3.下载所需的离线包(包括指定版本的libc6-dev和libc6,以及其他依赖)。4.将离线包移动到离线系统。5.在离线系统上使用dpkg安装这些包(注意安装顺序:先安装libc6,再安装libc6-dev,因为libc6-dev依赖libc6)。注意:直接安装libc6和libc6-dev可能会影响系统稳定性,特别是当降级这些核心库时。所以请确保版本是兼容的。由于用户之前已经尝试过其他方案,这里提供一个备选方案:使用docker容器构建Nginx。在离线环境中运行Docker可能需要额外的工作,但可以避免直接修改宿主机的libc。引用[1]中提到了docker安装问题,这里我们不展开。生成相关问题:1.如何为离线环境准备完整的软件依赖包?2.如何修复Ubuntu中的“Packagehasnoinstallationcandidate”错误?3.如何安全地降级Ubuntu系统库(如libc6)?注意:在回答中引用了用户提供的参考内容,但要注意用户的问题已经转变,主要针对libc-dev和libc6版本问题。因此,我们重点解决这两个错误。根据用户最后一次提问,他明确要求解决这两个错误。我们给出的方案应直接针对这两个错误。由于用户处于离线环境,关键是在线准备阶段要下载到正确的包。如果下载不到指定版本,则需要确认该版本确实存在于软件源中。</think> ### 解决 libc-dev 和 libc6 版本相关 APT 错误 针对您遇到的 **"E: Can't select candidate version from package libc-dev"** 和 **"E: Version '2.31-0ubuntu9.7' for 'libc6' was not found"** 错误,以下是系统性的解决方案: --- #### 问题根本原因 1. **离线环境依赖断裂**:您的离线包集合中缺少必要依赖或版本不匹配 2. **版本精确性要求**: - libc6-dev 是 libc6 的开发版本,两者必须严格匹配 - 您的系统可能要求特定的 ABI 版本(2.31),但源中无此精确版本 3. **软件源配置问题**:离线环境没有配置正确的版本源[^1] 4. **依赖链断裂**:libc6-dev 依赖 gcc、binutils 等基础工具链 --- #### 完整解决方案 ##### 阶段1:修复软件源配置(核心问题) ```bash # 在可联网设备上执行 echo "deb http://archive.ubuntu.com/ubuntu focal main restricted deb http://archive.ubuntu.com/ubuntu focal-updates main restricted deb http://security.ubuntu.com/ubuntu focal-security main restricted" | sudo tee /etc/apt/sources.list.d/focal-corrected.list sudo apt-get update # 更新源列表 ``` ##### 阶段2:精确获取所需版本(验证版号可用性) ```bash apt-cache show libc6 | grep '2.31-0ubuntu9' # 验证实际可用版本 # 若输出为空,改用最近的补丁版本 RECENT_VERSION=$(apt-cache show libc6 | grep -oP 'Version: \K2\.31-0ubuntu9\.\d+' | sort -V | tail -1) echo "将使用版本: $RECENT_VERSION" ``` ##### 阶段3:离线环境依赖安装 ```bash # 1. 安装基础运行时 sudo dpkg -i libc6_${RECENT_VERSION}_amd64.deb # 2. 安装开发文件(解决 libc-dev 问题) sudo dpkg -i libc6-dev_${RECENT_VERSION}_amd64.deb # 3. 解决依赖链断裂问题 sudo dpkg -i libgcc-s1_*.deb gcc-10-base_*.deb libc-bin_*.deb # 4. 修复安装状态 sudo apt-get install -f --allow-downgrades # 修复依存关系 ``` ##### 阶段4:验证安装结果 ```bash # 检查版本一致性 ldd --version | grep 'glibc' && dpkg -l libc6-dev | grep 'libc6-dev' # 验证开发环境 echo -e '#include <stdio.h>\nint main(){return 0;}' | gcc -x c - -o /tmp/test && /tmp/test echo $? # 应返回0 ``` --- #### 替代解决方案:源码编译(规避依赖问题) ```bash wget http://ftp.gnu.org/gnu/glibc/glibc-2.31.tar.gz tar xvf glibc-2.31.tar.gz mkdir glibc-build && cd glibc-build ../glibc-2.31/configure --prefix=/usr/local/glibc-2.31 make -j$(nproc) sudo make install # 设置环境变量 export LD_LIBRARY_PATH=/usr/local/glibc-2.31/lib:$LD_LIBRARY_PATH export PATH=/usr/local/glibc-2.31/bin:$PATH ``` --- #### 版本依赖关系矩阵 | 软件包 | 必须版本 | 替代方案 | 兼容性要求 | |---------------|---------------------|---------------------|--------------------------| | libc6 | 2.31-0ubuntu9.7 | 2.31-0ubuntu9.x | ≥2.30, ≤2.32 | | libc6-dev | 匹配libc6的精确版本 | 源码编译glibc | 必须与libc6完全匹配 | | gcc | 9.x/10.x | gcc-9 | 需兼容glibc-2.31的ABI | | libgcc-s1 | ≥10.3.0 | libgcc-s1:amd64 | 必须存在且兼容 | $$\small \text{ABI兼容性公式:} \Phi(\text{glibc}_\text{app}) \leq \Phi(\text{glibc}_\text{system})$$ --- #### 预防措施 1. **依赖快照**:使用`apt-clone`创建环境快照 ```bash sudo apt-get install apt-clone sudo apt-clone clone ubuntu-env --with-dpkg-repack ``` 2. **离线源构建**:创建本地APT仓库 ```bash sudo cp *.deb /var/debs/ sudo dpkg-scanpackages /var/debs | gzip > /var/debs/Packages.gz echo "deb [trusted=yes] file:/var/debs ./" | sudo tee /etc/apt/sources.list.d/local.list ``` ---
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值