CentOS 7.x docker uses overlay2 storage method

CentOS 7.x docker uses overlay2 storage method

Edit /etc/docker/daemon.json and add the following:

{
 "storage-driver": "overlay2",
 "storage-opts": [
  "overlay2.override_kernel_check=true"
 ]
}

Installation dependencies:

yum install yum-plugin-ovl -y

Otherwise the following error will be reported:

May 05 18:20:45 node1 dockerd[49605]: Error starting daemon: error initializing graphdriver: /var/lib/docker contains several valid graphdrivers: overlay2, overlay; Please cleanup or explicitly choose storage driver (-s )

Finally restart Docker

systemctl restart docker

Additional knowledge: Compile and load toa module on centos7

1. Install the kernel-devel package, which needs to be consistent with the current kernel version

yum install kernel-devel

yum update kernel

2. After updating the kernel, you need to restart the system to make it take effect

3. Get toa source code

cd /usr/local/src/
git clone https://github.com/huaweicloud/elb-toa.git
cd elb-toa/src
make

4. If normal, toa.ko should be generated, load and test

insmod toa.ko

lsmod |grep toa

Deploy nginx for testing

Add boot auto-load

cd /lib/modules/uname -r/kernel/net/

cp /usr/local/src/elb-toa/src/toa.ko .

Add the following line to rc.local

insmod /lib/modules/3.10.0-957.21.3.el7.x86_64/kernel/net/toa.ko

Make sure /etc/rc.d/rc.local has execution permission, otherwise rc.local will not take effect.

The above article about CentOS 7.x docker using overlay2 storage method is all the content that the editor shares with you. I hope it can give you a reference. I also hope that you will support 123WORDPRESS.COM.

You may also be interested in:
  • Docker Overlay2 disk space usage is too large to clean up the method
  • Solve the problem of insufficient docker disk space
  • How to clean up the disk space occupied by Docker
  • About Docker's cleanup of Overlay2's occupied disk space (tested and effective)

<<:  Provides helpful suggestions for improving website design

>>:  Web lesson plans, lesson plans for beginners

Recommend

HTML table tag tutorial (35): cross-column attribute COLSPAN

In a complex table structure, some cells span mul...

How to set Nginx log printing post request parameters

【Foreword】 The SMS function of our project is to ...

How to modify the IP restriction conditions of MySQL account

Preface Recently, I encountered a requirement at ...

MySQL slow_log table cannot be modified to innodb engine detailed explanation

background Getting the slow query log from mysql....

Detailed tutorial on installing mysql 5.7.26 on centOS7.4

MariaDB is installed by default in CentOS, which ...

TortoiseSvn Little Turtle Installation Latest Detailed Graphics Tutorial

There were always problems when installing tortoi...

Simple implementation method of two-way data binding in js project

Table of contents Preface Publish-Subscriber Patt...

How to use Zen coding in Dreamweaver

After I published my last article “Zen Coding: A Q...

Solve the problem of IDEA configuring tomcat startup error

The following two errors were encountered when co...

Detailed steps to implement the Excel import function in Vue

1. Front-end-led implementation steps The first s...

How to use CSS to pull down a small image to view a large image and information

Today I will talk about a CSS special effect of h...

Detailed explanation of MySQL execution plan

The EXPLAIN statement provides information about ...

Vue implements adding watermark to uploaded pictures

This article shares the specific implementation c...