Use Rclone to manage your data on Z1 Storage

enter image description here rclone is a command-line program to manage files on cloud storage, compatible with Windows and Linux.


Install rclone (Linux)

On most Linux distributions, you can install rclone via terminal with command:

sudo apt-get install rclone

rclone install command

After installation you can check if rclone has been installed by typing the command:

rclone version

You should get output similar to this:

rclone check version


Install rclone (Windows)
  • First of all, download rclone for Windows from HERE.
  • After the download is completed, extract rclone to a working directory. In this guide we will extract it in C:/rclone

rclone directory should contain rclone.exe file and look similar to this:

rclone windows directory


Run and configure rclone

rclone is a command-line tool, you need to use command prompt (Windows) or terminal (Linux)


**For Windows Users only
**

Open the directory where you extracted rlone and in address bar type cmd and press **Enter.
**This will open the command-line tool in directory you're in.

open cmd from folder


Once you have terminal or command-line tool ready, type the command:

rclone config

rclone config

rclone now will ask you to configure remote

Type n to add new remote configuration and press Enter

rclone new config

rclone configurator will ask you for a remote name.
You can type in anything you like.
For demonstration purposes we will call it z1storage

remote name

Next step will ask for a Type of storage to configure, choose Amazon S3 Compliant Storage.
In our case, it was option 4.

storage configuration type

Next step will ask you to choose your S3 provider, type in number next to the CEPH option and **press Enter.
**In our case, it was 3.

s3 provider

Now rclone will ask you type of authentication, you will need access key and secret key.
Keys can be retrieved from your account by navigating HERE.

(Keep your keys safe and do not share them with others)

In rclone select Enter AWS credentials in the next step.
In our case we typed 1

authentication

The Configuration process will ask you for your access key.
Type in your Z1 Storage access key and press Enter.

access key entry

Then rclone config will ask for your secret access key.
Type in your Z1 Storage secret key and press Enter.

secret key entry

On the next step you need to choose empty region and V4 signatures and press Enter.
In our case it was option 1.

region selection

Now rclone setup will ask for Endpoint of S3 API.
Type in s3.z1storage.com

endpoint input

On the next step leave input blank for location constraint and press Enter.

location constraint

Now you will have to choose ACL you want to use. You can read more about it in HERE.
In our case we selected Owner gets FULL_CONTROL, option 1. This means only you can access and control the data.

ACL setup

On this step you can select the encryption type you would like to use for your stored data on Z1 Storage,
For this rclone tutorial, we chose no encryption, and proceeded to press Enter for the default option.

encryption setting

Last step does not need to be configured, press Enter to skip.

KMD ID

rclone setup will ask you if you want to Edit advanced config?, type in n and press Enter.

advanced configuration

Review your Remote Config, if everything is correct; type in y and press Enter.

remote config confirmation

Exit rclone configuration by typing q and pressing Enter.

quit configurator


Use rclone to access your Z1 Storage data

After you have completed configuration, you can now use rclone to access your buckets and manage data.

rclone offers many commands. You can check a list of theme HERE.

As an example lets try to list contents of our bucket

In terminal or command-line type in:

rclone ls :

- is configuration name you entered in rclone config - is bucket name you try to access

Example:

rclone ls z1storage:z1testbucket

list bucket contents

You should get the output with a list of files in a bucket

rclone output


Mount Z1 Storage Bucket as a directory

rclone commands allow you to do various operations, but sometimes you might need more flexibility when it comes to accessing and working with your cloud storage.

Here we will mount your Z1 Storage S3 bucket as a mount point within the OS: You can access buckets on your OS like any other directory and use native OS commands to interact with files.


Linux

To mount a Z1 Storage bucket on linux use command:

rclone mount : </mnt/mountdir>

example

rclone mount z1storage:z1testbucket /mnt/clouddrive


Windows

**Mouting S3 buckets and Z1 Storage Buckets in Windows using WinFsp and rclone

WinFsp is a FUSE alternative for Windows, this is required to get rclone to mount your Z1 Storage buckets in Windows.
**

To mount a Z1 Storage bucket on Windows using rclone we need to first install WinFsp.
WinFsp is a open-source tool to mount virtual directories.
You can download it HERE.

1) WinFsp Installation
  • Open the installation file you downloaded.
  • When the installer opens **press next
    **

winfsp installation

  • Now choose where to install WinFsp
  • Press Next

winfsp installation

  • Press Next

winfsp installation

  • Press Finish to finalise the install.

winfsp installation

2) Mount your Z1 Storage bucket in Windows

Once WinFsp is installed you can now mount your Z1 Storage bucket in Windows using rclone

Mounting bucket to directory in Windows is similar to Linux, only directory definition changes.

rclone mount :

example

rclone mount z1storage:z1testbucket C:clouddirectory

mount bucket to directory

rclone should show that service has been started

rclone service working

Now you can navigate to defined virtual directory and view the mounted bucket files

mounted directory in windows

Congratulations! You have successfully configured rclone to work with Z1 Storage.