Ascp Examples |
Examples of using the ascp command to initiate fasp transfers to cloud storage.
If you have access to cloud storage that is hosted by Aspera On Demand, you can use ascp to transfer to it.
With Docroot Already Configured
If your transfer server account already has a docroot set up, ascp transfers to S3 storage, Google storage, Akamai, Softlayer, and Azure are the same as regular ascp transfers:
ascp options myfile username@server:/targetpath
For examples, see Ascp General Examples.
In some cases, ascp transfers to cloud storage can be made without a preconfigured docroot. See the examples below.
With No Docroot Configured: S3
If the transfer server account does not have a docroot, you can still transfer to S3 as long as you know your S3 Access ID and Secret Key and you have an S3 bucket. The syntax is:
ascp options --mode=send --user=username --host=s3_server_addr files_to_send \ s3://access_id:secret_key@s3.amazonaws.com/s3_bucket
For example:
ascp --mode=send --user=bob --host=s3.asperasoft.com myfiles \ s3://1K3C18FBWF9902:GEyU1BTwCFeUtLR3CcAqXuxtTVHWtc@s3.amazonaws.com/demos2014
With No Docroot Configured: Softlayer
If the transfer server account does not have a docroot, you can still transfer with the following syntax:
ascp options --mode=send --user=root --host=ip_addr files_to_send \ swift://softlayer_username:api_key@location.objectstorage.service.networklayer.com/container
Example Upload:
ascp --mode=send --user=root --host=192.155.218.130 bigfile.txt \ swift://XYZOS303446-2:bob:437e29...bcf616@sjc01.objectstorage.service.networklayer.com/test
Example Download:
ascp --mode=recv --user=root --host=192.155.218.130 \ swift://XYZOS303446-2:bob:437e29...bcf616@sjc01.objectstorage.service.networklayer.com/test/bigfile.txt /tmp/
With No Docroot Configured: Azure
If the transfer server account does not have a docroot, you can still transfer. First set an Aspera environment variable with the password:
Windows Command Prompt: set ASPERA_SCP_PASS = password
Linux: export ASPERA_SCP_PASS=password
Then run ascp with the following syntax:
ascp options --mode=send --user=username --host=server files_to_send azu://storage:key@blob.core.windows.net/abc
For example:
Windows Command Prompt: set ASPERA_SCP_PASS = fslk47CLwlj
Linux: export ASPERA_SCP_PASS=fslk47CLwlj
ascp --mode=send --user=AS037d8eda429737d6 --host=dev920350144d2.azure.asperaondemand.com bigfile.txt \ azu://astransfer:zNfMtU...nBTkhB@blob.core.windows.net/abc