Grounded in the Cloud
HP Helion brings together all the speed, agility and cost benefits of cloud computing, and with all the possibilities and interoperability of open source. Providing the cloud practitioner in you, the flexibility, reliability and security that enterprises need to move forward with confidence.

In this blog, we will explore the unique challenges and solutions of enterprise cloud deployment and usage. And in so doing, help you on your way to design, build and manage enterprise-grade infrastructure, platform and application services for the Cloud. Come join us now on this journey….

Migrating your files with the Windows CLI

Not all of us have had the pleasure of using HP Cloud Object Storage yet. Some customers may keep their data on other storage systems like Amazon S3, Dropbox, or even Microsoft Skydrive. This can present a problem when migrating over to HP Cloud Object Storage. After all, we have better things to do with our time than copy our files one by one from system to the system. To address this problem we've created a new Powershell cmdlet available within the Windows CLI that I’d like to share with you called Migrate-drive. This cmdlet specializes in moving data from S3 Buckets , Skydrive and Dropbox to a set of our Object Storage Containers. First off, let’s look at a full S3 conversion in action. Suppose that we had TLPRoot and TLPTest2 Buckets in S3 and the TLPTest2 Bucket contained MikeConfig.txt and NewHelp.text files.

Now let’s move these files over to HP Cloud Object Storage.



Your first argument is the Provider name. Valid entries are S3, Skydrive and Dropbox. The –ak stands for AccessKey and –sk stands for Secret Key. These parameters are only required if S3 is the Provider (more on this later). Now let’s check our results.



In the example above we’ve copied every S3 Bucket found for the supplied credentials into a set of corresponding Containers. After we issue the get-psdrive command you can see that a new set of Containers exist, one for each migrated Bucket. To mount just issue


Cd yourContainer:


You should also notice that any folder structures that you’ve created within S3 have been preserved during the copy operation. Now let’s introduce a bit more precision by moving only the Buckets that we’re interested in. In this case the TLPRoot bucket.



The –b argument takes a set of comma delimited bucket names (each in quotes) and copies only those specified over to Object Storage.


Finally let’s look at a few other providers that we can move data from. Here’s an example of moving our SkyDrive based data.



In this example you’ll notice that the only required parameter is the Provider name. The reason no credentials are required for non-S3 stores is because these operations rely on the fact that you’ve installed the Skydrive or Dropbox clients. These clients keep your local machine in sync with the store and we’re simply doing a complete recursive copy from your local machine, to HP Cloud Object Storage. One side effect of this approach is the need to place the folders found in a root container named after the Provider. You can see this by observing the SkyDrive Container present in the get-psdrive output above.


We hope this cmdlet simplifies migrating or backing up your files from other storage providers. If you have ideas or questions please feel free to send feedback to the Developer Experience team.  We look forward to hearing from you.

Labels: HP cloud
Leave a Comment

We encourage you to share your comments on this post. Comments are moderated and will be reviewed
and posted as promptly as possible during regular business hours

To ensure your comment is published, be sure to follow the Community Guidelines.

Be sure to enter a unique name. You can't reuse a name that's already in use.
Be sure to enter a unique email address. You can't reuse an email address that's already in use.
Type the characters you see in the picture above.Type the words you hear.
Showing results for 
Search instead for 
Do you mean 
About the Author
Stephen Spector is a HP Cloud Evangelist promoting the OpenStack based clouds at HP for hybrid, public, and private clouds . He was previous...

Follow Us
The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation.