Settings for rclone and plex?

Hi.

So i host a plex server for my family (Mother, Father, Sister and so on)

And for the longest time i have been using this

/usr/bin/rclone mount -v gdrive: /drive --allow-other --dir-cache-time 672h --vfs-cache-mode writes --vfs-cache-max-age 675h --vfs-read-chunk-size 32M --vfs-read-chunk-size-limit 1G --buffer-size 32M &

Some random thing i found on the internet.. But now that im redoing my plex server i was wondering if there is anything better?

I have been reading on Animosity´s github as he seems to know alot about rclone and plex..
I tried out some of his settings but it just made things worse

The big problem is that i dont really know what im looking at and looking for?

My problem before was that with the old rclone mount. Family would often have problems with movies just loading and loading and they had to jump in and out to get it to work.. and it just seemed sluggish..

I tried using the --dir-cache-time 1000h and --poll-interval 15s as from what i could figure out it would update faster.. But for some reason it just made it even worse..

And i tried --vfs-cache-max-size 500G and vfs-cache-mode full and made it cache to my servers harddrive..

And it did but it was still really slow..

And now im here asking for help because the more i read the more confused i get..

Im running a dedicated server from Hetzner

Specs:
Intel Xeon E3-1275V6
4x RAM 16384 MB DDR4 ECC
2x HDD SATA 6,0 TB Enterprise

I run everything on my server in containers cause it just seems so easy.. I have 3 mounts that i tried using in union but for some reason rclone would copy files to the wrong mount alot of the time.. So now i have 3 mounts

I wish i had encrypted it from the beginning as i cant encrypted now because that means starting over.. And im up about 100tb so far so starting over is not ideal..

But anyhelp or tips would be greatly appriceatet as my head is spinning..

What i would really like is the optimal rclone settings for my system and for rclone to automaticly mount on boot up..

I tried making a rclone.service but it didn work..

It's a bit all over the place without any real information.

The Help and Support template really is needed as it has all the right fields to fill in.

If you want to start on one thing and work on that, use the template and share all the information and we can help out.

My personal use case is pretty well written up as I don't use containers as they would over complicate my single server setup.

1 Like

What is the problem you are having with rclone?

"Slow load times, if i fast forward or rewind in a movie plex just keeps loading and i have to close to movie and open it back up again"

What is your rclone version (output from rclone version)

rclone v1.51.0

  • os/arch: linux/amd64
  • go version: go1.13.7

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

Ubuntu Server 18.04 64 bit

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

Google Drive

The command you were trying to run (eg rclone copy /tmp remote:tmp)

/usr/bin/rclone mount -v gdrive: /movies --allow-other --dir-cache-time 1000h --poll-interval 5s --cache-dir=/cache --vfs-cache-max-size 500G --vfs-cache-mode writes --vfs-cache-mode writes --vfs-cache-max-age 96h --vfs-read-chunk-size 16M --vfs-read-chunk-size-limit 50G &

The rclone config contents with secrets removed.


A log from the command with the -vv flag

[gdrive]
type = drive
scope = drive
token = {
root_folder_id = 

[gdrive1]
type = drive
scope = drive
token = {
root_folder_id = 

[gdrive3]
type = drive
scope = drive
token = {
root_folder_id = 

I did make a google api.. But i guess the rclone.conf get reset after a reboot

For any of the items mentioned on my page, you'd have to be on 1.53+ and just grab the latest as all the caching features would not work as they were changed.

No, they don't. You'd want to make sure the client ID and secret are in there as you'd be using the default rclone items and they are over burned. You need to reauthorize after you make those changes as well.

*Okay rclone is updatet and the id and secret are in the conf.. But i dont know how to reauthorize

I tried

rclone authorize --auth-no-open-browser

But didn do anything

That would throw an error if you typed it in:

felix@guardian:~$ rclone authorize --auth-no-open-browser
Usage:
  rclone authorize [flags]

Flags:
      --auth-no-open-browser   Do not automatically open auth link in default browser
  -h, --help                   help for authorize

Use "rclone [command] --help" for more information about a command.
Use "rclone help flags" for to see the global flags.
Use "rclone help backends" for a list of supported services.
Command authorize needs 1 arguments minimum: you provided 0 non flag arguments: []

You can do it two ways:

rclone authorize drive
rclone config reconnect remotename:

I get this error when i try

Failed to load config file "/root/.config/rclone/rclone.conf": could not parse line: client_id

How much of the client id should i use? All of it?

The client ID and secret should be the full value that was created on the Google API suite.

my id ends in .apps.googleusercontent.com

Is that right?

Think is fixed the id

now i get

"could not parse line: client_secret"

Got it to work :smiley:

Okay everything is up to date :wink:

Whats next.?

I'd probably look at the new vfs-cache-mode full and use that.

Change writes to full and retest and see how things work.

Well it feels the same.. Sluggish

But i wonder if its as good as it gets? I can fast forward and rewind.. But its sluggish

So far it looks like this

/usr/bin/rclone mount -v movies: /movies --allow-other --dir-cache-time 1000h --poll-interval 5s --cache-dir=/cache --vfs-cache-max-size 500G --vfs-cache-mode full --vfs-cache-mode writes --vfs-cache-max-age 96h --vfs-read-chunk-size 16M --vfs-read-chunk-size-limit 50G &

Haha i might see a problem :stuck_out_tongue: --vfs-cache-mode full --vfs-cache-mode writes "facepalm"

Kinda the same :slight_smile:

Only thing i can see that is diffrent is that plex uses more harddrive space and network..

But its so small a change..

What about

--vfs-read-chunk-size 16M

Any point in rasing it to 32-64? 512 maybe?

What i mostly thing about is..

That its cool my server takes a hit if it means that my family gets a better experince watching movies..

So anything that can help in that regard

Yes, that's why I suggested you read up on it as it's done a bit differently than previous versions. It won't use any more network as in the end if you play a 1GB file, it's getting a 1GB file. For Plex, it actually uses less network traffic and API hits as it's caching the file locally for a period of time.

Those are range requests for data and my thoughts are to remove anything you don't know why you have it and leave it at the defaults. If there is a reason to change something, change it, but know why you have it.

Well i would have to delete it all :stuck_out_tongue:

I dont really know what any of it does.. I might have and idea.. But thats it..

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