Bug 1260189 - Fedora cloud does not ship with LVM enabled. This breaks docker-storage-setup
Fedora cloud does not ship with LVM enabled. This breaks docker-storage-setup
Status: ASSIGNED
Product: Fedora
Classification: Fedora
Component: fedora-productimg-cloud (Show other bugs)
25
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Matthew Miller
Fedora Extras Quality Assurance
: Reopened
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-09-04 12:44 EDT by James Findley
Modified: 2017-03-06 17:10 EST (History)
14 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-07-19 13:46:55 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description James Findley 2015-09-04 12:44:51 EDT
Description of problem:

Unlike every other fedora image, including fedora-atomic, fedora cloud does not ship with an LVM root filesystem.

This breaks docker-storage-setup.

Even if you attach a secondary disk, start the lvm2-lvmmetad service, create a PV+VG, the script still does not handle this correctly.


I've tested this with both the supplied F22 docker and the docker-1.8.1-3.git32b8b25 package that's currently in F23-testing.


[fedora@ip-172-21-22-182 ~]$ sudo vgs
  VG     #PV #LV #SN Attr   VSize   VFree
  docker   1   0   0 wz--n- 100.00g 100.00g
[fedora@ip-172-21-22-182 ~]$ sudo lsblk
NAME    MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
xvda    202:0    0   30G  0 disk
└─xvda1 202:1    0   30G  0 part /
xvdb    202:16   0  100G  0 disk
[fedora@ip-172-21-22-182 ~]$ sudo docker-storage-setup
  Volume group "xvda1" not found
  Cannot process volume group xvda1
  Path required for Logical Volume "xvda1".
  Please provide a volume group name
  Run `lvextend --help' for more information.
Metadata volume docker-poolmeta already exists. Not creating a new one.
  Please provide a volume group name
  Run `lvcreate --help' for more information.
[fedora@ip-172-21-22-182 ~]$ sudo lvs
[fedora@ip-172-21-22-182 ~]$
[fedora@ip-172-21-22-182 ~]$
Comment 4 Vivek Goyal 2015-10-28 10:58:09 EDT
fedora-atomic should be having lvm by default. If not, that's bug and should be fixed.

Other regular fedora cloud images don't have lvm by default. And by default a thin pool will not be setup as there is no free space by default on root disk.

If you add another disk and configure docker-storage-setup to use that disk,that use case should work though.

In you example above, have you told docker-storage-setup about this new volume group "docker"?

echo "VG=docker" >> /etc/sysconfig/docker-storage-setup
Comment 5 Vivek Goyal 2015-10-28 11:13:49 EDT
I just tested F23 beta atomic image and it is shipped with lvm and docker thin pool is setup properly.

-bash-4.3# cat /etc/redhat-release 
Fedora release 23 (Twenty Three)
-bash-4.3# vgs
  VG       #PV #LV #SN Attr   VSize VFree
  atomicos   1   2   0 wz--n- 5.70g 1.10g
-bash-4.3# lvs
  LV          VG       Attr       LSize Pool Origin Data%  Meta%  Move Log Cpy%Sync Convert
  docker-pool atomicos twi-a-t--- 1.66g             1.15   0.49                            
  root        atomicos -wi-ao---- 2.93g                              


So the issue is only present with fedora cloud images (non-atomic) where lvm is not there and there is no free space on root disk to setup thin pool by default.

Adding another disk and specifying that to docker-storage-setup should work.

I am also looking into following.

- Grow root disk before boot.
- Limit the size of rootfs using some cloud-config option (hopefully there is one).

- Create a partition and volume group from remaining space on root disk and point docker-storage-setup at it.
Comment 6 Daniel Walsh 2015-12-01 17:04:10 EST
Any update on this?
Comment 8 Fedora End Of Life 2016-07-19 13:46:55 EDT
Fedora 22 changed to end-of-life (EOL) status on 2016-07-19. Fedora 22 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.
Comment 9 Daniel Walsh 2016-07-20 06:44:45 EDT
Once we get overlayfs into the upstream .next we should pull the kernel patches into Fedora Rawhide and start shipping the cloud image to default to Overlayfs at least in Rawhide.
Comment 10 Jan Kurik 2016-07-26 00:40:00 EDT
This bug appears to have been reported against 'rawhide' during the Fedora 25 development cycle.
Changing version to '25'.

Note You need to log in before you can comment on or make changes to this bug.