Skip to content
This repository has been archived by the owner on Nov 9, 2020. It is now read-only.

Plugin client must print an error message in case of create error #616

Closed
govint opened this issue Oct 7, 2016 · 7 comments
Closed

Plugin client must print an error message in case of create error #616

govint opened this issue Oct 7, 2016 · 7 comments

Comments

@govint
Copy link
Contributor

govint commented Oct 7, 2016

Recent changes to formatting of the disks on the guest side may have introduced this error. When create hits an error condition we get this,

root@photon-jyLxAJ3OK [ ~ ]# docker volume create -d vmdk --name v2
Error response from daemon: create v2: Post http://%2Frun%2Fdocker%2Fplugins%2Fvmdk.sock/VolumeDriver.Create: http: ContentLength=24 with Body length 0

@brunotm
Copy link
Contributor

brunotm commented Oct 7, 2016

Hi @govint,

What's on the plugin logs?

@govint
Copy link
Contributor Author

govint commented Oct 7, 2016

These are the plugin logs,


10/07/16 06:00:12 117321 [P1] [INFO ] *** createVMDK:
/vmfs/volumes/Storage1/dockvols/v4.vmdk opts = {u'fstype': u'ext4'}
10/07/16 06:00:13 117321 [P1] [INFO ] executeRequest 'create' completed
with ret=None
10/07/16 06:00:13 117321 [P1] [INFO ] *** attachVMDK:
/vmfs/volumes/Storage1/dockvols/v4.vmdk to P1 VM uuid =
564dabc0-da80-2e80-1174-d92d69585cc4
10/07/16 06:00:13 117321 [P1] [INFO ] Attaching
/vmfs/volumes/Storage1/dockvols/v4.vmdk as independent_persistent
10/07/16 06:00:14 117321 [P1] [INFO ] Disk
/vmfs/volumes/Storage1/dockvols/v4.vmdk successfully attached. controller
pci_slot_number=192, disk_slot=1
10/07/16 06:00:14 117321 [P1] [INFO ] executeRequest 'attach' completed
with ret={'ControllerPciSlotNumber': '192', 'Unit': '1'}
10/07/16 06:00:14 117321 [P1] [INFO ] *** detachVMDK:
/vmfs/volumes/Storage1/dockvols/v4.vmdk from P1 VM uuid =
564dabc0-da80-2e80-1174-d92d69585cc4
10/07/16 06:00:14 117321 [P1] [INFO ] Disk detached
/vmfs/volumes/Storage1/dockvols/v4.vmdk
10/07/16 06:00:14 117321 [P1] [INFO ] executeRequest 'detach' completed
with ret=None
10/07/16 06:00:14 117321 [P1] [INFO ] *** removeVMDK:
/vmfs/volumes/Storage1/dockvols/v4.vmdk
10/07/16 06:00:15 117321 [P1] [INFO ] executeRequest 'remove' completed

with ret=None

On Fri, Oct 7, 2016 at 11:26 AM, Bruno Moura notifications@github.com
wrote:

Hi @govint https://github.com/govint,

What's on the plugin logs?


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
#616 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/APHseJrB-T3H7M-CKQJkJ2TUZ01WniQWks5qxd8agaJpZM4KQsdo
.

@brunotm
Copy link
Contributor

brunotm commented Oct 7, 2016

These are the server logs, can you add the plugin logs?

thanks!

@govint
Copy link
Contributor Author

govint commented Oct 7, 2016

Ok, this is a repro,

  1. Create volume v6
    root@photon-jyLxAJ3OK [ /sys ]# docker volume create -d vmdk --name v6

