Running rclone through termux on android (<5.0)

Things you will need

- Android tablet/phone

- wifi connected

- install termux app (play store) version 0.74

- run few commands in order

- file manager app

- this guide assumes that user knows how to add rclone remotes. With basic remotes hbg: , gdrive:

- Daily total limit is 750gb per day. (Gdive limits)

#Step 1 This step is to install rclone in termux.

Open termux

##Run this command

pkg install rclone

Wait till it finishes the installation.

#To check if rclone is installed properly run

rclone version

Should show

rclone v1.49.1

- os/arch: android/arm64

- go version: go1.13

#Setup your remotes with rclone config Or SEE Step 2 Using rclone.conf from pc

rclone config

##Run rclone copy this copies from hbg:hbg/NSP Dumps to gdrive:hbgbackup/NSP Dumps Backup

rclone copy "hbg:hbg/NSP Dumps" "gdrive:hbgbackup/NSP Dumps Backup" -P --drive-server-side-across-configs

Wait till it hits transfered 750 GB quota limit per day.

exit the app

Enjoy now you can Run rclone through termux through android.

Step 2 Using rclone.conf from pc SKIP STEP 2 For not using your rclone.conf from pc

Get the rclone.conf from pc (C:\Users\[username]\.config\rclone\rclone.conf)

Copy to rclone.conf to your android device (via dropbox/gdrive/usb)

Make a new rclone folder /copy the rclone.conf in this folder

the location of rclone should look like this

(/storage/emulated/0/rclone/rclone.conf)

##Run

termux-setup-storage

Allow permission so termux can access storage.

This will create a $HOME/storage directory with symlinks to respective paths of sdcard(s).

# This bit is important as it letting rclone know the location of the file to run the rclone.conf file (copied from pc)

##Run

RCLONE_CONFIG=/data/data/com.termux/files/home/storage/shared/rclone/rclone.conf

export RCLONE_CONFIG

rclone config

It should list all the remotes of rclone.conf from pc.

Step 3 this part is for all the lazy people out there making a Script for this

Writting this in two ways one without rclone.conf copied from pc and one with rclone.conf

##intalling nano

pkg install nano

##creating script Nsp.sh

nano Nsp.sh

Copy the script from 3.A or 3.B

3.A. One without rclone.conf copied from pc

#!/bin/bash

#This nsp.sh is for rclone copy for hbgbackup.

echo "This nsp.sh is for rclone copy for hbgbackup."

echo "LOADING ......"

echo "Please wait..... running rclone copy from hbg NSP Dumps ....."

#Rclone copy Command

rclone copy "hbg:hbg/NSP Dumps" "gdrive:hbgbackup/NSP Dumps Backup" -P --drive-server-side-across-configs

echo #

#

echo ###

#

echo ########

#

echo "Copying Completed NSP Dump ......."

Pause

##save it exit

##making Nsp.sh to excuteable script

chmod +x Nsp.sh

##run the script Nsp.sh

./Nsp.sh

##The script Nsp.sh should run perfectly

END OF 3.A.

3.B One with rclone.conf copied from pc

#!/bin/bash

#This nsp.sh is for rclone copy for hbgbackup.

# RClone Config file THIS IS FOR RCLONE LOCATION (IF IT IS DIFFERENT )

RCLONE_CONFIG=/data/data/com.termux/files/home/storage/shared/rclone/rclone.conf

export RCLONE_CONFIG

echo "This nsp.sh is for rclone copy for hbgbackup."

echo "LOADING ......"

echo "Please wait..... running rclone copy from hbg NSP Dumps ....."

#Rclone copy Command

rclone copy "hbg:hbg/NSP Dumps" "gdrive:hbgbackup/NSP Dumps Backup" -P --drive-server-side-across-configs

echo #

echo ###

echo ########

echo "Copying Completed NSP Dump ......."

Pause

##save it exit

##making Nsp.sh to excuteable script

chmod +x Nsp.sh

##run the script Nsp.sh

./Nsp.sh