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

推荐订阅源

U
Unit 42
Microsoft Azure Blog
Microsoft Azure Blog
Engineering at Meta
Engineering at Meta
博客园 - 【当耐特】
人人都是产品经理
人人都是产品经理
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
WordPress大学
WordPress大学
有赞技术团队
有赞技术团队
Blog — PlanetScale
Blog — PlanetScale
酷 壳 – CoolShell
酷 壳 – CoolShell
aimingoo的专栏
aimingoo的专栏
Jina AI
Jina AI
小众软件
小众软件
博客园 - 叶小钗
MongoDB | Blog
MongoDB | Blog
大猫的无限游戏
大猫的无限游戏
博客园 - 聂微东
Y
Y Combinator Blog
云风的 BLOG
云风的 BLOG
I
InfoQ
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
Martin Fowler
Martin Fowler
P
Proofpoint News Feed
MyScale Blog
MyScale Blog

博客园 - yi-sheng

[2026年9月]国产曦云C500双卡vllm框架本地部署qwen3.6-35B模型 [部署失败]国产曦云C500双卡sglang框架本地部署qwen3.6-35B模型 4090多卡使用sglang:v0.5.16在docker环境部署Qwen3.5-35B-A3B-20260807 短剧及算力租用平台 AMD Rademo RX 7900 48G显存 单卡环境部署Qwen3.6-35B-A3B AMD开发者中心Notebook开SSH与WEB外网访问 ROCm 环境多模态开发开源项目汇总 国产曦云C500双卡vllm框架本地部署qwen3.6-35B模型 国产曦云C500驱动安装 国产曦云C500双卡本地部署qwen3.6-35B模型 FusionXpark_GB10救砖教程 ARM 架构NVIDIA GB10 Grace Blackwell环境中部署 Qwen3.6-35B 推理服务 Rufus的4.4制作ubuntu-24.04.4安装U盘 常用办公终端NEC 莱斯双盘位桌面存储阵列2代-LaCie 2big v2设置RAID1 常用办公终端配置信息 H3C LinSeer MegaCube灵犀MegaCube工作站使用笔记 4090多卡使用sglang推理框架docker布署qwen3.6-35B 国产曦云C500双卡本地部署qwen3.5-35B模型 国产GPU沐曦GPU系统曦云C500体验笔记 ARM 架构NVIDIA GB10 Grace Blackwell 芯片环境下安装conda FusionXpark GB10盒子开箱笔记 Python 3.11.6 + Oracle 11g​开发环境配置 MCP开发技巧:静态参数作为行为提醒(Reminder Pattern) Teachable Machine安装 Qwen2.5-1.5B + LoRA 单张显卡 微调实战 Qwen2.5-1.5B + LoRA 微调实战 大模型基建实战:使用序列猴子数据集定制 BPE Tokenizer 老年小龙虾soul.md示例 低幻觉医疗大模型Baichuan-M2-32B本地部署笔记
NVIDIA GeForce RTX 3080 魔改20G 运行大模型
yi-sheng · 2026-06-09 · via 博客园 - yi-sheng

今天使用,3080魔改卡跑大模型。

一,先将硬件组装上架。

安装操作系统  Ubuntu 22.04.4 LTS

二,查看GPU设备

root@zjyy:~# lspci | grep vga
root@zjyy:~# lspci | grep gpu
root@zjyy:~# lspci | grep -i vga
02:00.0 VGA compatible controller: NVIDIA Corporation GA102 [GeForce RTX 3080] (rev a1)
09:00.0 VGA compatible controller: Matrox Electronics Systems Ltd. G200eR2 (rev 01)

这台服务器有两张显示设备:
02:00.0— NVIDIA GA102 [GeForce RTX 3080]​ → 这就是今天主角,NVIDIA GeForce RTX 3080(桌面级显卡插在服务器上,GA102 核心)。
09:00.0— Matrox G200eR2​ → 板载BMC/带外管理显卡(用于 IPMI 远程控制台),不是真正算力卡。

三,安装驱动

Ubuntu20.04 LTS 的 yum  使用aliyum
可以手动编辑/etc/apt/sources.list中archive.ubuntu.com为mirrors.aliyun.com
输入以下命令批量替换配置:

sudo sed -e 's|archive.ubuntu.com|mirrors.aliyun.com|g' \
    -i.bak \
    /etc/apt/sources.list

sudo apt update     #更新软件包列表

安装驱动

apt-get install -y nvidia-driver-550

 安装完驱动,重起一次操作系统。

 查看驱动