Error response from daemon: create v6: Post
http://%2Frun%2Fdocker%2Fplugins%2Fvmdk.sock/VolumeDriver.Create:
http: ContentLength=24 with Body length 0

  1. Client logs
    2016-10-07 09:01:05.127970653 +0000 UTC [INFO] Attaching volume and
    creating filesystem fstype=ext4 name=v6
    2016-10-07 09:01:05.740203226 +0000 UTC [WARNING] Get device path failed
    for unit# %s @ PCI slot %s: 1192Error="open /sys/bus/pci/slots/192/address:
    no such file or directory"
    2016-10-07 09:01:05.74026955 +0000 UTC [ERROR] Could not find attached
    device, removing the volume name=v6 error="Device not found"
  2. Server logs
    10/07/16 09:01:03 117321 [P1] [INFO ] executeRequest 'get' completed with
    ret={u'Error': 'Volume v6 not found (file:
    /vmfs/volumes/Storage1/dockvols/v6.vmdk)'}
    10/07/16 09:01:03 117321 [P1] [INFO ] *** createVMDK:
    /vmfs/volumes/Storage1/dockvols/v6.vmdk opts = {u'fstype': u'ext4'}
    10/07/16 09:01:05 117321 [P1] [INFO ] executeRequest 'create' completed
    with ret=None
    10/07/16 09:01:05 117321 [P1] [INFO ] *** attachVMDK:
    /vmfs/volumes/Storage1/dockvols/v6.vmdk to P1 VM uuid =
    564dabc0-da80-2e80-1174-d92d69585cc4
    10/07/16 09:01:05 117321 [P1] [INFO ] Attaching
    /vmfs/volumes/Storage1/dockvols/v6.vmdk as independent_persistent
    10/07/16 09:01:06 117321 [P1] [INFO ] Disk
    /vmfs/volumes/Storage1/dockvols/v6.vmdk successfully attached. controller
    pci_slot_number=192, disk_slot=1
    10/07/16 09:01:06 117321 [P1] [INFO ] executeRequest 'attach' completed
    with ret={'ControllerPciSlotNumber': '192', 'Unit': '1'}
    10/07/16 09:01:06 117321 [P1] [INFO ] *** detachVMDK:
    /vmfs/volumes/Storage1/dockvols/v6.vmdk from P1 VM uuid =
    564dabc0-da80-2e80-1174-d92d69585cc4
    10/07/16 09:01:06 117321 [P1] [INFO ] Disk detached
    /vmfs/volumes/Storage1/dockvols/v6.vmdk
    10/07/16 09:01:06 117321 [P1] [INFO ] executeRequest 'detach' completed
    with ret=None
    10/07/16 09:01:06 117321 [P1] [INFO ] *** removeVMDK:
    /vmfs/volumes/Storage1/dockvols/v6.vmdk
    10/07/16 09:01:07 117321 [P1] [INFO ] executeRequest 'remove' completed
    with ret=None

The guest is running docker 1.12 with API version 1.24. Seems like error
response to the docker daemon may be an issue or a docker bug itself.

On Fri, Oct 7, 2016 at 12:33 PM, Bruno Moura notifications@github.com
wrote:

These are the server logs, can you add the plugin logs?

thanks!


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
#616 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/APHseBZqgkwIPfRJOsiEVyQFUXJ-gsffks5qxe7HgaJpZM4KQsdo
.

@brunotm
Copy link
Contributor

brunotm commented Oct 7, 2016

This is the same as #614

@govint
Copy link
Contributor Author

govint commented Oct 7, 2016

No no, I'm looking at #614 and am seeing this error message thats not seen
earlier. :-))

On Fri, Oct 7, 2016 at 2:41 PM, Bruno Moura notifications@github.com
wrote:

This is the same as #614
#614


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
#616 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/APHseGeUSgPyOH_G31_aUJ-Odcax1kviks5qxgylgaJpZM4KQsdo
.

@brunotm
Copy link
Contributor

brunotm commented Oct 7, 2016

I think the problem itself is the same. But you're right, we're missing a error message for the user in some cases in the plugin.

I'm going to prepare a patch for testing.

# for free to subscribe to this conversation on GitHub. Already have an account? #.
Projects
None yet
Development

No branches or pull requests

2 participants