Files
nexus/wiki/sources/removing-old-portainer-container-volume.md
2026-04-17 08:38:12 +08:00

36 lines
1.2 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
---
title: "删除旧 Portainer Container + Volume"
type: source
tags: [docker, container, portainer, volume, cleanup]
date: 2026-04-17
---
## Source File
- [[raw/Home Office/如何删除旧的废弃的docker container +volume.md]]
## Summary
- 核心主题:清理旧的 Portainer 容器、网络和数据卷,完整重装流程
- 问题域Docker 容器清理与重装
- 方法/机制:使用 docker ps/stop/rm 命令清理容器,使用 docker volume ls/rm 清理卷,使用 docker network ls/rm 清理网络
- 结论/价值:提供完整清理步骤,解决重装时 WARN 问题
## Key Claims
- 先停止容器再删除是安全清理的最佳实践
- 删除 volume 会丢失所有数据,需谨慎操作
- 使用 external: true 可保留既有 volume
## Key Quotes
> "注意:这会删除 Portainer 所有数据(用户、配置)"
> "如果 compose 文件里加 external: true可以保留既有 volume"
## Key Concepts
- [[Docker Volume]]Docker 持久化数据的管理机制
- [[Docker Network]]Docker 容器网络隔离机制
## Key Entities
- [[Portainer]]Docker 可视化管理工具
## Connections
- [[Portainer]] ← manages ← [[Docker Volume]]
- [[Portainer]] ← manages ← [[Docker Network]]