docker扩容

一、docker扩容

在docker运行状态,在docker的宿主机操作:

1、cd /dev/mapper/

2、dmsetup table

3、echo 0 88080384 thin 253:7 11 | dmsetup load docker-253:0-143881939-c5d625c1787fd9e9a9793ccb6bee666c460833ed961b773ed2c6a0c3202dfe90

注:这里的88080384,代表42GB。意思为:echo $((42*1024*1024*1024/512))

4、dmsetup resume docker-253:0-143881939-c5d625c1787fd9e9a9793ccb6bee666c460833ed961b773ed2c6a0c3202dfe90

5、xfs_growfs /dev/mapper/docker-253:0-143881939-c5d625c1787fd9e9a9793ccb6bee666c460833ed961b773ed2c6a0c3202dfe90

 

二、重启docker

1、docker stop docker-project

2、docker start docker-project(如果启动时报错,则继续执行下列语句)

3、echo 0 88080384 thin 253:7 11 | dmsetup load docker-253:0-143881939-c5d625c1787fd9e9a9793ccb6bee666c460833ed961b773ed2c6a0c3202dfe90

4、dmsetup resume docker-253:0-143881939-c5d625c1787fd9e9a9793ccb6bee666c460833ed961b773ed2c6a0c3202dfe90

 

 

你可能感兴趣的:(docker扩容)