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

Re: [atomic-devel] Running docker-storage-setup from a UI



On 04/13/2016 09:36 AM, Marius Vollmer wrote:
Vivek Goyal <vgoyal redhat com> writes:

On Tue, Apr 12, 2016 at 03:09:08PM +0300, Marius Vollmer wrote:

- Docker-storage-setup needs to run non-interactively, but I think it
   can't do that right now, and asks confirmation for various things.
It already runs non-interactively. It is a service which runs on boot.
Yes, I noticed that, too.  So any user-prompting from
docker-storage-setup is a bug?  I get a prompt from pvcreate sometimes,
for example when the random data on the new partition has a filesystem
signature at the beginning.  With what I know now, this is probably
unintended.  Should I file an issue?  Lvm likes to add confirmation
prompts like this over time... :)
I had same dilemma in past when I wanted to make d-s-s to wipe out all on device specified in DEVS section in /etc/sysconfig/docker-storage, however I think option to stop d-s-s if it detects fs signature is security warning for case when someone by mistake specify wrong device in /etc/sysconfig/docker-storage-setup. If --force-wipe ( or wipefs -a ) is used in d-s-s then it would delete all on device no matter is it correct device or not. Now d-s-s will stop ( iirc silently fail and start loop lvm in case it finds fs on device ) From user it is expected to ensure that device specified in DEVS section in /etc/sysconfig/docker-storage-setup does not contain file system signatures, or partitions.

Why does d-s-s run during boot, actually?  Shouldn't people run it
interactively after changing /e/s/d-s-s?  Or does it only run on first
boot?
If docker is enabled it will start d-s-s.

   Would it be acceptable to add a "--force-wipe" option to d-s-s, and
   maybe others?  I can do that at the same time as I write the code for
   the UI.
So --force-wipe is a new functionality. What will it do?
It would not do any safety checks while turning a block device into a
physical volume, with the assumption that the user has already
independently confirmed that all devices in DEVS are ok to be used for
the docker storage pool, no matter what they currently contain.

I now see that d-s-s refuses to touch a device that already has a
partition table on it.  The --force-wipe option would override this and
write a new one.

If you think that a --force-wipe option is not appropriate for d-s-s,
Cockpit can wipe the devices itself.  But I think the option is nicer.

   So I am thinking there could be something like

     # docker-storage-setup status
     /dev/vda: ok, shared with OS
     /dev/sda: ok
     /dev/sdb: Not yet set up!

     The Docker storage pool is not fully set up.  Run
     "docker-storage-setup" to complete the set up.
I think first what would be nice is to display current docker
configuration.
Certainly.  I will work first on what I need, of course, but I am hoping
that others chime in and extend the status output with other useful
things.

What does "shared with OS" mean? Does it mean, it is in same volume
group where rootfs is?
Yes, pretty much, but I am already changing my mind on the details.
This will all be properly documented once I have working code.


Thinking out loud:

I want to have three flags for each block device: "pool" if it holds any
bits of the docker storage pool, "config" if it is listed in /e/s/d-s-s,
and "other" if it holds any bits of other logical volumes.  That would
allow the UI to show the correct current state based on the "pool" flag.
The human readable output might highlight devices that are "config" but
not "pool", but I am not sure yet what the UI will do about them.  Maybe
nothing, maybe pre-select them in the "Additional storage" pane.

I think a reliable "other" flag will be interesting for a potential
"docker-storage-setup reset" operation.  This would remove the current
pool and create a new one, so that the user can meaningfully remove
devices from DEVS again.



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