{"record":{"id":"59e2afef434a62eb","repo":"vllm-project/vllm","slug":"max-cpu-loras-self-max-cpu-loras-must-be-ma","errorCode":null,"errorMessage":"max_cpu_loras ({self.max_cpu_loras}) must be >= max_loras ({self.max_loras}).","messagePattern":"max_cpu_loras \\((.+?)\\) must be >= max_loras \\((.+?)\\)\\.","errorType":"validation","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"vllm/config/lora.py","lineNumber":121,"sourceCode":"        factors.append(self.fully_sharded_loras)\n        factors.append(self.lora_dtype)\n        factors.append(self.enable_tower_connector_lora)\n        factors.append(self.enable_mixed_moe_lora_format)\n        factors.append(self.enable_moe_shared_loras)\n        # target_modules affects which modules get LoRA applied\n        factors.append(\n            tuple(sorted(self.target_modules)) if self.target_modules else None\n        )\n\n        hash_str = safe_hash(str(factors).encode(), usedforsecurity=False).hexdigest()\n        return hash_str\n\n    @model_validator(mode=\"after\")\n    def _validate_lora_config(self) -> Self:\n        if self.max_cpu_loras is None:\n            self.max_cpu_loras = self.max_loras\n        elif self.max_cpu_loras < self.max_loras:\n            raise ValueError(\n                f\"max_cpu_loras ({self.max_cpu_loras}) must be >= \"\n                f\"max_loras ({self.max_loras}).\"\n            )\n        if envs.VLLM_LORA_ENABLE_DUAL_STREAM and not current_platform.is_cuda_alike():\n            raise ValueError(\"Dual CUDA streams are only supported on CUDA platforms.\")\n        if envs.VLLM_LORA_ENABLE_DUAL_STREAM and self.fully_sharded_loras:\n            logger.warning_once(\n                \"fully_sharded_loras isn't compatible with \"\n                \"VLLM_LORA_ENABLE_DUAL_STREAM, set VLLM_LORA_ENABLE_DUAL_STREAM=False\"\n            )\n            envs.VLLM_LORA_ENABLE_DUAL_STREAM = False\n        return self\n\n    def verify_with_model_config(self, model_config: ModelConfig):\n        if self.lora_dtype in (None, \"auto\"):\n            self.lora_dtype = model_config.dtype\n        elif isinstance(self.lora_dtype, str):\n            self.lora_dtype = getattr(torch, self.lora_dtype)","sourceCodeStart":103,"sourceCodeEnd":139,"githubUrl":"https://github.com/vllm-project/vllm/blob/c794754062d49a8fdb63ab3c5215b488b865030c/vllm/config/lora.py#L103-L139","documentation":"Error \"max_cpu_loras ({self.max_cpu_loras}) must be >= max_loras ({self.max_loras}).\" thrown in vllm-project/vllm.","triggerScenarios":"Raised at vllm/config/lora.py:121 when validation fails: max_cpu_loras must be >= max_loras. Typically triggered by an incompatible or incomplete vLLM configuration, an unsupported platform/backend combination, or a runtime resource/dependency that is missing.","commonSituations":"Commonly encountered at vllm/config/lora.py:121 during vLLM startup/config validation or runtime setup when: (1) conflicting CLI flags or config fields are combined, (2) the current platform (CUDA/ROCm/CPU/XPU) or installed optional packages do not support the requested feature, or (3) a required value is absent or out of range. Resolve by correcting the configuration as described in the message, or by selecting a supported alternative.","solutions":["Increase max_cpu_loras to be >= max_loras, or decrease max_loras."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"c794754062d49a8fdb63ab3c5215b488b865030c","analyzedAt":"2026-08-14T21:17:39.825Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}