tempauth for swift

classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|

tempauth for swift

yahoorocks
Hello,

If you get swift to auth with tempauth, would you kind enough to share the xml template for cosbench? I don't have keystone setup.

much appreciated!!

-Jimmy
Reply | Threaded
Open this post in threaded view
|

Re: tempauth for swift

ywang19
Administrator
For openstack swift, COSBench supports tempauth, swauth and keystone. Actually, tempauth and swauth share the same authentication module and name "swauth".

COSbench package includes a few workload samples for different storage systems under "conf" folder, here is the link to swift sample, which is with "swauth" enabled:

https://github.com/intel-cloud/cosbench/blob/master/release/conf/swift-config-sample.xml


Hope it helps.

-Y.G.
Reply | Threaded
Open this post in threaded view
|

Re: tempauth for swift

yahoorocks
Thank you much.

I see keystone is also in the xml, do I have to remove it knowing that I am using tempauth?

Thanks,
Jimmy
Reply | Threaded
Open this post in threaded view
|

Re: tempauth for swift

yahoorocks
In reply to this post by ywang19
Hi Y.G.

I don't see where I can specify the x-Auth Token for tempauth and also the container. Do I need to specify in the workload.xml or the swift.xml?

Thanks again!!

-Jimmy
Reply | Threaded
Open this post in threaded view
|

Re: tempauth for swift

yahoorocks
Hi Y.G.

Please ignore my dumb question about portforwarding. I have a workaround and able to see the GUI.

So, I submitted a workload and it terminated right away. I downloaded the log and saw that it can't authenticated. I think I am missing something. Please advise.

Thanks a bunch!!

[root@cleverloadgen10 Downloads]# cat workload-log.txt
================================================== stage: s1 ==================================================
---------------------------------- mission: MF3209AD103, driver: driver1 ----------------------------------
2013-07-30 17:03:49,463 [INFO] [Log4jLogManager] - will append log to file /home/jlu/cosbench/0.3.1.1/log/mission/MF3209AD103.log
2013-07-30 17:03:49,532 [ERROR] [AbstractOperator] - fail to perform prepare operation
com.intel.cosbench.api.storage.StorageException: HTTP/1.1 401 Unauthorized
        at com.intel.cosbench.api.swift.SwiftStorage.createContainer(SwiftStorage.java:128)
        at com.intel.cosbench.driver.operator.Preparer.doInit(Preparer.java:110)
        at com.intel.cosbench.driver.operator.Preparer.operate(Preparer.java:85)
        at com.intel.cosbench.driver.operator.AbstractOperator.operate(AbstractOperator.java:53)
        at com.intel.cosbench.driver.operator.Initializer.operate(Initializer.java:1)
        at com.intel.cosbench.driver.agent.WorkAgent.performOperation(WorkAgent.java:175)
        at com.intel.cosbench.driver.agent.WorkAgent.doWork(WorkAgent.java:161)
        at com.intel.cosbench.driver.agent.WorkAgent.execute(WorkAgent.java:118)
        at com.intel.cosbench.driver.agent.AbstractAgent.call(AbstractAgent.java:44)
        at com.intel.cosbench.driver.agent.AbstractAgent.call(AbstractAgent.java:1)
        at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
        at java.util.concurrent.FutureTask.run(FutureTask.java:166)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
        at java.lang.Thread.run(Thread.java:781)
Caused by: com.intel.cosbench.client.swift.SwiftException: unexpected return from server
        at com.intel.cosbench.client.swift.SwiftClient.createContainer(SwiftClient.java:129)
        at com.intel.cosbench.api.swift.SwiftStorage.createContainer(SwiftStorage.java:119)
        ... 14 more
================================================== stage: s2 ==================================================
================================================== stage: s3 ==================================================
================================================== stage: s4 ==================================================
================================================== stage: s5 ==================================================
[root@cleverloadgen10 Downloads]#


-Jimmy
Reply | Threaded
Open this post in threaded view
|

RE: tempauth for swift

ywang19
Administrator

Jimmy,

 

Before running COSBench, be sure your swift setup working with tempauth through swift command, and could you also paste out your workload configuration file?

 

-Y.G.

 

