Change SFTP remote source (from the default home dir)

What is the problem you are having with rclone?

SFTP remote mounts the user's home directory. I'd like to specify which directory to mount. If logging in with my_user, it uses /home/my_user/, but I'd like to use /zfspool/ instead.

What is your rclone version (output from rclone version)

1.55.0

Which OS you are using and how many bits (eg Windows 7, 64 bit)

mac and linux

Which cloud storage system are you using? (eg Google Drive)

SFTP

The rclone config contents with secrets removed.

[media03]
type = sftp
host = 192.168.x.xx
user = my_user
port = 22
pass = 
use_insecure_cipher = false

I want to say this is possible with an alias remote, but I can't remember how.

Just make an alias remote and call it whatever you want and point it to:

media03:/zfspool
2 Likes

Thanks @Animosity022. I knew it was something so simple, just couldn't figure it out.

@ncw Do you think the docs can be amended for sftp to include the use of an alias to mount specific remote directories with the sftp remote?

1 Like

Perhaps a sentence after this

Paths are specified as remote:path . If the path does not begin with a / it is relative to the home directory of the user. An empty path remote: refers to the user's home directory.

Do you want to add one @jiru? You can edit the SFTP docs online (click the pencil icon).

1 Like

I will add some edits and a couple practical examples!

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.