cloudstack-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mike Tutkowski <mike.tutkow...@solidfire.com>
Subject Re: createStoragePool API Question
Date Tue, 19 Feb 2013 03:27:20 GMT
Turns out it was a problem with URL encoding.  The example I was following
didn't need to URL encode anything and that happened to work for two out of
the three API calls I was trying to make (but the iscsi part of
createStoragePool needed to be URL encoded to work).


On Mon, Feb 18, 2013 at 4:27 PM, Mike Tutkowski <
mike.tutkowski@solidfire.com> wrote:

> I wonder if the problem perhaps is the iscsi:// part of the query string.
>  Do I maybe have to do something special with that (URL encode)?
>
>
> On Mon, Feb 18, 2013 at 2:44 PM, Mike Tutkowski <
> mike.tutkowski@solidfire.com> wrote:
>
>> For example, deployVirtualMachine (works):
>>
>>
>> http://127.0.0.1:8080/client/api?command=deployVirtualMachine&serviceOfferingId=ad8921ce-79e9-11e2-9ad2-3fe5c11831af&templateId=3bb9efd1-42f1-4413-be98-57c49c6dc12b&zoneId=a39e2c4c-7172-4045-b692-b6053b0ba01a&userdata=xyz&response=json&apiKey=JZ13Mfqe6VJDs7iJxQL1JlsUbxdoSM7xrDMe65-PSggfcTTM61yZCrM7ol8Lr4vZf2kTUU0oSnjuwJZ2Y-Jc7A&signature=0c%2FD2NoiKRrcD5CV6o4r2U5SXGg%3D
>>
>>
>> createStoragePool (fails with 401):
>>
>>
>> http://127.0.0.1:8080/client/api?command=createStoragePool&name=SolidFirePS33416652&url=iscsi://192.168.56.7/iqn.2013-01.com.solidfire:volume-1/0&zoneId=a39e2c4c-7172-4045-b692-b6053b0ba01a&podId=4d95c83b-da35-463d-8557-5f1912c8f978&clusterId=6dcc24e2-bb32-4413-b654-ea956b565b3e&response=json&apiKey=JZ13Mfqe6VJDs7iJxQL1JlsUbxdoSM7xrDMe65-PSggfcTTM61yZCrM7ol8Lr4vZf2kTUU0oSnjuwJZ2Y-Jc7A&signature=cwJpUdj0Zc7QX2cvOp16WXkuw7E%3D
>>
>>
>>
>> On Mon, Feb 18, 2013 at 2:35 PM, Mike Tutkowski <
>> mike.tutkowski@solidfire.com> wrote:
>>
>>> So, when I call createStoragePool, I get back the following error:
>>>
>>> { "createstoragepoolresponse" : {"uuidList":[],"errorcode":401,"errortext":"unable
to verify user credentials and/or request signature"} }
>>>
>>> Do I have to send an authentication header field for such an API call?
>>>
>>> Thanks!
>>>
>>>
>>>
>>> On Mon, Feb 18, 2013 at 12:24 AM, Mike Tutkowski <
>>> mike.tutkowski@solidfire.com> wrote:
>>>
>>>> Great, thanks a lot!
>>>>
>>>>
>>>> On Mon, Feb 18, 2013 at 12:07 AM, Sowmya Krishnan <
>>>> sowmya.krishnan@citrix.com> wrote:
>>>>
>>>>> Mike, you're right - the URL parameter should include IP address,
>>>>> Target IQN and LUN in the following format: url= iscsi://IP address/target
>>>>> IQN/LUN
>>>>>
>>>>> This worked for me:
>>>>> http://localhost:8096/client/api?command=createStoragePool&name=PS2iscsi&url=iscsi://10.X.X.X/iqn.2004XXXX/0&zoneid=f7f9bd51-1860-438b-8c32-b669fa8e9677&clusterid=fdc03b94-2ff1-4a41-ae43-b2e296c4bf2c&podid=f43c0b43-cc85-41e6-91af-00fd09924fac
>>>>>
>>>>>
>>>>> -----Original Message-----
>>>>> From: Mike Tutkowski [mailto:mike.tutkowski@solidfire.com]
>>>>> Sent: Monday, February 18, 2013 11:39 AM
>>>>> To: cloudstack-dev@incubator.apache.org
>>>>> Subject: createStoragePool API Question
>>>>>
>>>>> Hi everyone,
>>>>>
>>>>> I'm trying to reconcile the API doc here with what I see in the GUI:
>>>>>
>>>>>
>>>>> http://incubator.apache.org/cloudstack/docs/api/apidocs-4.0.0/root_admin/createStoragePool.html
>>>>>
>>>>> *Parameter Name*DescriptionRequired*name**the name for the storage
>>>>> pool** true**url**the URL of the storage pool**true**zoneid**the Zone
ID
>>>>> for the storage pool**true**clusterid**the cluster ID for the storage
>>>>> pool**false** details**the details for the storage pool**false**podid**the
>>>>> Pod ID for the storage pool**false**tags**the tags for the storage
>>>>> pool**false*
>>>>>
>>>>> In the GUI, the requested text fields are the following (when Protocol
>>>>> =
>>>>> iSCSI):  Zone, Pod, Cluster, Name, Protocol, Server, Target IQN, LUN,
>>>>> and Storage Tags.
>>>>>
>>>>> So, what I'm wondering is where do I pass in the IP address of the
>>>>> Server, the Target IQN, and the LUN?  It seems like the URL parameter
might
>>>>> be for this, but - if so - what format do I need to pass this info in
as?
>>>>>
>>>>> Thanks!
>>>>>
>>>>> --
>>>>> *Mike Tutkowski*
>>>>> *Senior CloudStack Developer, SolidFire Inc.*
>>>>> e: mike.tutkowski@solidfire.com
>>>>> o: 303.746.7302
>>>>> Advancing the way the world uses the
>>>>> cloud<http://solidfire.com/solution/overview/?video=play>
>>>>> *(tm)*
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> *Mike Tutkowski*
>>>>  *Senior CloudStack Developer, SolidFire Inc.*
>>>> e: mike.tutkowski@solidfire.com
>>>> o: 303.746.7302
>>>> Advancing the way the world uses the cloud<http://solidfire.com/solution/overview/?video=play>
>>>> *™*
>>>>
>>>
>>>
>>>
>>> --
>>> *Mike Tutkowski*
>>> *Senior CloudStack Developer, SolidFire Inc.*
>>> e: mike.tutkowski@solidfire.com
>>> o: 303.746.7302
>>> Advancing the way the world uses the cloud<http://solidfire.com/solution/overview/?video=play>
>>> *™*
>>>
>>
>>
>>
>> --
>> *Mike Tutkowski*
>> *Senior CloudStack Developer, SolidFire Inc.*
>> e: mike.tutkowski@solidfire.com
>> o: 303.746.7302
>> Advancing the way the world uses the cloud<http://solidfire.com/solution/overview/?video=play>
>> *™*
>>
>
>
>
> --
> *Mike Tutkowski*
> *Senior CloudStack Developer, SolidFire Inc.*
> e: mike.tutkowski@solidfire.com
> o: 303.746.7302
> Advancing the way the world uses the cloud<http://solidfire.com/solution/overview/?video=play>
> *™*
>



-- 
*Mike Tutkowski*
*Senior CloudStack Developer, SolidFire Inc.*
e: mike.tutkowski@solidfire.com
o: 303.746.7302
Advancing the way the world uses the
cloud<http://solidfire.com/solution/overview/?video=play>
*™*

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message