Re: root on btrfs and lvmthinp for docker backing confusion

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




----- Original Message -----
> From: "Chris Murphy" <lists@xxxxxxxxxxxxxxxxx>
> To: "Fedora Cloud SIG" <cloud@xxxxxxxxxxxxxxxxxxxxxxx>
> Sent: Thursday, December 10, 2015 12:39:26 AM
> Subject: root on btrfs and lvmthinp for docker backing confusion
> 
> OK instead of hijacking some other thread...(sorta too late).
> 
> # lsblk -f
> NAME                      FSTYPE      LABEL UUID
>             MOUNTPOINT
> sda
> =E2=94=9C=E2=94=80sda1                    vfat              5956-63D8
>             /boot/efi
> =E2=94=9C=E2=94=80sda2                    btrfs       f23a
> 8b0c4840-4fc7-4782-a4c0-25fec8a40dd4   /sysroot
> =E2=94=9C=E2=94=80sda3                    ext4
> 908cb4df-410b-47e4-afb1-872255bd1244   /boot
> =E2=94=9C=E2=94=80sda4                    LVM2_member
> 9WkBEW-XwcN-8f99-nQOP-E1w8-QiBs-6Xio7a
> =E2=94=94=E2=94=80sda5                    swap
> 53f95874-06db-4433-a74b-8dc31105c528   [SWAP]
> 
> -bash-4.3# pvs
>   PV         VG   Fmt  Attr PSize   PFree
>   /dev/sda4  VG   lvm2 a--  426.51g 126.36g
> -bash-4.3# vgs
>   VG   #PV #LV #SN Attr   VSize   VFree
>   VG     1   1   0 wz--n- 426.51g 126.36g
> -bash-4.3# lvs
>   LV          VG   Attr       LSize   Pool Origin Data%  Meta%  Move
> Log Cpy%Sync Convert
>   docker-pool VG   twi-a-tz-- 300.00g             0.00   0.44
> 
> 
> What I'd like to know how to do, is get docker to use the thin pool
> setup here as backing, instead of Btrfs.
> 
> What I tried:
> 
> # cp /usr/lib/docker-storage-setup/docker-storage-setup
> /etc/sysconfig/docker-storage-setup
> 
> I then edited that file making one change such that VG=3DVG since that's
> the name of the VG. So it still says to use
> STORAGE_DRIVER=3Ddevicemapper.
> 
> 
> # systemctl status docker-storage-setup
> =E2=97=8F docker-storage-setup.service - Docker Storage Setup
>    Loaded: loaded
> (/usr/lib/systemd/system/docker-storage-setup.service; enabled; vendor
> preset: disabled)
>    Active: inactive (dead) since Thu 2015-12-10 01:09:06 MST; 45s ago
>   Process: 8008 ExecStart=3D/usr/bin/docker-storage-setup (code=3Dexited,
> status=3D0/SUCCESS)
>  Main PID: 8008 (code=3Dexited, status=3D0/SUCCESS)
> 
> Dec 10 01:09:05 f23a.localdomain systemd[1]: Starting Docker Storage Setup.=
> ..
> Dec 10 01:09:05 f23a.localdomain docker-storage-setup[8008]: INFO:
> Volume group backing root filesystem could not be determined
> Dec 10 01:09:06 f23a.localdomain docker-storage-setup[8008]: Logical
> volume "docker-pool" changed.
> Dec 10 01:09:06 f23a.localdomain systemd[1]: Started Docker Storage Setup.
> 
> 
> # systemctl status docker
> =E2=97=8F docker.service - Docker Application Container Engine
>    Loaded: loaded (/usr/lib/systemd/system/docker.service; enabled;
> vendor preset: disabled)
>   Drop-In: /usr/lib/systemd/system/docker.service.d
>            =E2=94=94=E2=94=80flannel.conf
>    Active: failed (Result: exit-code) since Thu 2015-12-10 01:09:06 MST; 48=
> s ago
>      Docs: http://docs.docker.com
>   Process: 8032 ExecStart=3D/usr/bin/docker daemon $OPTIONS
> $DOCKER_STORAGE_OPTIONS $DOCKER_NETWORK_OPTIONS $INSECURE_REGISTRY
> (code=3Dexited, status=3D1/FAILURE)
>  Main PID: 8032 (code=3Dexited, status=3D1/FAILURE)
> 
> Dec 10 01:09:06 f23a.localdomain systemd[1]: Starting Docker
> Application Container Engine...
> Dec 10 01:09:06 f23a.localdomain docker[8032]:
> time=3D"2015-12-10T01:09:06.240354137-07:00" level=3Dinfo
> msg=3D"[graphdriver] using prior storage driver \"btrfs\""
> Dec 10 01:09:06 f23a.localdomain docker[8032]:
> time=3D"2015-12-10T01:09:06.249931298-07:00" level=3Dfatal msg=3D"Error
> starting daemon: SELinux is not supporte...h driver"
> Dec 10 01:09:06 f23a.localdomain systemd[1]: docker.service: Main
> process exited, code=3Dexited, status=3D1/FAILURE
> Dec 10 01:09:06 f23a.localdomain systemd[1]: Failed to start Docker
> Application Container Engine.
> Dec 10 01:09:06 f23a.localdomain systemd[1]: docker.service: Unit
> entered failed state.
> Dec 10 01:09:06 f23a.localdomain systemd[1]: docker.service: Failed
> with result 'exit-code'.
> Hint: Some lines were ellipsized, use -l to show in full.
> 
> 
> So there's a disconnect between docker-storage-setup, which is set to
> use devicemapper and the volume group named VG, and docker.service
> which continues to use the btrfs driver (and then fails for the known
> reason that --selinux-enabled is set by default and that's not yet
> working until the automatic chcon patch lands).
> 
> In the meantime I can just remove --selinux-enabled. But I'd like to
> know how to redirect docker to use lvm thinp if that's possible.

You can ignore docker-storage-setup and edit /etc/sysconfig/docker-storage
yourself.

Here's what it looks like from the f23 vagrant box:

DOCKER_STORAGE_OPTIONS=-s devicemapper --storage-opt dm.fs=xfs --storage-opt dm.thinpooldev=/dev/mapper/atomicos-docker--pool --storage-opt dm.use_deferred_removal=true

Jason

> 
> --
> Chris Murphy
> _______________________________________________
> cloud mailing list
> cloud@xxxxxxxxxxxxxxxxxxxxxxx
> http://lists.fedoraproject.org/admin/lists/cloud@xxxxxxxxxxxxxxxxxxxxxxx
> 
_______________________________________________
cloud mailing list
cloud@xxxxxxxxxxxxxxxxxxxxxxx
http://lists.fedoraproject.org/admin/lists/cloud@xxxxxxxxxxxxxxxxxxxxxxx



[Index of Archives]     [Fedora General Discussion]     [Older Fedora Users Archive]     [Fedora Advisory Board]     [Fedora Security]     [Fedora Devel Java]     [Fedora Legacy]     [Fedora Desktop]     [ATA RAID]     [Fedora Marketing]     [Fedora Mentors]     [Fedora Package Announce]     [Fedora Package Review]     [Fedora Music]     [Fedora Packaging]     [Centos]     [Fedora SELinux]     [Coolkey]     [Yum Users]     [Big List of Linux Books]     [Yosemite News]     [Linux Apps]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Asterisk PBX]

  Powered by Linux