![]() |
![]() |
Subject: | howto extend size in /dev/mapper/docker- ? |
Author: | Fredrik |
Posted: | 2018-12-21 06:08 |
Subject: | RE: howto extend size in /dev/mapper/docker- ? |
Author: | Arthur |
Posted: | 2018-12-22 10:05 |
Subject: | RE: howto extend size in /dev/mapper/docker- ? |
Author: | Ryan Matte |
Posted: | 2018-12-26 12:25 |
/dev/mapper/docker-253:0-44154960-2ojXvaTRZkYNXo9ErVL9T9 103080888 92144932 5676692 95% /opt/serviced/var/volumes/c2zb7s2kdi6onzyaan9qg5vdr
So this means you ran out of storage space on your serviced volume.
So first off, it's possible that space is not actually being used by files and is just being taken up by old data which hasn't been cleared from the volume yet. The first thing you should try doing as root is this...
fstrim /opt/serviced/var/volumes/c2zb7s2kdi6onzyaan9qg5vdr
See if that frees up a significant amount of space on the volume. If it doesn't then move on to the following steps to extend the volume size (make sure you add more storage space to the underlying storage device beforehand)...
The following is an example of the steps required to extend a serviced volume...
First, stop serviced on all of your hosts including the master host. Then do...
vgdisplay # to locate the physical device associated with that volume group, in the case of this example /dev/sdf. Replace that with the appropriate device for your instance.
# Also, below where it says +200G, replace that with the amount of storage that you plan to add to it once the additional storage is available on the underlying device.
pvresize /dev/sdf
vgextend serviced /dev/sdf
lvextend /dev/serviced/serviced-pool -L +200G
fstrim /opt/serviced/var/volumes/c2zb7s2kdi6onzyaan9qg5vdr
Update the following in /etc/default/serviced on the master with the new total volume size before starting serviced back up.
SERVICED_DM_BASESIZE=300G
Hope this helps. Cheers.
Subject: | RE: howto extend size in /dev/mapper/docker- ? |
Author: | Ryan Matte |
Posted: | 2018-12-26 13:29 |
Some useful commands while working on this...
lsblk # to list all the block devices
lvs # to list the actual volume usage (both data and metadata)
Subject: | RE: howto extend size in /dev/mapper/docker- ? |
Author: | Fredrik |
Posted: | 2019-01-02 03:24 |
Some useful commands while working on this...
lsblk # to list all the block devices
lvs # to list the actual volume usage (both data and metadata)
/dev/mapper/docker-253:0-44154960-2ojXvaTRZkYNXo9ErVL9T9 103080888 92144932 5676692 95% /opt/serviced/var/volumes/c2zb7s2kdi6onzyaan9qg5vdr
So this means you ran out of storage space on your serviced volume.
So first off, it's possible that space is not actually being used by files and is just being taken up by old data which hasn't been cleared from the volume yet. The first thing you should try doing as root is this...
fstrim /opt/serviced/var/volumes/c2zb7s2kdi6onzyaan9qg5vdr
See if that frees up a significant amount of space on the volume. If it doesn't then move on to the following steps to extend the volume size (make sure you add more storage space to the underlying storage device beforehand)...
The following is an example of the steps required to extend a serviced volume...
First, stop serviced on all of your hosts including the master host. Then do...
vgdisplay # to locate the physical device associated with that volume group, in the case of this example /dev/sdf. Replace that with the appropriate device for your instance.
# Also, below where it says +200G, replace that with the amount of storage that you plan to add to it once the additional storage is available on the underlying device.
pvresize /dev/sdf
vgextend serviced /dev/sdf
lvextend /dev/serviced/serviced-pool -L +200G
fstrim /opt/serviced/var/volumes/c2zb7s2kdi6onzyaan9qg5vdr
Update the following in /etc/default/serviced on the master with the new total volume size before starting serviced back up.
SERVICED_DM_BASESIZE=300G
Hope this helps. Cheers.
Subject: | RE: howto extend size in /dev/mapper/docker- ? |
Author: | Ryan Matte |
Posted: | 2019-01-03 10:36 |
Sorry, use pvdisplay instead or lsblk to determine the device for the serviced pool. The pvdisplay output should look something like...
[root@zenoss5 rmatte]# pvdisplay
--- Physical volume ---
PV Name /dev/sda1
VG Name docker
PV Size 90.00 GiB / not usable 4.00 MiB
Allocatable yes
PE Size 4.00 MiB
Total PE 23039
Free PE 2304
Allocated PE 20735
PV UUID C7LCve-mYBU-VYlr-jnLv-NEw9-Jq6Y-qaLIJS
--- Physical volume ---
PV Name /dev/sda2
VG Name serviced
PV Size 100.00 GiB / not usable 3.00 MiB
Allocatable yes
PE Size 4.00 MiB
Total PE 25599
Free PE 2335
Allocated PE 23264
PV UUID 6PAzCU-gwgd-bDjD-uAja-6py1-bAAi-dWmbru
In the example output above the serviced device would be /dev/sda2. That's the device you would reference when completing the other steps. Run pvdisplay on your instance to locate the correct device then proceed with the rest of the steps. If your serviced host is a vm I'd recommend cloning it beforehand in case something goes wrong (though the steps should work fine, I've used them many times).
Subject: | RE: howto extend size in /dev/mapper/docker- ? |
Author: | Fredrik |
Posted: | 2019-01-23 03:16 |
Sorry, use pvdisplay instead or lsblk to determine the device for the serviced pool. The pvdisplay output should look something like...
[root@zenoss5 rmatte]# pvdisplay
--- Physical volume ---
PV Name /dev/sda1
VG Name docker
PV Size 90.00 GiB / not usable 4.00 MiB
Allocatable yes
PE Size 4.00 MiB
Total PE 23039
Free PE 2304
Allocated PE 20735
PV UUID C7LCve-mYBU-VYlr-jnLv-NEw9-Jq6Y-qaLIJS
--- Physical volume ---
PV Name /dev/sda2
VG Name serviced
PV Size 100.00 GiB / not usable 3.00 MiB
Allocatable yes
PE Size 4.00 MiB
Total PE 25599
Free PE 2335
Allocated PE 23264
PV UUID 6PAzCU-gwgd-bDjD-uAja-6py1-bAAi-dWmbru
In the example output above the serviced device would be /dev/sda2. That's the device you would reference when completing the other steps. Run pvdisplay on your instance to locate the correct device then proceed with the rest of the steps. If your serviced host is a vm I'd recommend cloning it beforehand in case something goes wrong (though the steps should work fine, I've used them many times).
Some useful commands while working on this...
lsblk # to list all the block devices
lvs # to list the actual volume usage (both data and metadata)
/dev/mapper/docker-253:0-44154960-2ojXvaTRZkYNXo9ErVL9T9 103080888 92144932 5676692 95% /opt/serviced/var/volumes/c2zb7s2kdi6onzyaan9qg5vdr
So this means you ran out of storage space on your serviced volume.
So first off, it's possible that space is not actually being used by files and is just being taken up by old data which hasn't been cleared from the volume yet. The first thing you should try doing as root is this...
fstrim /opt/serviced/var/volumes/c2zb7s2kdi6onzyaan9qg5vdr
See if that frees up a significant amount of space on the volume. If it doesn't then move on to the following steps to extend the volume size (make sure you add more storage space to the underlying storage device beforehand)...
The following is an example of the steps required to extend a serviced volume...
First, stop serviced on all of your hosts including the master host. Then do...
vgdisplay # to locate the physical device associated with that volume group, in the case of this example /dev/sdf. Replace that with the appropriate device for your instance.
# Also, below where it says +200G, replace that with the amount of storage that you plan to add to it once the additional storage is available on the underlying device.
pvresize /dev/sdf
vgextend serviced /dev/sdf
lvextend /dev/serviced/serviced-pool -L +200G
fstrim /opt/serviced/var/volumes/c2zb7s2kdi6onzyaan9qg5vdr
Update the following in /etc/default/serviced on the master with the new total volume size before starting serviced back up.
SERVICED_DM_BASESIZE=300G
Hope this helps. Cheers.
Subject: | RE: howto extend size in /dev/mapper/docker- ? |
Author: | Ryan Matte |
Posted: | 2019-01-23 14:38 |
Subject: | RE: howto extend size in /dev/mapper/docker- ? |
Author: | Fredrik |
Posted: | 2019-01-24 02:59 |
Subject: | RE: howto extend size in /dev/mapper/docker- ? |
Author: | Ryan Matte |
Posted: | 2019-01-28 16:12 |
Subject: | RE: howto extend size in /dev/mapper/docker- ? |
Author: | Arthur |
Posted: | 2019-01-29 16:29 |
Sorry, use pvdisplay instead or lsblk to determine the device for the serviced pool. The pvdisplay output should look something like...
[root@zenoss5 rmatte]# pvdisplay
--- Physical volume ---
PV Name /dev/sda1
VG Name docker
PV Size 90.00 GiB / not usable 4.00 MiB
Allocatable yes
PE Size 4.00 MiB
Total PE 23039
Free PE 2304
Allocated PE 20735
PV UUID C7LCve-mYBU-VYlr-jnLv-NEw9-Jq6Y-qaLIJS
--- Physical volume ---
PV Name /dev/sda2
VG Name serviced
PV Size 100.00 GiB / not usable 3.00 MiB
Allocatable yes
PE Size 4.00 MiB
Total PE 25599
Free PE 2335
Allocated PE 23264
PV UUID 6PAzCU-gwgd-bDjD-uAja-6py1-bAAi-dWmbru
In the example output above the serviced device would be /dev/sda2. That's the device you would reference when completing the other steps. Run pvdisplay on your instance to locate the correct device then proceed with the rest of the steps. If your serviced host is a vm I'd recommend cloning it beforehand in case something goes wrong (though the steps should work fine, I've used them many times).
Some useful commands while working on this...
lsblk # to list all the block devices
lvs # to list the actual volume usage (both data and metadata)
/dev/mapper/docker-253:0-44154960-2ojXvaTRZkYNXo9ErVL9T9 103080888 92144932 5676692 95% /opt/serviced/var/volumes/c2zb7s2kdi6onzyaan9qg5vdr
So this means you ran out of storage space on your serviced volume.
So first off, it's possible that space is not actually being used by files and is just being taken up by old data which hasn't been cleared from the volume yet. The first thing you should try doing as root is this...
fstrim /opt/serviced/var/volumes/c2zb7s2kdi6onzyaan9qg5vdr
See if that frees up a significant amount of space on the volume. If it doesn't then move on to the following steps to extend the volume size (make sure you add more storage space to the underlying storage device beforehand)...
The following is an example of the steps required to extend a serviced volume...
First, stop serviced on all of your hosts including the master host. Then do...
vgdisplay # to locate the physical device associated with that volume group, in the case of this example /dev/sdf. Replace that with the appropriate device for your instance.
# Also, below where it says +200G, replace that with the amount of storage that you plan to add to it once the additional storage is available on the underlying device.
pvresize /dev/sdf
vgextend serviced /dev/sdf
lvextend /dev/serviced/serviced-pool -L +200G
fstrim /opt/serviced/var/volumes/c2zb7s2kdi6onzyaan9qg5vdr
Update the following in /etc/default/serviced on the master with the new total volume size before starting serviced back up.
SERVICED_DM_BASESIZE=300G
Hope this helps. Cheers.
Subject: | RE: howto extend size in /dev/mapper/docker- ? |
Author: | Fredrik |
Posted: | 2019-01-30 12:39 |
Subject: | RE: howto extend size in /dev/mapper/docker- ? |
Author: | Arthur |
Posted: | 2019-01-30 16:29 |
Hi Fredrik
Let's start from the top. For the docker stuff you are using the overlay storage driver. It's not recommended by Zenoss but it's not the point here.
For the serviced stuff you are using the docker devicemapper storage driver in loopback-lvm mode (loop-lvm mode is not supported) – but ok.
https://docs.docker.com/storage/storagedriver/select-storage-driver/
The devicemapper storage driver uses a thin-pool which has two storage areas, Data and Metadata.
In your case it looks like you have two files mounted (loop0 100GB/Data and loop1 2GBMetadata)
loop0 7:0 0 100G 0 loop
docker-253:0-44154960-pool 253:3 0 100G 0 dm
docker-253:0-44154960-2ojXvaTRZkYNXo9ErVL9T9 253:4 0 100G 0 dm /exports/serviced_volumes_v2/c2zb7s2kdi6onzyaan9qg5vdr
loop1 7:1 0 2G 0 loop
docker-253:0-44154960-pool 253:3 0 100G 0 dm
docker-253:0-44154960-2ojXvaTRZkYNXo9ErVL9T9 253:4 0 100G 0 dm /exports/serviced_volumes_v2/c2zb7s2kdi6onzyaan9qg5vdr
If you look at your serviced volume status output, you can see that your data volume has only 4.855GiB space left. The Metadata is only 3% used which is still good enough for me.
Volume Path: /opt/serviced/var/volumes
Thin Pool
---------
Logical Volume: docker-253:0-44154960-pool
Metadata (total/used/avail): 2 GiB / 60.91 MiB (3%) / 1.941 GiB (97%)
Data (total/used/avail): 100 GiB / 95.14 GiB (95%) / 4.855 GiB (4.9%)
c2zb7s2kdi6onzyaan9qg5vdr Application Data
-----------------------------------------
Volume Mount Point: /opt/serviced/var/volumes/c2zb7s2kdi6onzyaan9qg5vdr
Filesystem (total/used/avail): 98.31 GiB / 83.64 GiB (85%) / 9.653 GiB (9.8%)
Virtual device size: 100 GiB
So, from my point of view have to extend the loop1 device. Unfortunately I haven't any experience in resizing loop devices. I found some information on the below site under "Resize a loop-lvm thin pool"
https://docs.docker.com/storage/storagedriver/device-mapper-driver/
Maybe some other readers do have and are willing to jump in!
In the meantime I will check out if I can find some more information.
Cheers Arthur
P.S I saw that you already added 200GB (sdd) to the environment.
Subject: | RE: howto extend size in /dev/mapper/docker- ? |
Author: | Arthur |
Posted: | 2019-02-07 16:38 |
Hi Fredrik
Let's start from the top. For the docker stuff you are using the overlay storage driver. It's not recommended by Zenoss but it's not the point here.
For the serviced stuff you are using the docker devicemapper storage driver in loopback-lvm mode (loop-lvm mode is not supported) – but ok.
https://docs.docker.com/storage/storagedriver/select-storage-driver/
The devicemapper storage driver uses a thin-pool which has two storage areas, Data and Metadata.
In your case it looks like you have two files mounted (loop0 100GB/Data and loop1 2GBMetadata)
loop0 7:0 0 100G 0 loop
docker-253:0-44154960-pool 253:3 0 100G 0 dm
docker-253:0-44154960-2ojXvaTRZkYNXo9ErVL9T9 253:4 0 100G 0 dm /exports/serviced_volumes_v2/c2zb7s2kdi6onzyaan9qg5vdr
loop1 7:1 0 2G 0 loop
docker-253:0-44154960-pool 253:3 0 100G 0 dm
docker-253:0-44154960-2ojXvaTRZkYNXo9ErVL9T9 253:4 0 100G 0 dm /exports/serviced_volumes_v2/c2zb7s2kdi6onzyaan9qg5vdr
If you look at your serviced volume status output, you can see that your data volume has only 4.855GiB space left. The Metadata is only 3% used which is still good enough for me.
Volume Path: /opt/serviced/var/volumes
Thin Pool
---------
Logical Volume: docker-253:0-44154960-pool
Metadata (total/used/avail): 2 GiB / 60.91 MiB (3%) / 1.941 GiB (97%)
Data (total/used/avail): 100 GiB / 95.14 GiB (95%) / 4.855 GiB (4.9%)
c2zb7s2kdi6onzyaan9qg5vdr Application Data
-----------------------------------------
Volume Mount Point: /opt/serviced/var/volumes/c2zb7s2kdi6onzyaan9qg5vdr
Filesystem (total/used/avail): 98.31 GiB / 83.64 GiB (85%) / 9.653 GiB (9.8%)
Virtual device size: 100 GiB
So, from my point of view have to extend the loop1 device. Unfortunately I haven't any experience in resizing loop devices. I found some information on the below site under "Resize a loop-lvm thin pool"
https://docs.docker.com/storage/storagedriver/device-mapper-driver/
Maybe some other readers do have and are willing to jump in!
In the meantime I will check out if I can find some more information.
Cheers Arthur
P.S I saw that you already added 200GB (sdd) to the environment.
Sorry, use pvdisplay instead or lsblk to determine the device for the serviced pool. The pvdisplay output should look something like...
[root@zenoss5 rmatte]# pvdisplay
--- Physical volume ---
PV Name /dev/sda1
VG Name docker
PV Size 90.00 GiB / not usable 4.00 MiB
Allocatable yes
PE Size 4.00 MiB
Total PE 23039
Free PE 2304
Allocated PE 20735
PV UUID C7LCve-mYBU-VYlr-jnLv-NEw9-Jq6Y-qaLIJS
--- Physical volume ---
PV Name /dev/sda2
VG Name serviced
PV Size 100.00 GiB / not usable 3.00 MiB
Allocatable yes
PE Size 4.00 MiB
Total PE 25599
Free PE 2335
Allocated PE 23264
PV UUID 6PAzCU-gwgd-bDjD-uAja-6py1-bAAi-dWmbru
In the example output above the serviced device would be /dev/sda2. That's the device you would reference when completing the other steps. Run pvdisplay on your instance to locate the correct device then proceed with the rest of the steps. If your serviced host is a vm I'd recommend cloning it beforehand in case something goes wrong (though the steps should work fine, I've used them many times).
Some useful commands while working on this...
lsblk # to list all the block devices
lvs # to list the actual volume usage (both data and metadata)
/dev/mapper/docker-253:0-44154960-2ojXvaTRZkYNXo9ErVL9T9 103080888 92144932 5676692 95% /opt/serviced/var/volumes/c2zb7s2kdi6onzyaan9qg5vdr
So this means you ran out of storage space on your serviced volume.
So first off, it's possible that space is not actually being used by files and is just being taken up by old data which hasn't been cleared from the volume yet. The first thing you should try doing as root is this...
fstrim /opt/serviced/var/volumes/c2zb7s2kdi6onzyaan9qg5vdr
See if that frees up a significant amount of space on the volume. If it doesn't then move on to the following steps to extend the volume size (make sure you add more storage space to the underlying storage device beforehand)...
The following is an example of the steps required to extend a serviced volume...
First, stop serviced on all of your hosts including the master host. Then do...
vgdisplay # to locate the physical device associated with that volume group, in the case of this example /dev/sdf. Replace that with the appropriate device for your instance.
# Also, below where it says +200G, replace that with the amount of storage that you plan to add to it once the additional storage is available on the underlying device.
pvresize /dev/sdf
vgextend serviced /dev/sdf
lvextend /dev/serviced/serviced-pool -L +200G
fstrim /opt/serviced/var/volumes/c2zb7s2kdi6onzyaan9qg5vdr
Update the following in /etc/default/serviced on the master with the new total volume size before starting serviced back up.
SERVICED_DM_BASESIZE=300G
Hope this helps. Cheers.
Subject: | RE: howto extend size in /dev/mapper/docker- ? |
Author: | Arthur |
Posted: | 2019-02-27 15:44 |
< |
Previous Over Ridden Templates |
Next Zenoss 6.2.1, Zope stops answering on its own, unprovoked |
> |