OpenStack Swift Object Storage on EMC Isilon

Introduction

EMC recently made good announcements on OpenStack solution starting from the acquisition of Cloudscaling, EMC Enterprise Hybrid Cloud OpenStack Edition and EMC OpenStack Reference Architecture Partner Program with RedHat, Ubuntu, and Mirantis.  Very exciting news that EMC is giving choices of solutions that customers feel comfortable with.

Another good news is that EMC Isilon with OneFS 7.2 now supports OpenStack Swift API.   Isilon is simple to manage, highly scalable (up to 30PB+ in a single namespace) and highly efficient (80%+ storage utilization) NAS platform.  Isilon helps customers to significantly reduce TCO and to resolve their storage management challenge.  Key benefits of Swift Object API support with Isilon are first, to allow objects seamlessly accessible as file with SMB, NFS, HTTP, FTP and HDFS.  You can build a use case like storing data as object using Swift API and run Hadoop MapReduce analysis job directly on those stored objects via HDFS.  Second, all Enterprise features like Dedupe, Snapshots, Storage Tiering are available to Swift Object Storage.  Many customers have been using those features for years and also willing to have with new cloud infrastructures as well.

In this post, I will demonstrate how OpenStack Swift API works with Isilon.

How Isilon Swift works

  1. Swift Object proxy service runs on every Isilon nodes to handle API requests
  2. Each home directory in the OneFS file system maps to a Swift account. The directories and subdirectories in a home directory map to containers and sub-containers. Files appear as objects.
  3. OneFS supports following authentication methods
    • TempAuth and Swauth modules
    • The Rackspace extension to the OpenStack Identity Service
    • The Get Token request supported by the Keystone authentication method
  4. When a user is authenticated successfully, OneFS generates a unique authentication token for the user.  The token lets the user performs Swift API request without a username and a password each time.
  5. Swift API as just “another” protocol.  Again, all existing Enterprise features below that customers like are available to Swift Object Storage.
    • High-Efficiency data protection with FEC (forward error correction) code
    • Dedupe
    • Storage Tiering
    • Snapshots/Replication
    • Compliance WORM
    • NDMP backup

Isilon-swift

API request using cURL

In this example, I used

  • Storage URL (Iislon SmartConnect zone name): http://swift.isilon72.home.local
  • Account: masa
  • Password: password

Authentication using standard TempAuth

The response includes an access token and a storage access token and URL, which the client uses for subsequent requests.