image

 能看到显卡信息和,魔改后的20G显存。

查看nvidia-container

dpkg -l | grep nvidia-container
curl -fsSL https://mirrors.ustc.edu.cn/libnvidia-container/gpgkey | \
  sudo gpg --dearmor -o /usr/share/keyrings/nvidia-container-toolkit-keyring.gpg

写入 NVIDIA Container 源 

curl -fsSL https://nvidia.github.io/libnvidia-container/gpgkey | \
sudo gpg --dearmor -o /usr/share/keyrings/nvidia-container-toolkit-keyring.gpg

curl -fsSL https://nvidia.github.io/libnvidia-container/stable/deb/nvidia-container-toolkit.list | \
sed 's#deb https://#deb [signed-by=/usr/share/keyrings/nvidia-container-toolkit-keyring.gpg] https://#g' | \
sudo tee /etc/apt/sources.list.d/nvidia-container-toolkit.list

更新 APT

安装sudo apt install -y nvidia-container-toolkit  ,跑docker环境CUDA 开发/运行用,在宿主机安装。

sudo apt install -y nvidia-container-toolkit

 验证nvidia-container

dpkg -l | grep nvidia-container 

安装 nvidia-cuda-toolkit,本机环境跑CUDA 开发/运行环境用

apt install nvidia-cuda-toolkit

 查看nvcc -V

nvcc显示的是 CUDA Toolkit 11.5

根据CUDA版本安装对应的PyTorch:

pip3 install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu115

验证安装:

python3 -c "import torch; print(torch.__version__); print(torch.cuda.is_available())"

# 验证Torch GPU支持

python3 -c "import torch; print('PyTorch版本:', torch.__version__); print('CUDA可用:', torch.cuda.is_available()); print('CUDA版本:', torch.version.cuda); print('GPU设备:', torch.cuda.get_device_name(0) if torch.cuda.is_available() else 'None'); print('GPU数量:', torch.cuda.device_count());"

 输出:

PyTorch版本: 1.11.0+cu115
CUDA可用: True
CUDA版本: 11.5
GPU设备: NVIDIA GeForce RTX 3080
GPU数量: 1

四,使用vLLM推理框架,运行 Qwen3-Reranker-4B 模型。

下载模型

modelscope download \
  --model Qwen/Qwen3-Reranker-4B \
  --local_dir /data_b/modelscope/qwen3_reranker_4b_20250610

拉取镜像

docker pull dengcao/vllm-openai:v0.9.2

用 python3 -c检查vLLM否能在容器里正常导入

docker run --rm --entrypoint python3 dengcao/vllm-openai:v0.9.2 -c \
"import vllm; print('vLLM OK:', vllm.__version__)"

启动容器

docker rm -f Qwen3-Reranker-4B

docker run -d \
  --gpus all \
  --shm-size=2g \
  --ipc=host \
  -p 8701:8701 \
  -v /data_b/modelscope/qwen3_reranker_4b_20250610:/models/Qwen3-Reranker-4B \
  --name Qwen3-Reranker-4B \
  dengcao/vllm-openai:v0.9.2 \
  --model /models/Qwen3-Reranker-4B \
  --task score \
  --trust-remote-code \
  --served-model-name Qwen3-Reranker-4B \
  --max-model-len 8192 \
  --gpu-memory-utilization 0.8 \
  --port 8701

查看启动日志

docker logs -f Qwen3-Reranker-4B

 出现以下内容表示启动成功:

INFO:     Started server process [1]
INFO:     Waiting for application startup.
INFO:     Application startup complete.

测试 Rerank API

curl http://localhost:8701/v1/rerank \
  -H "Content-Type: application/json" \
  -d '{
    "model": "Qwen3-Reranker-4B",
    "query": "深度学习框架有哪些?",
    "documents": [
      "PyTorch 是一个主流的深度学习框架。",
      "苹果是一种水果。"
    ],
    "top_n": 2
  }'

常见参数说明

参数说明
--task score Reranker 专用
--max-model-len 8192 支持长 query + doc
--gpu-memory-utilization 0.8 4090 24G 推荐
--trust-remote-code Qwen3 必须
--port 8701 对外 API 端口
使用New API(Calcium-Ion/new-api)代理来转发
New API 内置了 /v1/rerank中继接口,目前兼容 Cohere Rerank 和 Jina Rerank 格式

调用时走 New API 的地址:

 

curl http://新API地址:3000/v1/rerank \