After Deprec

openstack_cloud_computing_cookbook

Issue link: https://read.uberflip.com/i/1334488

Contents of this Issue

Navigation

Page 124 of 317

Using OpenStack Storage 114 How to do it... Carry out the following steps to upload large objects, split into smaller segments: Uploading objects 1. We will first start by creating a 1 GB file under /tmp as an example file to upload. We do this as follows: dd if=/dev/zero of=/tmp/example-1Gb bs=1M count=1024 2. Rather than upload this file as a single object, we will utilize segmenting to split this into smaller chunks, in this case, 100 MB segments. To do this, we specify the size of the segments with the -s option, as follows: swift -V 2.0 -A http://172.16.0.1:5000/v2.0/ -U cookbook:demo -K openstack upload test -S 102400000 /tmp/example-1Gb You will see output similar to the following, showing the status of each upload: How it works... OpenStack Storage is very good at storing and retrieving large objects. To efficiently do this in our OpenStack Storage environment, we have the ability to split large objects into smaller objects with OpenStack Storage, maintaining this relationship between the segments and the objects that appear as a single file. This allows us to upload large objects in parallel, rather than stream a single large file. To achieve this, we use the following syntax: swift -V 2.0 -A http://keystone_server:5000/v2.0 -U tenant:user -K password upload container -S bytes large_file www.it-ebooks.info

Articles in this issue

Links on this page

Archives of this issue

view archives of After Deprec - openstack_cloud_computing_cookbook