Chinaunix首页 | 论坛 | 博客
  • 博客访问: 866894
  • 博文数量: 66
  • 博客积分: 10
  • 博客等级: 民兵
  • 技术积分: 2071
  • 用 户 组: 普通用户
  • 注册时间: 2012-12-04 15:22
个人简介

从事IT相关工作近10年,获得《网络规划师》《信息系统项目管理师》《系统分析师》、Cisco等认证,对网络和操作系统有较深理解,对认证计费系统和虚拟化技术有深入研究。

文章分类

全部博文(66)

文章存档

2019年(4)

2018年(1)

2015年(2)

2014年(16)

2013年(43)

分类: LINUX

2019-07-19 14:26:06

Definition of: volume
A volume is a specially-designated directory within one or more containers that bypasses the Union File System. Volumes are designed to persist data, independent of the container’s life cycle. Docker therefore never automatically delete volumes when you remove a container, nor will it “garbage collect” volumes that are no longer referenced by a container. Also known as: data volume

数据卷是一个或多个容器中专门指定的目录,它能够绕过联合文件系统。卷被设计用作数据持久化、并且是独立于容器的生命周期的。因此,Docker不会在删除容器时自动删除数据卷卷,也不会主动“垃圾回收”掉容器不再使用的卷。

There are three types of volumes: host, anonymous, and named:
A host volume lives on the Docker host’s filesystem and can be accessed from within the container.
A named volume is a volume which Docker manages where on disk the volume is created, but it is given a name.

An anonymous volume is similar to a named volume, however, it can be difficult, to refer to the same volume over time when it is an anonymous volumes. Docker handle where the files are stored.

有三种数据卷类型:
①宿主机数据卷:直接在宿主机的文件系统中但是容器可以访问(bind mount)
②命名的数据卷:磁盘上Docker管理的数据卷,但是这个卷有个名字。
③匿名数据卷:磁盘上Docker管理的数据卷,因为没有名字想要找到不容易,Docker来管理这些文件。

备注:数据卷其实都在(如果没有网络文件系统等情况下)宿主机文件系统里面的,只是第一种是在宿主机内的特定目录下,而后两种则在docker管理的目录下,这个目录一般是 /var/lib/docker/volumes/。

阅读(5958) | 评论(0) | 转发(0) |
1

上一篇:又一个黑客redis脚本分析

下一篇:没有了

给主人留下些什么吧!~~