惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Google DeepMind News
Google DeepMind News
P
Proofpoint News Feed
S
Schneier on Security
D
Darknet – Hacking Tools, Hacker News & Cyber Security
T
The Exploit Database - CXSecurity.com
B
Blog RSS Feed
G
GRAHAM CLULEY
Microsoft Azure Blog
Microsoft Azure Blog
Know Your Adversary
Know Your Adversary
N
Netflix TechBlog - Medium
A
Arctic Wolf
W
WeLiveSecurity
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
T
The Blog of Author Tim Ferriss
AWS News Blog
AWS News Blog
Engineering at Meta
Engineering at Meta
T
Threatpost
博客园 - 叶小钗
G
Google Developers Blog
U
Unit 42
Latest news
Latest news
Cyberwarzone
Cyberwarzone
N
News and Events Feed by Topic
Simon Willison's Weblog
Simon Willison's Weblog
Hacker News: Ask HN
Hacker News: Ask HN
MongoDB | Blog
MongoDB | Blog
H
Hacker News: Front Page
F
Fortinet All Blogs
T
Tailwind CSS Blog
The Register - Security
The Register - Security
Apple Machine Learning Research
Apple Machine Learning Research
C
CXSECURITY Database RSS Feed - CXSecurity.com
H
Heimdal Security Blog
A
About on SuperTechFans
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO
C
CERT Recently Published Vulnerability Notes
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
N
News and Events Feed by Topic
Application and Cybersecurity Blog
Application and Cybersecurity Blog
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
Schneier on Security
Schneier on Security
Y
Y Combinator Blog
V
Visual Studio Blog
GbyAI
GbyAI
Forbes - Security
Forbes - Security
www.infosecurity-magazine.com
www.infosecurity-magazine.com
N
News | PayPal Newsroom
P
Proofpoint News Feed
T
Threat Research - Cisco Blogs

博客园 - 骨月枫🍁

记录个人数组、字符串自己常忘记的方法,以及ES常用处理方式 解决webpack vue 项目打包生成的文件,资源文件均404问题 js 复制粘贴功能记录 记录下工作中使用的pdf.js 记录下jplayer的简单demo js 函数节流 用ajax与fetch调用阿里云免费接口 简要谈谈javascript bind 方法 h5启动原生APP总结 mac上安装mongoDb以及简单使用 mac快捷键整理以及node的基本使用 html5视频video积累 整理下PC和移动获取点击、移动坐标的代码和坑 html5 实现简单的上传 canvas基础学习(四) canvas基础学习(三) canvas基础学习(二) canvas基础学习(一) 移动端使用百度分享代码
使用vLLM部署Qwen/Qwen3.5-35B-A3B-FP8并且在DIFY中调用
骨月枫🍁 · 2026-03-06 · via 博客园 - 骨月枫🍁

硬件配置

三块4090的显卡,CUDA版本为12.8,需要注意vllm需要在CUDA12.4-9的版本下运行,下面的命令要根据当前的CUDA版本来

image

screen使用

# 1. 查看会话
screen -ls

# 2. 连接到运行 Qwen2.5 的会话
screen -r qwen2.5-session

# 3. 在会话中停止服务(按 Ctrl + C)

# 4. 退出会话(Ctrl + A, D)

# 5. 可选:终止旧会话
screen -X -S qwen2.5-session quit

# 6. 创建新会话启动 Qwen3.6
screen -S qwen3.6-session
vllm serve Qwen/Qwen3.6-7B-Instruct --port 8000
# 按 Ctrl + A, D 分离

# 7. 验证服务
curl http://localhost:8000/health

模型部署

创建环境

这里使用conda创建一个新的python 虚拟环境(重要!!!一定是新的虚拟环境,python版本选择3.12)

# 创建虚拟环境
conda create -n vllm-qwen python=3.12 -y
# 激活环境
conda activate vllm-qwen

安装基础依赖

# 安装包管理工具
pip install uv
# 安装模型下载工具
uv pip install modelscope

安装vllm

# 先安装PyTorch(使用国内镜像),需要注意的是cu128对应cuda12.8的版本,如果是12.0则是cu129!!!!!!此处造成了我爬坑了半天!!!!!!
uv pip install torch -i https://mirrors.aliyun.com/pypi/simple/ --extra-index-url https://mirrors.aliyun.com/torch-cu128/
# 再安装vllm(不指定PyTorch索引)
uv pip install -U vllm --prerelease=allow \
  -i https://mirrors.aliyun.com/pypi/simple/ \
  --extra-index-url https://wheels.vllm.ai/nightly \
  --extra-index-url https://mirrors.aliyun.com/torch-cu128/ \
  --trusted-host mirrors.aliyun.com
# 验证vllm是否安装成功
pip show vllm

启动模型

此处注意--tensor-parallel-size的值需要被模型的内部维度(8192)整除,所以我有3块卡但也设置为2

# 充分利用算力
vllm serve $HOME/.cache/modelscope/hub/models/Qwen/Qwen3.5-35B-A3B-FP8     --port 8002     --tensor-parallel-size 2     --dtype auto     --max-model-len 32768     --max-num-seqs 1     --block-size 128     --served-model-name Qwen3.5-35B     --gpu-memory-utilization 0.9
# 最求性能,把max-model-len、block-size降低了
vllm serve $HOME/.cache/modelscope/hub/models/Qwen/Qwen3.5-35B-A3B-FP8 \
    --port 8002 \
    --tensor-parallel-size 2 \
    --dtype auto \
    --max-model-len 16384 \
    --max-num-seqs 1 \
    --block-size 16 \
    --served-model-name Qwen3.5-35B \
    --gpu-memory-utilization 0.8
# 目前公司使用
vllm serve $HOME/.cache/modelscope/hub/models/Qwen/Qwen3.5-35B-A3B-FP8     --port 8002     --tensor-parallel-size 2     --dtype auto     --max-model-len 32768     --max-num-seqs 1     --block-size 16     --served-model-name Qwen3.5-35B     --gpu-memory-utilization 0.8

vllm serve $HOME/.cache/modelscope/hub/models/Qwen/Qwen3.6-27B-FP8     --port 8002     --tensor-parallel-size 2     --dtype auto     --max-model-len 49152     --max-num-seqs 1     --block-size 16     --served-model-name Qwen3.6-27B-FP8     --gpu-memory-utilization 0.8

vllm serve $HOME/.cache/modelscope/hub/models/Qwen/Qwen3.6-35B-A3B-FP8 --port 8002 --tensor-parallel-size 4 --dtype auto --max-model-len 131072 --kv-cache-dtype fp8 --max-num-seqs 1 --block-size 16 --served-model-name Qwen3.6-35B-A3B-FP8 --gpu-memory-utilization 0.85 --enable-prefix-caching --language-model-only --trust-remote-code --enable-auto-tool-choice --tool-call-parser qwen3_coder

企业微信截图_1772798280451

 显示上述内容表示启动成功

DIFY配置

image