How to use Rclone behind a proxy in terminal?

In order to get a high speed to transfer to GDrive, I wanna use a proxy to improve my speed.

I have 2 ways to do so.

First plan: I could do some settings in my router, and all connections go to Google will keep behind a proxy server. This way I've already tried and it works. But not that convenient for me.

Second plan: I could set up the environment varibles for a terminal session.
I use this

export http_proxy=""
export https_proxy=""

and I have also tried

export http_proxy="socks5://"
export https_proxy="socks5://"

But these do not work for me. After set up the environment varibles, I do this:

systemctl start rclone.service

to mount my GDrive, and then I use rclone copy to my GDrive.
But the speed never changed compared with first plan, which the speed is extremely high.

Is there any way to use proxy in a terminal session?

I think you are asking if you want to run a system service using a proxy as you mention terminal but are starting with a systemd service file.

If the service file is you want you want, you can add something like:

cat /tmp/test.environment

and in your systemd service file have the enivornment line:

ExecStart=/usr/bin/rclone mount blah blah
1 Like

It works! Thanks a lot!!!

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