Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docker-storage-setup fails but has already gone half way #63

Open
jeremyeder opened this issue Jul 29, 2015 · 1 comment
Open

docker-storage-setup fails but has already gone half way #63

jeremyeder opened this issue Jul 29, 2015 · 1 comment

Comments

@jeremyeder
Copy link

docker-1.7.1-108.el7.x86_64

Trying to swap between overlay and devicemapper backend...

Added a new disk to the VM, and edited /etc/sysconfig/docker-storage-setup so it contains:
DEVS=/dev/vdc
VG=docker

Ran docker-storage-setup and...

# docker-storage-setup 
  WARNING: Device for PV VP6BxI-8NYd-kpBe-Xlr7-LJLO-dmGo-zR2bSx not found or rejected by a filter.
Checking that no-one is using this disk right now ...
OK

Disk /dev/vdc: 416101 cylinders, 16 heads, 63 sectors/track
sfdisk:  /dev/vdc: unrecognized partition table type

Old situation:
sfdisk: No partitions found

New situation:
Units: sectors of 512 bytes, counting from 0

   Device Boot    Start       End   #sectors  Id  System
/dev/vdc1          2048 419430399  419428352  8e  Linux LVM
/dev/vdc2             0         -          0   0  Empty
/dev/vdc3             0         -          0   0  Empty
/dev/vdc4             0         -          0   0  Empty
Warning: partition 1 does not start at a cylinder boundary
Warning: partition 1 does not end at a cylinder boundary
Warning: no primary partition is marked bootable (active)
This does not matter for LILO, but the DOS MBR will not boot this disk.
Successfully wrote the new partition table

Re-reading the partition table ...

If you created or changed a DOS partition, /dev/foo7, say, then use dd(1)
to zero the first 512 bytes:  dd if=/dev/zero of=/dev/foo7 bs=512 count=1
(See fdisk(8).)
  Replacing dev /dev/vdc1 pvid VP6BxI8NYdkpBeXlr7LJLOdmGozR2bSx with dev /dev/vdc1 pvid GsLnMJ348U0S4TTr1l24QgrJYo2ZC1A4
  Physical volume "/dev/vdc1" successfully created
  Volume group "docker" successfully created
Storage is already configured with overlay driver. Can't configure it with devicemapper driver. To override, remove /etc/sysconfig/docker-storage and retry.

If it's going to error-out with some warning about existing overlay, why bother doing anything to the hard drives? I think you should move that check up to the front of the script.

@rhvgoyal
Copy link
Collaborator

@jeremyeder

This utility currently does two major jobs.

  • Grow rootfs
  • Setup storage

Because we can't setup storage does not mean we should not try to grow root (after adding specified disks to volume group). Hence the check is in second part and we still try to grow root first.

I think this behavior is resonable. We instead need to figure out why partitioning disk, adding it to volume group is giving so many errors in your case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants