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

Corrupted reply mesage to a typo in docker volume create command #1002

Closed
shuklanirdesh82 opened this issue Mar 7, 2017 · 2 comments · Fixed by #1004
Closed

Corrupted reply mesage to a typo in docker volume create command #1002

shuklanirdesh82 opened this issue Mar 7, 2017 · 2 comments · Fixed by #1004

Comments

@shuklanirdesh82
Copy link
Contributor

shuklanirdesh82 commented Mar 7, 2017

Getting Valid options and defaults: <zip object at 0x431f1f6b48> when there is a typo in volume creation command input

root@photon-xVmYMbyTn [ ~ ]# docker volume create --driver=vsphere --name abc334@vsanDatastore -o size=1MB -o vsan-policy-nam=abc     
Error response from daemon: create abc334@vsanDatastore: VolumeDriver.Create: Invalid options: ['vsan-policy-nam'] 
Valid options and defaults: <zip object at 0x431f1f6b48>

---------docker-volume-vsphere.log---------

2017-03-07 07:23:57.338452077 +0000 UTC [ERROR] Create volume failed error="Invalid options: ['vsan-policy-nam'] \nValid options and defaults: <zip object at 0x431f1f7248>" name="abc334@vsanDatastore"

---------vmdk_ops.log---------

03/07/17 07:23:53 1321926 [Thread-71] [INFO   ] cmd create with opts {'vsan-policy-nam': 'abc', 'size': '1MB', 'fstype': 'ext4'} on tenant_uuid 42b1a76c-65df-4cf6-b18d-9dd17b684a9b datastore vsanDatastore is allowed to execute
03/07/17 07:23:53 1321926 [vmFolderPhoton-[vsanDatastore] dockvols/42b1a76c-65df-4cf6-b18d-9dd17b684a9b/abc334.vmdk] [INFO   ] *** createVMDK: /vmfs/volumes/vsanDatastore/dockvols/42b1a76c-65df-4cf6-b18d-9dd17b684a9b/abc334.vmdk opts = {'vsan-policy-nam': 'abc', 'size': '1MB', 'fstype': 'ext4'}
03/07/17 07:23:53 1321926 [vmFolderPhoton-[vsanDatastore] dockvols/42b1a76c-65df-4cf6-b18d-9dd17b684a9b/abc334.vmdk] [INFO   ] executeRequest 'create' completed with ret={'Error': "Invalid options: ['vsan-policy-nam'] \nValid options and defaults: <zip object at 0x431f1f7248>"}

Plugin/driver version information:
On VM: docker-volume-vsphere-0.12.3f64805-1.x86_64

on ESX:

[root@sc-rdops-vm10-dhcp-36-198:~] /usr/lib/vmware/vmdkops/bin/vmdkops_admin.py status
Version: 0.12.3f64805-0.0.1
Status: Running
Pid: 1321926
@pdhamdhere
Copy link
Contributor

@pshahzeb related to recent change?

@pshahzeb
Copy link
Contributor

pshahzeb commented Mar 7, 2017

Yes somewhat. From python3, the zip function returns an iterator instead of a list. https://docs.python.org/3/library/functions.html#zip

Fixing this.

@msterin msterin changed the title Unable to get valid supported options with defaults when there is a typo in volume creation command input Corrupted reply mesage to a typo in docker volume create command Mar 7, 2017
pshahzeb pushed a commit that referenced this issue Mar 8, 2017
zip() function in python3 returns an iterator. So creating a list from it for
proper error info message printing for docker volume create command

Resolves: #1002
shuklanirdesh82 pushed a commit that referenced this issue Mar 9, 2017
…nd (#1004)

zip() function in python3 returns an iterator. So creating a list from it for
proper error info message printing for docker volume create command

Resolves: #1002
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
3 participants