[root@centos ~]# curl -H "X-Auth-User: account:masa" -H "X-Auth-Key:password" -v "http://swift.isilon72.home.local:28080/auth/v1.0" -X GET
* About to connect() to swift.isilon72.home.local port 28080 (#0)
* Trying 192.168.1.112... connected
* Connected to swift.isilon72.home.local (192.168.1.112) port 28080 (#0)
> GET /auth/v1.0 HTTP/1.1
> User-Agent: curl/7.19.7 (x86_64-redhat-linux-gnu) libcurl/7.19.7 NSS/3.15.3 zlib/1.2.3 libidn/1.18 libssh2/1.4.2
> Host: swift.isilon72.home.local:28080
> Accept: */*
> X-Auth-User: account:masa
> X-Auth-Key:password
>
< HTTP/1.1 200 OK
< Content-Length: 114
< Content-Type: application/json; charset=utf-8
< Date: Mon, 24 Nov 2014 15:41:41 EST
< X-Auth-Token: AUTH_tk839346cbf6767f7e940e604ee20f7b24
< X-Storage-Token: AUTH_tk839346cbf6767f7e940e604ee20f7b24
< X-Storage-Url: http://swift.isilon72.home.local:28080/v1/AUTH_account
< X-Trans-Id: tx93db8f30a0ed4a7f94c7b-0054739805
<
* Connection #0 to host swift.isilon72.home.local left intact
* Closing connection #0
{"storage": {"cluster_name": "http://swift.isilon72.home.local:28080/v1/AUTH_account", "default": "cluster_name"}}
[root@centos ~]#

PUT Container

Create a new container called “container1” using the acquired token.

[root@centos ~]# curl -H "X-Auth-Token:AUTH_tk839346cbf6767f7e940e604ee20f7b24" -v "http://swift.isilon72.home.local:28080/v1/AUTH_masa/container1" -X PUT
* About to connect() to swift.isilon72.home.local port 28080 (#0)
* Trying 192.168.1.112... connected
* Connected to swift.isilon72.home.local (192.168.1.112) port 28080 (#0)
> PUT /v1/AUTH_masa/container1 HTTP/1.1
> User-Agent: curl/7.19.7 (x86_64-redhat-linux-gnu) libcurl/7.19.7 NSS/3.15.3 zlib/1.2.3 libidn/1.18 libssh2/1.4.2
> Host: swift.isilon72.home.local:28080
> Accept: */*
> X-Auth-Token:AUTH_tk839346cbf6767f7e940e604ee20f7b24
>
< HTTP/1.1 201 Created
< Content-Length: 0
< Content-Type: text/html; charset=UTF-8
< Date: Mon, 24 Nov 2014 15:43:07 EST
< X-Trans-Id: tx06ebdc49f767460f8ca74-005473985a
<
* Connection #0 to host swift.isilon72.home.local left intact
* Closing connection #0
[root@centos ~]#

POST Container

Set the custom metadata tags of the container created as below

  • X-Container-Meta-Owner: Masa
  • X-Container-Meta-Doc-Types: Technical
[root@centos ~]# curl -H "X-Auth-Token:AUTH_tk839346cbf6767f7e940e604ee20f7b24" -v "http://swift.isilon72.home.local:28080/v1/AUTH_masa/container1" -X POST -H "X-Container-Meta-Owner: Masa" -H "X-Container-Meta-Doc-Types: Technical"
* About to connect() to swift.isilon72.home.local port 28080 (#0)
* Trying 192.168.1.111... connected
* Connected to swift.isilon72.home.local (192.168.1.111) port 28080 (#0)
> POST /v1/AUTH_masa/container1 HTTP/1.1
> User-Agent: curl/7.19.7 (x86_64-redhat-linux-gnu) libcurl/7.19.7 NSS/3.15.3 zlib/1.2.3 libidn/1.18 libssh2/1.4.2
> Host: swift.isilon72.home.local:28080
> Accept: */*
> X-Auth-Token:AUTH_tk839346cbf6767f7e940e604ee20f7b24
> X-Container-Meta-Owner: Masa
> X-Container-Meta-Doc-Types: Technical
>
< HTTP/1.1 204 No Content
< Content-Length: 0
< Content-Type: text/html; charset=UTF-8
< Date: Mon, 24 Nov 2014 16:05:47 EST
< X-Trans-Id: txdddf8903eed94e099cfd7-0054739dab
<
* Connection #0 to host swift.isilon72.home.local left intact
* Closing connection #0
[root@centos ~]#

POST Object

Create a object called “object1.txt” with content “hello swift” in “container1”.

[root@centos ~]# curl -H "X-Auth-Token:AUTH_tk839346cbf6767f7e940e604ee20f7b24" -v "http://swift.isilon72.home.local:28080/v1/AUTH_masa/container1/object1.txt" -X PUT -d "hello swift"
* About to connect() to swift.isilon72.home.local port 28080 (#0)
* Trying 192.168.1.113... connected
* Connected to swift.isilon72.home.local (192.168.1.113) port 28080 (#0)
> PUT /v1/AUTH_masa/container1/object1.txt HTTP/1.1
> User-Agent: curl/7.19.7 (x86_64-redhat-linux-gnu) libcurl/7.19.7 NSS/3.15.3 zlib/1.2.3 libidn/1.18 libssh2/1.4.2
> Host: swift.isilon72.home.local:28080
> Accept: */*
> X-Auth-Token:AUTH_tk839346cbf6767f7e940e604ee20f7b24
> Content-Length: 11
> Content-Type: application/x-www-form-urlencoded
>
< HTTP/1.1 201 Created
< Content-Length: 0
< Content-Type: text/html; charset=UTF-8
< Date: Mon, 24 Nov 2014 16:10:21 EST
< ETag: 88436debb01d6c1c0ed4a1b81b8c33c5
< X-Trans-Id: tx9bf59a74a4254b9f8c678-0054739ebd
<
* Connection #0 to host swift.isilon72.home.local left intact
* Closing connection #0
[root@centos ~]#

GET Container

Obtain information about “container1”.

[root@centos ~]# curl -H "X-Auth-Token:AUTH_tk839346cbf6767f7e940e604ee20f7b24" -v "http://swift.isilon72.home.local:28080/v1/AUTH_masa/container1?format=json" -X GET
* About to connect() to swift.isilon72.home.local port 28080 (#0)
* Trying 192.168.1.112... connected
* Connected to swift.isilon72.home.local (192.168.1.112) port 28080 (#0)
> GET /v1/AUTH_masa/container1?format=json HTTP/1.1
> User-Agent: curl/7.19.7 (x86_64-redhat-linux-gnu) libcurl/7.19.7 NSS/3.15.3 zlib/1.2.3 libidn/1.18 libssh2/1.4.2
> Host: swift.isilon72.home.local:28080
> Accept: */*
> X-Auth-Token:AUTH_tk839346cbf6767f7e940e604ee20f7b24
>
< HTTP/1.1 200 OK
< X-Container-Meta-Doc-Types: Technical
< X-Container-Meta-Owner: Masa
< Accept-Ranges: bytes
< Content-Length: 221
< Content-Type: application/json; charset=utf-8
< Date: Mon, 24 Nov 2014 16:10:34 EST
< Last-Modified: 2014-11-24 16:10:21
< X-Container-Bytes-Used: 11
< X-Container-Object-Count: 1
< X-Timestamp: 130613370210956644
< X-Trans-Id: tx1634a99c4550448dbc5c4-0054739eca
<
[
 {
 "hash": "88436debb01d6c1c0ed4a1b81b8c33c5",
 "last_modified": "2014-11-24 16:10:21",
 "bytes": "11",
 "name": "object1.txt",
 "content_type": "application/octet-stream"
 }
]
* Connection #0 to host swift.isilon72.home.local left intact
* Closing connection #0
[root@centos ~]#

HEAD Account

Retrieve account statistics, metadata, and the values of the custom metadata tags

[root@centos ~]# curl -H "X-Auth-Token:AUTH_tk839346cbf6767f7e940e604ee20f7b24" -v "http://swift.isilon72.home.local:28080/v1/AUTH_masa" -X HEAD
* About to connect() to swift.isilon72.home.local port 28080 (#0)
* Trying 192.168.1.111... connected
* Connected to swift.isilon72.home.local (192.168.1.111) port 28080 (#0)
> HEAD /v1/AUTH_masa HTTP/1.1
> User-Agent: curl/7.19.7 (x86_64-redhat-linux-gnu) libcurl/7.19.7 NSS/3.15.3 zlib/1.2.3 libidn/1.18 libssh2/1.4.2
> Host: swift.isilon72.home.local:28080
> Accept: */*
> X-Auth-Token:AUTH_tk839346cbf6767f7e940e604ee20f7b24
>
< HTTP/1.1 204 No Content
< Content-Length: 0
< Content-Type: text/html; charset=UTF-8
< Date: Mon, 24 Nov 2014 16:15:35 EST
< Last-Modified: 2014-11-24 15:43:07
< X-Account-Bytes-Used: 11
< X-Account-Container-Count: 1
< X-Account-Object-Count: 1
< X-Timestamp: 130613353870114877
< X-Trans-Id: tx71b8b188bfba4a008ffe7-0054739ff7
<
* Connection #0 to host swift.isilon72.home.local left intact
* Closing connection #0

API request using Swift CLI

The Swift CLI is part of the python-swiftclient package and can be installed on any computer running Python 2.6 or 2.7.

  • Installed python-swiftclient 2.3.1 on same CentOS client
  • Auth version 1.0 (Standard TempAuth) is used in this example

swift list (HTTP GET) Container & Object

[root@centos ~]# swift list -A http://swift.isilon72.home.local:28080/auth/v1.0 -U masa -K password
container1
[root@centos ~]# swift list container1 -A http://swift.isilon72.home.local:28080/auth/v1.0 -U masa -K password
object1.txt
[root@centos ~]#

swift stat (HTTP HEAD) Container

[root@centos ~]# swift stat container1 -A http://swift.isilon72.home.local:28080/auth/v1.0 -U masa -K password
 Account: AUTH_masa
 Container: container1
 Objects: 1
 Bytes: 11
 Read ACL:
 Write ACL:
 Sync To:
 Sync Key:
Meta Doc-Types: Technical
 Meta Owner: Masa
 Accept-Ranges: bytes
 Last-Modified: 2014-11-24 16:10:21
 X-Timestamp: 130613370210956644
 X-Trans-Id: txa526a5fc4df14bc3b1a8c-005473baa3
 Content-Type: text/html; charset=UTF-8
[root@centos ~]#

swift download (HTTP GET) Object

[root@centos ~]# swift download container1 -A http://swift.isilon72.home.local:28080/auth/v1.0 -U masa -K password
object1.txt [auth 0.012s, headers 0.019s, total 0.019s, 0.002 MB/s]
[root@centos ~]#
[root@centos ~]# cat object1.txt
hello swift[root@centos ~]#
[root@centos ~]#

Accessing object as a file from SMB client

Let’s try to access object from Windows client via SMB.  As described earlier a Swift account maps to each home directory in the OneFS. Containers and subcontainers map to directories and subdirectories in a home directory.  Objects appear as files.

Object: http://swift.isilon72.home.local:28080/v1/AUTH_masa/container1/object1.txt

File: \\swift.isilon72.home.local\ifs\home\masa\container1\object1.txt

Screen Shot 2014-11-25 at 2.37.12 PM

For more information

If you want to learn more about Isilon Swift, please refer to below white papers

Also, you can download EMC Isilon OneFS simulator from here http://www.emc.com/getisilon.