I just started to use rclone recently together with google drive, and mount it to plex.
When I start streaming something either thought plex or doing a “rclone copy” to the server, it takes 40-50 seconds, before it starts the download. When it has received the first byte/chunk, it downloads at full speed (~130 MB/s), so doesn’t seem to be the speed that is a problem. Hopefully someone knows what could might be the issue
rclone.conf
[gdrive]
type = drive
scope = drive
token = ******
[gcrypt]
type = crypt
remote = gdrive:Private
filename_encryption = standard
directory_name_encryption = true
password = ******
I’m playing / copying directly from the mount position (/home/plex/gdrive)
It seems that it took about 40 seconds before it got the docs.googleusercontent.com link, but still took about 20-30 seconds after that to start the download, so not sure if it’s rate limited related or not.
Is why it is taking so long as you get those repeating.
I wouldn’t use this either:
--drive-v2-download-min-size
That’s a copy command as well and not a play from Plex so not sure if it is the same thing or not. If you can play something and share that log, it would be helpful.
Not sure where to get and use an API key for rclone and google drive.
I have removed --drive-v2-download-min-size from the copy command. Read another thread about that it could result in some kind of lock, because of it, so have been removed since.
And here is a debug log from the mount with a play from plex. Still seem to be some issue with playing, as it took around 60 sec to start. https://pastebin.com/raw/EcSAKhm8
Have created a client id and secret and added to my gdrive config now. Still seems to give Rate Limit Exceeded. Not sure if I should wait a few hours before I can see the impact?
Debug log: https://pastebin.com/raw/11v7UVCc
I used rclone config to edit “existing remote remote”, and added the client_id (clientid.apps.googleusercontent.com) and client_secret (secret). I removed scope = drive. Not sure what it does, so it looks like your config.
I use a Google Drive Business account, with a domain for it. (1 user)
[gdrive]
type = drive
token = {"access_token":"access_token","token_type":"Bearer","refresh_token":"refresh_token","expiry":"2019-01-14T14:00:20.052604978+01:00"}
client_id = clientid.apps.googleusercontent.com
client_secret = secret
[gcrypt]
type = crypt
remote = gdrive:Private
filename_encryption = standard
directory_name_encryption = true
password = ******
I resat the client_secret in the API console and re-entered the client_id and client_secret and update the token in the config. I can see some information on the API console now, and there was no previous information, so it didn’t use the API as you suspected. Have not received a Rate Limit Exceeded yet. Also tried to start a stream, and it starts in 10 sec without a Rate Limit Exceeded, so seems like it has helped.
10 seconds is a bit longer than I’d expect but that does depend on if you are transcoding or direct streaming or a few other things like your bandwidth and such.
I usually start in 2-3 seconds at most but I am direct streaming or direct playing and I have a gigabit link.
The server is on a gigabit connection, but Google API v3 is slow compared to v2 (Hence why I tested with --drive-v2-download-min-size earlier). I just tested with direct streaming, and takes about 15 sec to start the streaming in plex. There is no rate limit exceeded in the debug log, so that has been fixed.
Another issue is that it shows the correct playtime, before the stream has started playing, but after that it says the playtime is 2 hours, no matter how long the episode is.
With the mount the V3 is just as fast as it does chunked reading. There is some data that shows the V2 was leading to bans but nothing confirmed so I personally would not recommend using it.
Start times could be peering or files not being analyzed. Would need to see the rclone logs and Plex logs when you hit play to confirm.
Times changing are usually due to analysis as well.