Adding a second Teamdrive

You need to go through the usual method of creating a mount in Rclone See Here

Then what you need to do is add the second drive to PGunion
Mount the second tdrive on

mkdir -p /mnt/tdrive2
sudo chown -cR 1000:1000 /mnt/tdrive2
cd /etc/systemd/system
cp tdrive.service tdrive2.service
sudo nano tdrive2.service

Change the folder to /mnt/tdrive2

From

ExecStart=/usr/bin/rclone mount tdrive: /mnt/tdrive \

To

ExecStart=/usr/bin/rclone mount tdrive2: /mnt/tdrive2 \

From:

ExecStop=/bin/fusermount -uz /mnt/tdrive > /dev/null

To:

ExecStop=/bin/fusermount -uz /mnt/tdrive2 > /dev/null

Change the log file to rclone-tdrvie2.log

from

--log-file=/var/plexguide/logs/drive/rclone-tdrive.log \

to

--log-file=/var/plexguide/logs/drive/rclone-tdrive2.log \

Change the rclone.conf file location

Save

cd /opt/appdata/plexguide 
nano pgunion.sh

Add this after /mnt/tdrive=NC:

/mnt/tdrive2=NC: 

Save the file (ctrl + x, y)

Next we need to stop PGunion

Then you need to restart all the arrs and plex
(copy the command and paste it only in the terminal)

cat <<EOF >> /home/restart.sh 

sudo service pgunion stop
sudo systemctl daemon-reload

sudo fusermount -uzq /mnt/unionfs

container=$(docker ps -aq --format '{{.Names}}' | sed '/^$/d' | grep -E 'ple|arr|emby|jelly') 

for i in ${container}; do
     docker stop $i >> /dev/null
done

sudo service tdrive2 start
sudo service pgunion start

container=$(docker ps -aq --format '{{.Names}}' | sed '/^$/d' | grep -E 'ple|arr|emby|jelly') 

for i in ${container}; do
     docker start $i >> /dev/null
done

EOF
sudo  bash /home/restart.sh

You should now have your second drive mounted correctly.

2 Likes

Or if you want it within the normal area and less work, do this

I understand the second part, of editing the tdrive2 location. I don’t get the first, with Rclone. I set this up last year wtih PGBlitz 8.7.5 . Is there no way to use PGBlitz to add a second encrypted TeamDrive?

No sorry, PG was never designed for multiple drives.

Thank you. I think I did it correctly, but how do I test to know for sure?

Here’s where I’m at;
Followed Rclone for Google Team Drive
Edited the files from your guide
I can create files in tdrive2 but I’m not seeing it on Gdrive.

You shouldn’t see it in gdrive. You should see in unionfs

1 Like

Rclone sees the drive I named ‘seconddrive’.
image

I can prove a not owner of the drive can see the folders and files.

I have saved the service file in the correct folder.
image

I have edited as per the guide.


I have rebooted with an edited version of your restart.sh
image

I still don’t see ‘seconddrive’ in unionfs.

The only thing I can think of is how I can only get the mount to show up when I run Rclone as root but not as the user. What am I doing wrong?

Please add to guide, after ExecStart;

Change the folder to STOP to /mnt/tdrive2

From:
ExecStop=/bin/fusermount -uz /mnt/tdrive > /dev/null
To:
ExecStop=/bin/fusermount -uz /mnt/tdrive2 > /dev/null

1 Like

is the multi tdrive setup going to be an option on the sudobox lite beta? i had it using pgx and about to rebuild on a server closer to home.

would rather wait on the cli beta than changing setup. but i do miss my other drives :slight_smile:

I was able to add a second teamdrive, just curious if anyone knows how to use service accounts on the second team drive.