CentOS7.x系統中使用Docker時,在存儲方面須要注意的問題

 

簡述:html

一、Docker 1.12.6/v17.03文檔中CentOS7系統下安裝時,明確說明,用於生產時,必須使用devicemapper驅動的direct-lvm模式,須要咱們提早準備好塊設備,以提供更好的穩定性和性能。默認使用devicemapper驅動的loop-lvm模式,由於安裝簡單,只適用於測試環境。從docker info 信息能夠看出,loop-lvm模式最大可用空間只有107GB。生產環境下必須使用devicemapper驅動的direct-lvm模式,使用塊設備,速度更快而且能更有效地使用系統資源。linux

二、在Docker v17.06及之後的版本中,關於OverlayFS存儲驅動,儘可能使用overlay2而不要使用overlay,官方的說明是overlay能夠使用但不建議。使用overlay2時Linux系統內核要求4.0以上,或者CentOS7的內核在3.10.0-693以上。Docker-ce v17.06及以上,在使用overlay2驅動時,還須要設置額外的參數,以禁止檢測內核爲4.0版本。docker

 

官網截圖:centos

01-Docker v17.03文檔中CentOS7系統下安裝時,明確說明,用於生產時,必須使用devicemapper驅動的direct-lvm模式,須要咱們提早準備好塊設備,以提供更好的穩定性和性能app

01-Docker v17.03文檔中CentOS7系統下安裝時,明確說明,用於生產時,必須使用devicemapper驅動的direct-lvm模式,須要咱們提早準備好塊設備,以提供更好的穩定性和性能

02-Docker v17.03文檔中CentOS7系統下安裝時,默認使用devicemapper驅動的loop-lvm模式,由於安裝簡單,只適用於測試環境ide

02-Docker v17.03文檔中CentOS7系統下安裝時,默認使用devicemapper驅動的loop-lvm模式,由於安裝簡單,只適用於測試環境

03-Docker v17.03文檔中CentOS7系統下安裝時,默認使用devicemapper驅動的loop-lvm模式,docker info 信息顯示,最大可用空間只有107GBoop

03-Docker v17.03文檔中CentOS7系統下安裝時,默認使用devicemapper驅動的loop-lvm模式,最大可用空間只有107GB

 

04-生產環境下必須使用devicemapper驅動的direct-lvm模式,使用塊設備,速度更快而且能更有效地使用系統資源post

04-生產環境下必須使用devicemapper驅動的direct-lvm模式,使用塊設備,速度更快而且能更有效地使用系統資源

 

05-關於OverlayFS存儲驅動,儘可能使用overlay2而不要使用overlay,使用overlay2時Linux系統內核要求4.0以上性能

05-關於OverlayFS存儲驅動,儘可能使用overlay2而不要使用overlay,使用overlay2時Linux系統內核要求4.0以上

 

06-新版本的Docker存儲驅動說明,overlay能夠使用但不建議,最好使用overlay2,內核須要4.0以上,或者CentOS7的內核在3.10.0-693以上,須要額外的設置參數。測試

06-新版本的Docker存儲驅動說明,overlay能夠使用但不建議,最好使用overlay2,內核須要4.0以上,或者CentOS7的內核在3.10.0-693以上

 

07-CentOS7的用戶,內核在3.10.0-693以上,Docker-ce v17.06及以上,在使用overlay2驅動時,還須要設置額外的參數,禁止檢測內核爲4.0版本。

07-CentOS7的用戶,內核在3.10.0-693以上,在使用overlay2驅動時,還須要設置額外的參數,禁止檢測內核爲4.0版本

 

參考連接:

CentOS7下安裝Docker v17.03

https://docs.docker.com/v17.03/engine/installation/linux/centos/#install-from-a-package

Use the Device Mapper storage driver

https://docs.docker.com/v17.03/engine/userguide/storagedriver/device-mapper-driver/

Use the OverlayFS storage driver

https://docs.docker.com/v17.03/engine/userguide/storagedriver/overlayfs-driver/

CentOS下修改Devicemapper存儲驅動爲Direct-lvm模式

https://forums.cnrancher.com/article/19

Use the Device Mapper storage driver

https://docs.docker.com/storage/storagedriver/device-mapper-driver/

CentOS下 Docker的安裝

https://docs.docker.com/v17.03/engine/installation/linux/centos/#install-from-a-package

Configure direct-lvm mode for production

https://docs.docker.com/v17.03/engine/userguide/storagedriver/device-mapper-driver/#configure-direct-lvm-mode-for-production

Docker問答錄(100)

https://blog.lab99.org/post/docker-2016-07-14-faq.html#docker-de-var-lib-docker-devicemapper-zhan-yong-kong-jian-bu-duan-zeng-chang-zen-me-po

Redhat7.2_release_notes (OverlayFS)

https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/7.2_release_notes/technology-preview-file_systems

Redhat7.3_release_notes (OverlayFS)

https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/7.3_release_notes/technology_previews_file_systems

Redhat7.4_release_notes (OverlayFS)

https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/7.4_release_notes/technology_previews_file_systems

相關文章
相關標籤/搜索