From: yahoorocks [via cosbench] [mailto:ml-node+[hidden email]]
Sent: Wednesday, July 31, 2013 8:08 AM
To: Wang, Yaguang
Subject: Re: tempauth for swift

 

Hi Y.G.

Please ignore my dumb question about portforwarding. I have a workaround and able to see the GUI.

So, I submitted a workload and it terminated right away. I downloaded the log and saw that it can't authenticated. I think I am missing something. Please advise.

Thanks a bunch!!

[root@cleverloadgen10 Downloads]# cat workload-log.txt
================================================== stage: s1 ==================================================
---------------------------------- mission: MF3209AD103, driver: driver1 ----------------------------------
2013-07-30 17:03:49,463 [INFO] [Log4jLogManager] - will append log to file /home/jlu/cosbench/0.3.1.1/log/mission/MF3209AD103.log
2013-07-30 17:03:49,532 [ERROR] [AbstractOperator] - fail to perform prepare operation
com.intel.cosbench.api.storage.StorageException: HTTP/1.1 401 Unauthorized
        at com.intel.cosbench.api.swift.SwiftStorage.createContainer(SwiftStorage.java:128)
        at com.intel.cosbench.driver.operator.Preparer.doInit(Preparer.java:110)
        at com.intel.cosbench.driver.operator.Preparer.operate(Preparer.java:85)
        at com.intel.cosbench.driver.operator.AbstractOperator.operate(AbstractOperator.java:53)
        at com.intel.cosbench.driver.operator.Initializer.operate(Initializer.java:1)
        at com.intel.cosbench.driver.agent.WorkAgent.performOperation(WorkAgent.java:175)
        at com.intel.cosbench.driver.agent.WorkAgent.doWork(WorkAgent.java:161)
        at com.intel.cosbench.driver.agent.WorkAgent.execute(WorkAgent.java:118)
        at com.intel.cosbench.driver.agent.AbstractAgent.call(AbstractAgent.java:44)
        at com.intel.cosbench.driver.agent.AbstractAgent.call(AbstractAgent.java:1)
        at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
        at java.util.concurrent.FutureTask.run(FutureTask.java:166)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
        at java.lang.Thread.run(Thread.java:781)
Caused by: com.intel.cosbench.client.swift.SwiftException: unexpected return from server
        at com.intel.cosbench.client.swift.SwiftClient.createContainer(SwiftClient.java:129)
        at com.intel.cosbench.api.swift.SwiftStorage.createContainer(SwiftStorage.java:119)
        ... 14 more
================================================== stage: s2 ==================================================
================================================== stage: s3 ==================================================
================================================== stage: s4 ==================================================
================================================== stage: s5 ==================================================
[root@cleverloadgen10 Downloads]#


-Jimmy


If you reply to this email, your message will be added to the discussion below:

http://cosbench.1094679.n5.nabble.com/tempauth-for-swift-tp19p26.html

To start a new topic under cosbench-user, email [hidden email]
To unsubscribe from cosbench, click here.
NAML

Reply | Threaded
Open this post in threaded view
|

Re: tempauth for swift

ywang19
Administrator
In reply to this post by yahoorocks
x-auth-token is returned after successful authentication, and implicitly set in following storage operations implicitly, user doesn't need explicitly set the parameter in workload configuration.

As shown in sample configuration, you need set correct parameters for authentication, after authenticated, you can access swift storage, no parameter needs set in <storage> part for swift type.

  <auth type="swauth" config="<b>username=test:tester;password=testing;auth_url=http://192.168.10.1:8080/auth/v1.0" />
  <storage type="swift" />
Reply | Threaded
Open this post in threaded view
|

Re: tempauth for swift

yahoorocks
Here you go my workload template - http://paste.openstack.org/raw/42800/

Reply | Threaded
Open this post in threaded view
|

Re: tempauth for swift

ywang19
Administrator
The error indicates there are issues on authentication information configured in your swift cluster, I'd suggest you to have a check on it with swift/swauth itself command line tools.

From your <auth> section, the command line would be:
> swift -A http://10.218.50.78:8080/auth/v1.0 -U admin:admin -K admin stat


-Y.G.