[Openstack] Swift downloading only manifest of static large object (SLO)

Samuel Merritt sam at swiftstack.com
Thu Mar 13 06:09:09 UTC 2014


On 3/12/14 9:14 PM, Ben McCann wrote:
> Hi,
>
> I'm attempting to download a large file which I have uploaded to
> SoftLayer Object Storage using the swift tool. It's downloading only the
> manifest and is not downloading the segments. Any tips on figuring out
> what is going wrong?

It's entirely possible that the cluster in question lacks static large 
object support. Maybe they're running an old version of Swift 
(pre-1.8.0/Grizzly), or maybe they haven't enabled the static large 
object feature.

What you'll need to do is probe the cluster to see if static large 
objects are enabled.

The easy way is to politely ask the cluster with a GET request to /info. 
Run `swift stat -v`, then take the "StorageURL" field and change the 
path to be just "/info". Strip off any path that's already there.

For example, if the output looks like

     StorageURL: http://192.168.22.2:8080/v1/AUTH_test
     Auth Token: AUTH_tk89454677b67348e09eefc1d6fe4dfa68
        Account: AUTH_test
     Containers: 1
     [...]

then you'd simply run

     curl http://192.168.22.2:8080/info

The response will be a JSON hash, so maybe run it through a JSON 
pretty-printer, e.g.

     curl http://192.168.22.2:8080/info | python -mjson.tool

On my development machine, the response looks something like this (some 
items removed for brevity):

{
     "container_quotas": {},
     "formpost": {},
     "slo": {                   <---- LOOK FOR THIS
         "max_manifest_segments": 1000,
         "max_manifest_size": 2097152,
         "min_segment_size": 71
     },
     "swift": {
         "account_listing_limit": 10000,
         "container_listing_limit": 10000,
         "max_account_name_length": 256,
         "max_container_name_length": 256,
         "max_file_size": 5368709122,
         "max_meta_count": 90,
         "max_meta_name_length": 128,
         "max_meta_value_length": 256,
         "max_object_name_length": 1024,
         "version": "1.12.0.106.ga08e813"
     }
}

If you don't see SLO in there, then you're out of luck. Bug Softlayer 
and see if they'll turn it on.

Now, it's also possible that you'll get a 412 response with the body 
"Bad URL" when you run the curl command above. That will tell you that 
the cluster is running 1.11.0 or earlier, but it won't tell you anything 
about SLO support. In that case, try uploading a normal file (cat 
picture or something) with the header "X-Static-Large-Object: yes". If 
that succeeds, then SLO is disabled; if SLO is enabled, then the PUT 
will fail.

A more verbose description is available here: 
https://ask.openstack.org/en/question/7005/static-large-objects/





More information about the Openstack mailing list