Upload Directorys to block storage using linode-cli

Hey!

Are you able to upload directorys to linode block storage using linode-cli, or it is a limitation?

If it is a limitation, is there an alternative?

1 Reply

The Linode-CLI commands for Block Storage seem to be limited to simple interactions with the service itself (i.e. creating/deleting volumes, attaching, mounting/unmounting, and resizing). As far as I am aware, although the both the CLI and Block Storage API allow for mount path specifications, neither option allow you to create directories or manipulate data.

In order to do that, you would need to mount your Volume, SSH (Secure Shell) or LISH (Linode Shell) Console into the corresponding Linode, and perform the filesystem/data work from within the Linode itself.

In order to transfer files to your Linode/Block Storage Volume, you would want to use either the scp command or make use of a service like FileZilla or WinSCP:

Since the Volume is mounted to your Linode's filesystem, your data copying/moving commands would be directed at the respective Volume pathing. For example, if Block Storage Volume test_volume-01 is mounted at /dev/test_volume-01, you could copy a directory/folder from your local system using the command syntax:

scp -r $PATH/OF/SOURCE/DIRECTORY $USER@$IP_ADDRESS:/dev/test_volume-01/$DESTINATION/DIRECTORY

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct