Guide: How To Use Rclone To Mount Cloud Drives And Play Files


DZMM

Recommended Posts

On 7/11/2020 at 11:05 PM, watchmeexplode5 said:

@Yeyo53

 

These are the settings I would recommend for starting out. Mostly default but adapted to work for your Plex mount. Keeping things default also makes initial setup and support easier!


Using gcrypt pointing to your gdrive


RcloneRemoteName="gcrypt"
RcloneMountShare="/mnt/user/mount_rclone"
LocalFilesShare="/mnt/user/local"
MergerfsMountShare="/mnt/user/mount_mergerfs"
DockerStart="transmission plex sonarr radarr"
MountFolders=\{"downloads/complete,downloads/intermediate,downloads/seeds,movies,tv"\}

# Add extra paths to mergerfs mount in addition to LocalFilesShare
LocalFilesShare2="/mnt/user/Plex/"

 

So your gdrive will be mounted at .../mount_rclone. 

Your local file at .../local (to be moved to gdrive on upload)

I added your mnt/user/Plex/ folder to the localfileshare2 setting for mergerfs to see.

 

The merged folder will be at .../mount_mergerfs

  • If you go to .../mount_mergerfs you will have all your paths combined so your gdrive, your ../local, and your /Plex files will all be there. 
  • When you write/move/copy things to .../mount_mergerfs it will be written to /mnt/user/local/
  • When you run the upload script. Anything in .../local folder will be uploaded to your gdrive.

 

So with this configuration you should point Plex/Sonarr/NZBGet to "/mnt/user/mount_mergerfs"

It will still see your media that's in your /Plex folder because it's added to localfileshare2.

 

This setup will keep your /Plex folder untouched while you make sure everything works well. If you want to move portions of your /Plex folder to your gdrive. Simply move files from /mnt/user/Plex to /mnt/user/local (or /mnt/user/mount_mergerfs). Then run the upload script. 

 

On 7/11/2020 at 10:42 PM, watchmeexplode5 said:

 

@Yeyo53

Do you plan on moving your local plex files to the cloud? Or keeping some files local and some in the cloud?

 

To start off, I wouldn't use the rclone cache system if you don't have to. In my tests, I haven't seen any performance gains from it compared to the scripts listed here. 

I recommend using just your a remote pointing to your gdrive and a crypt pointing to that gdrive.

 

 

Here is an explanation of the commands that I think you are struggling with:

 

RcloneMountShare="/mnt/user/mount_rclone" 

  • This is where your gdrive will be mounted on your server. So when you navigate to /mnt/user/mount_rclone you will see the content of your gdrive. In your case it sounds like your will see your two folders which are "media" and "movies" 

 

LocalFilesShare="/mnt/user/local"

  • This is where local media is placed to be uploaded to the gdrive when you run the upload script. This is where you will have a download folder, a movie folder, a tv folder, or any folder your want. 

MergerfsMountShare="ignore"

  • If your fill this in it will combine your local and gdrive to a single folder. So lets say you set it as /mnt/user/mount_mergerfs. 
  • These files do not actually exist at that location but simply appear like they are at this location. Here is a visual example to help  

/mnt/user/
      │
      ├── mount_rclone (Google Drive Mount)
      │      └── movies
      │            └──FILE ON GDRIVE.mkv
      │           
      ├── local
      │     └── movies
      │           └──FILE ON LOCAL.mkv
      │
      └── mount_mergerfs
            └── movies
                  ├──FILE ON GDRIVE.mkv
                  └──FILE ON LOCAL.mkv 

 

MountFolders=\{"downloads/complete,downloads/intermediate,downloads/seeds,movies,tv"\}

  • These are the folders created in your LocalFileShare location. The folders here will be uploaded to gdrive when the uploader script runs (except the download folder. The uploader ignores that folder). 
  • So typically it's best to leave them as the default value. You can always make your own files there if you want

 

Sorry guys! I have been busy this week.

 

I just accomplished it! The main problem was in my cache remote (I read it in a spanish forum that it was better for plex but I have try with only the crypt and it is working fine so...)

 

Anyway I would like to ask because I think I can optimize it a little bit but it is hard to explain:

At first Im pretty new to unraid so maybe I am doing things wrong.

 

- I have 1 user shared called Torrent that use disk 3 (cache: no) for downloads (first question: should I use an unassigned device for torrent downloads to avoid writing all the time in parity?)
- Then I have a user shared called Plex with 4 HDs (disks 1,2,5,6) where movies and tv shows are and where downloads are moved after complete (radar&sonarr do this). Cache is set to YES so I guess sonnar and radar move it to cache drive and then the mover move it sometime to the final destination. am I right?
- Then I have a user share Storage (disk 4) for nextcloud.

So:

- I have mounted 'mount_rclone' (AKA gdrive) in Storage (but there is no real info there, right? I mean no space is occupied?)
- I have mounted 'local' in Torrent/gdrivedownloads (which I think I did wrong because anyway my transmission is dowloading to Torrent/download but keep reading)

- I have mounted 'mount_mergefs' in Plex user shared.

So files are downloaded through sonarr&radarr to 1)Torrent/download/incomplete 2)Torrent/download/complete, then 3) they move it to 'Plex/mount_mergefs/gdrivemovies' (but phisicaly they are 'occuping space' in Storage/mount_rclone AKA disk 4.

 

Is it weird or it makes sense? What I want to avoid is 'spinning disks' for nothing and try to save some power and so because Plex is not used until night (but if I'm sharing a complete with transmission... which have been moved to Plex but it '''is''' stil at Torrent/Downloads... which disk is active??)

SORRY for the long post but my head is a mess right now! thanks in advance if you read it!!

Link to comment

@Yeyo53

 

Long post but I'll try to help.

 

Two questions so I know what your goal is and can try and get you a good setup:

  • Do you want all your files (movies/tv) in your "Plex" share to eventually be moved to your gdrive? Or are you going to keep some files local and some on the cloud?
  • Do you seed files for a LONG time or just to meet ratio/hit-and-run rules (like 7 days seed before you delete it from your torrent client)?

------------------------------------------

------------------------------------------

 

With regards to your other questions:

 

Should I use unassigned device for torrents

  • That's up to you. I would use unassigned device for seeds to avoid parity writes OR use your cache. But that of course would make those files unprotected (likely not an issue for torrents). Consider keeping the seeds on your cache drive if it's big enough and that will avoid excessive spin ups.

Cache set to YES on "Plex" 

  • Yes you are correct. With cache set to yes, anything written to the "Plex" share will be placed on your cache drive (if there is enough space). When unraid runs the mover script it will write them to the disks on your array.

mount_rclone mounted in storage

  • One question, what do you mean "Storage"?
  • The above config I posted should place the mount at /mnt/user/mount_rclone. If you go there it will be the contents of your gdrive. Free-space/used-space reported there will likely be wrong. Just know that it's your gdrive mount and don't worry about what space is being reported. 

Local in Torrent/gdrivedownloads

  • This should be your "local" content that is pending upload to gdrive. The upload script will move things in "local" to your gdrive. So it doesn't make to have that set as Torrent/gdrivedownloads in my opinion.
    • I would keep it /mnt/user/local. That works best with these scripts.
  • To stop excessive spin ups, use your cache drive (if it's ssd) for /mnt/user/local... or you could map it to your unassigned drive if you want. 
  • Your torrent client should be set to download to something like /mount_mergerfs/downloads/"whatever-you-want" (something like /torrents)
    • This setup will insure you can maintain hardlinks with torrent

Regarding mount_mergerfs

  • Your mount_mergerfs mount shouldn't be placed in your "Plex" share. The setup I gave you earlier combines your local, rclone, and Plex share into a single place for Sonarr/Radarr/Plex/torrents to use. That way any file located on local, rclone, or "Plex" folders will appear in the mount_mergerfs. So it doesn't matter if the file is local or on gdrive, your programs will always see it in the mergerfs folder. Think of it like shortcuts. The file isn't actually on your mergerfs share but it's "linked" to that so programs can't tell the difference. 

 

Docker Mapping --> Very important for Torrent Hardlinks!

  • You should be able to map all your docker programs to something like: (Host Path) /mnt/user/mount_mergerfs ---> (Docker Path) /mount_mergerfs 
    • Torrents will download to /mount_mergerfs/downloads/torrent_dl_folder 
    • Sonarr will find them and move it to /mount_mergerfs/tv
    • Plex will scan them and play them from /mount_mergerfs/tv

 

 

Before you go and move your entire Plex folder to gdrive

  • Test it by taking files from your "Plex/movie/Folder-File" share and move them to  "/mnt/user/local/Movie/Folder-File". Then run your upload script. If you look in your mergerfs share, nothing will have changed because it's all linked together, that's normal! When you look in your mount_rclone folder you will see your new Folder-Files (because they are now on gdrive).
Edited by watchmeexplode5
Link to comment
On 7/19/2020 at 10:08 PM, watchmeexplode5 said:

@Yeyo53

 

Long post but I'll try to help.

 

Two questions so I know what your goal is and can try and get you a good setup:

  • Do you want all your files (movies/tv) in your "Plex" share to eventually be moved to your gdrive? Or are you going to keep some files local and some on the cloud?
  • Do you seed files for a LONG time or just to meet ratio/hit-and-run rules (like 7 days seed before you delete it from your torrent client)?

------------------------------------------

------------------------------------------

 

With regards to your other questions:

 

Should I use unassigned device for torrents

  • That's up to you. I would use unassigned device for seeds to avoid parity writes OR use your cache. But that of course would make those files unprotected (likely not an issue for torrents). Consider keeping the seeds on your cache drive if it's big enough and that will avoid excessive spin ups.

Cache set to YES on "Plex" 

  • Yes you are correct. With cache set to yes, anything written to the "Plex" share will be placed on your cache drive (if there is enough space). When unraid runs the mover script it will write them to the disks on your array.

mount_rclone mounted in storage

  • One question, what do you mean "Storage"?
  • The above config I posted should place the mount at /mnt/user/mount_rclone. If you go there it will be the contents of your gdrive. Free-space/used-space reported there will likely be wrong. Just know that it's your gdrive mount and don't worry about what space is being reported. 

Local in Torrent/gdrivedownloads

  • This should be your "local" content that is pending upload to gdrive. The upload script will move things in "local" to your gdrive. So it doesn't make to have that set as Torrent/gdrivedownloads in my opinion.
    • I would keep it /mnt/user/local. That works best with these scripts.
  • To stop excessive spin ups, use your cache drive (if it's ssd) for /mnt/user/local... or you could map it to your unassigned drive if you want. 
  • Your torrent client should be set to download to something like /mount_mergerfs/downloads/"whatever-you-want" (something like /torrents)
    • This setup will insure you can maintain hardlinks with torrent

Regarding mount_mergerfs

  • Your mount_mergerfs mount shouldn't be placed in your "Plex" share. The setup I gave you earlier combines your local, rclone, and Plex share into a single place for Sonarr/Radarr/Plex/torrents to use. That way any file located on local, rclone, or "Plex" folders will appear in the mount_mergerfs. So it doesn't matter if the file is local or on gdrive, your programs will always see it in the mergerfs folder. Think of it like shortcuts. The file isn't actually on your mergerfs share but it's "linked" to that so programs can't tell the difference. 

 

Docker Mapping --> Very important for Torrent Hardlinks!

  • You should be able to map all your docker programs to something like: (Host Path) /mnt/user/mount_mergerfs ---> (Docker Path) /mount_mergerfs 
    • Torrents will download to /mount_mergerfs/downloads/torrent_dl_folder 
    • Sonarr will find them and move it to /mount_mergerfs/tv
    • Plex will scan them and play them from /mount_mergerfs/tv

 

 

Before you go and move your entire Plex folder to gdrive

  • Test it by taking files from your "Plex/movie/Folder-File" share and move them to  "/mnt/user/local/Movie/Folder-File". Then run your upload script. If you look in your mergerfs share, nothing will have changed because it's all linked together, that's normal! When you look in your mount_rclone folder you will see your new Folder-Files (because they are now on gdrive).

At first, thank you for answering. I gonna try to clarify some points:

1-Do you want all your files (movies/tv) in your "Plex" share to eventually be moved to your gdrive? Or are you going to keep some files local and some on the cloud? No. I'm having two different folders: one for 'special movies' I want to keep local in /mnt/user/Plex/movies and other with 'less special' movies in '/mnt/user/Plex/mount_mergefs'. Then I add these two folders in the same library in Plex so I see all the movies together.

2- Do you seed files for a LONG time or just to meet ratio/hit-and-run rules (like 7 days seed before you delete it from your torrent client)? Well, it depends, but could be a month or two.


3- That's up to you. I would use unassigned device for seeds to avoid parity writes OR use your cache. But that of course would make those files unprotected (likely not an issue for torrents). Consider keeping the seeds on your cache drive if it's big enough and that will avoid excessive spin ups.
I don't really care about protection in those files, and my cache drive is 1TB so it could handle. I like this idea more than the unassigned device, but IDK. The thing is that if radarr/sonarr are moving files just after the download completes from /mnt/user/Torrent/downloads (disk3) to /mnt/user/Plex/movies(disks 4,5,6,7) it means that files are being seeded for the Plex user share so those disks are being spinned all the time, right? Maybe I should look for an option to tell sonarr/radarr to DON'T move the files after 1month or something like that?

4- Regarding the gdrive folders: I put the mount_mergefs in /mnt/user/Plex/mount_mergefs because i have my local folder of movies in the same place (/mnt/user/Plex/movies) so mount_mergefs is the folder inside my plex user share where movies in gdrive are (both yet not uploaded and already uploaded). as you said this is only a shortcut to the other two folders. In this case when radar downloads a movie it moves it to '/mnt/user/Plex/mount_mergefs' which in reality is my local gdrive folder located in /mnt/user/Torrent/gdrivedownloads + the RcloneMountShare which is a link to my gdrive, right? but imagine that theres is no new downloads so all my files are in GDRIVE currently. Now I download a new file (/mnt/user/Torrent/downloads) so disk 3 is spinned up. Then in completes and radarr moves it to /mnt/user/Plex/mount_mergefs so one of the disks related to that user share (disks,4,5,6,7) are spinned up. but /mnt/user/Plex/mount_mergefs in reality is a link to /mnt/user/Torrent/gdrivedownloads so another time disk 3. And then file is uploaded to gdrive and now is ''''virtuallly?''' in /mnt/user/Storage/mount_rclone so disk 2 is spinned up?

I know, I know. I'm just making things complicated. I really like to keep things organized so for me it makes sense thats 'gdrive movies local&notlocal' (aka mergefs) are ''located'' in the Plex user share. And it also makes sense that my 'gdrive' remote (aka mount_rclone) is the Storage user share where my 'personal files' are (nextcloud).

Hope I have clarified something! thanks in advance!

Edited by Yeyo53
Link to comment

had this working flawlessly for months, but today for some reason if i start a docker that has  /user -> /mnt/user mapped, the gdrive files disappear from the mergerfs mount.

 

/mnt/user/gdrive/mount -  has all of my gdrive contents mounted properly

/mnt/user/gmedia/    - has all of my gdrive+local contents merged properly, but the gdrive folders are all empty starting docker

/mnt/user/gmedia/data    - my local data merged but still works when the gdrive folders/files disappear

/mnt/user/local/data -   all my local data (before its uploaded to gdrive)

 

dockers are mapped to /mnt/user -> /user , and then within each docker i navigate them to the relevant folders.

 

to get the mount properly working again, i have to fusermount -uz it and remove /bin/mergerfs, all tracking files, and then run the mount script again. then the cycle continues with docker breaking it.

 

mergerfs command:

mergerfs /mnt/user/local:/mnt/user/gdrive/mount /mnt/user/gmedia -o rw,async_read=false,use_ino,allow_other,func.getattr=newest,category.action=all,category.create=ff,cache.files=partial,dropcacheonclose=true

with rclone mount set to debug log level, it shows nothing bad, even when i start a docker to intentionally trigger the mount breaking.

 

i've tried:

docker new safe permissions

recreating docker.img

 

no luck so far

 

any ideas? @DZMM

Edited by remedy
Link to comment
2 hours ago, remedy said:

had this working flawlessly for months, but today for some reason if i start a docker that has  /user -> /mnt/user mapped, the gdrive files disappear from the mergerfs mount.

 

/mnt/user/gdrive/mount -  has all of my gdrive contents mounted properly

/mnt/user/gmedia/    - has all of my gdrive+local contents merged properly, but the gdrive folders are all empty starting docker

/mnt/user/gmedia/data    - my local data merged but still works when the gdrive folders/files disappear

/mnt/user/local/data -   all my local data (before its uploaded to gdrive)

 

dockers are mapped to /mnt/user -> /user , and then within each docker i navigate them to the relevant folders.

 

to get the mount properly working again, i have to fusermount -uz it and remove /bin/mergerfs, all tracking files, and then run the mount script again. then the cycle continues with docker breaking it.

 

mergerfs command:


mergerfs /mnt/user/local:/mnt/user/gdrive/mount /mnt/user/gmedia -o rw,async_read=false,use_ino,allow_other,func.getattr=newest,category.action=all,category.create=ff,cache.files=partial,dropcacheonclose=true

with rclone mount set to debug log level, it shows nothing bad, even when i start a docker to intentionally trigger the mount breaking.

 

i've tried:

docker new safe permissions

recreating docker.img

 

no luck so far

 

any ideas? @DZMM

Why did you delete the logs from your post? It's hard to help you without logs.  Luckily, the logs are in the email alert I got.  If you look at the logs it says, error mergerfs mountpoint not empty.  Look at the mergerfs file location and delete or move whatever files are there and then run the script again.

Link to comment
9 hours ago, DZMM said:

Why did you delete the logs from your post? It's hard to help you without logs.  Luckily, the logs are in the email alert I got.  If you look at the logs it says, error mergerfs mountpoint not empty.  Look at the mergerfs file location and delete or move whatever files are there and then run the script again.

i thought it said that because i left a manually created mountcheck file in gmedia. but i deleted everything and ran it again, it ran fine, then again when i launched the docker the files disappear and it shows just the empty directories the script creates.

 

 Script location: /tmp/user.scripts/tmpScripts/rclone_mount_plugin/script
Note that closing this window will abort the execution of this script
26.07.2020 12:26:36 INFO: Creating local folders.
26.07.2020 12:26:36 INFO: *** Starting mount of remote gdrive_vfs
26.07.2020 12:26:36 INFO: Checking if this script is already running.
26.07.2020 12:26:36 INFO: Script not running - proceeding.
26.07.2020 12:26:36 INFO: *** Checking if online
26.07.2020 12:26:37 PASSED: *** Internet online
26.07.2020 12:26:37 INFO: Mount not running. Will now mount gdrive_vfs remote.
26.07.2020 12:26:37 INFO: Recreating mountcheck file for gdrive_vfs remote.
2020/07/26 12:26:37 DEBUG : rclone: Version "v1.52.2-250-g4f9a80e2-beta" starting with parameters ["rcloneorig" "--config" "/boot/config/plugins/rclone-beta/.rclone.conf" "copy" "mountcheck" "gdrive_vfs:" "-vv" "--no-traverse"]
2020/07/26 12:26:37 DEBUG : Using config file from "/boot/config/plugins/rclone-beta/.rclone.conf"
2020/07/26 12:26:37 DEBUG : fs cache: adding new entry for parent of "mountcheck", "/"
2020/07/26 12:26:38 DEBUG : mountcheck: Need to transfer - File not found at Destination
2020/07/26 12:26:39 INFO : mountcheck: Copied (new)
2020/07/26 12:26:39 INFO :
Transferred: 32 / 32 Bytes, 100%, 26 Bytes/s, ETA 0s
Transferred: 1 / 1, 100%
Elapsed time: 1.1s

2020/07/26 12:26:39 DEBUG : 10 go routines active
26.07.2020 12:26:39 INFO: *** Creating mount for remote gdrive_vfs
26.07.2020 12:26:39 INFO: sleeping for 5 seconds
26.07.2020 12:26:44 INFO: continuing...
26.07.2020 12:26:44 INFO: Successful mount of gdrive_vfs mount.
26.07.2020 12:26:44 INFO: Mergerfs not installed - installing now.
fetch http://dl-cdn.alpinelinux.org/alpine/v3.10/main/x86_64/APKINDEX.tar.gz
fetch http://dl-cdn.alpinelinux.org/alpine/v3.10/community/x86_64/APKINDEX.tar.gz
v3.10.5-60-gf7c8b9a88d [http://dl-cdn.alpinelinux.org/alpine/v3.10/main]
v3.10.5-58-g477aae6b2f [http://dl-cdn.alpinelinux.org/alpine/v3.10/community]
OK: 10348 distinct packages available
(1/6) Installing ca-certificates (20191127-r2)
(2/6) Installing nghttp2-libs (1.39.2-r1)
(3/6) Installing libcurl (7.66.0-r0)
(4/6) Installing expat (2.2.8-r0)
(5/6) Installing pcre2 (10.33-r0)
(6/6) Installing git (2.22.4-r0)
Executing busybox-1.30.1-r2.trigger
Executing ca-certificates-20191127-r2.trigger
OK: 21 MiB in 20 packages
Cloning into 'mergerfs'...
2.29.0
Note: checking out '2.29.0'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:

git checkout -b

HEAD is now at 10e8bd9 Merge pull request #716 from trapexit/mount
(1/49) Installing fakeroot (1.23-r0)
(2/49) Installing sudo (1.8.27-r2)
(3/49) Installing libcap (2.27-r0)
(4/49) Installing pax-utils (1.2.3-r0)
(5/49) Installing openssl (1.1.1g-r0)
(6/49) Installing libattr (2.4.48-r0)
(7/49) Installing attr (2.4.48-r0)
(8/49) Installing tar (1.32-r0)
(9/49) Installing pkgconf (1.6.1-r1)
(10/49) Installing patch (2.7.6-r6)
(11/49) Installing libgcc (8.3.0-r0)
(12/49) Installing libstdc++ (8.3.0-r0)
(13/49) Installing lzip (1.21-r0)
(14/49) Installing curl (7.66.0-r0)
(15/49) Installing abuild (3.4.0-r0)
Executing abuild-3.4.0-r0.pre-install
(16/49) Installing m4 (1.4.18-r1)
(17/49) Installing libbz2 (1.0.6-r7)
(18/49) Installing perl (5.28.3-r0)
(19/49) Installing autoconf (2.69-r2)
(20/49) Installing automake (1.16.1-r0)
(21/49) Installing binutils (2.32-r0)
(22/49) Installing gmp (6.1.2-r1)
(23/49) Installing isl (0.18-r0)
(24/49) Installing libgomp (8.3.0-r0)
(25/49) Installing libatomic (8.3.0-r0)
(26/49) Installing mpfr3 (3.1.5-r1)
(27/49) Installing mpc1 (1.1.0-r0)
(28/49) Installing gcc (8.3.0-r0)
(29/49) Installing musl-dev (1.1.22-r3)
(30/49) Installing libc-dev (0.7.1-r0)
(31/49) Installing g++ (8.3.0-r0)
(32/49) Installing gettext-asprintf (0.19.8.1-r4)
(33/49) Installing libintl (0.19.8.1-r4)
(34/49) Installing libunistring (0.9.10-r0)
(35/49) Installing gettext-libs (0.19.8.1-r4)
(36/49) Installing ncurses-terminfo-base (6.1_p20190518-r2)
(37/49) Installing ncurses-libs (6.1_p20190518-r2)
(38/49) Installing libxml2 (2.9.9-r3)
(39/49) Installing gettext (0.19.8.1-r4)
(40/49) Installing gettext-dev (0.19.8.1-r4)
(41/49) Installing perl-error (0.17027-r0)
(42/49) Installing perl-git (2.22.4-r0)
(43/49) Installing git-perl (2.22.4-r0)
(44/49) Installing readline (8.0.0-r0)
(45/49) Installing bash (5.0.0-r0)
Executing bash-5.0.0-r0.post-install
(46/49) Installing libltdl (2.4.6-r6)
(47/49) Installing libtool (2.4.6-r6)
(48/49) Installing linux-headers (4.19.36-r0)
(49/49) Installing make (4.2.1-r2)
Executing busybox-1.30.1-r2.trigger
OK: 237 MiB in 69 packages
make -C libfuse
make[1]: Entering directory '/tmp/mergerfs/libfuse'
mkdir -p build
touch build/stamp
ecfd/build | tee build/config.h
#ifndef CONFIG_H_INCLUDED
#define CONFIG_H_INCLUDED

#define HAVE_FORK
#define HAVE_SPLICE
#define HAVE_STRUCT_STAT_ST_ATIM
#define HAVE_UTIMENSAT
#define HAVE_VMSPLICE

#endif
make build/buffer.o build/cuse_lowlevel.o build/fuse.o build/fuse_kern_chan.o build/fuse_loop.o build/fuse_loop_mt.o build/fuse_lowlevel.o build/fuse_mt.o build/fuse_opt.o build/fuse_session.o build/fuse_signals.o build/helper.o build/mount.o
make[2]: Entering directory '/tmp/mergerfs/libfuse'
cc -O2 -Wall -pipe -MMD -Iinclude -Ibuild -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DPACKAGE_VERSION=\"2.9.7-mergerfs_2.29.0\" -DFUSERMOUNT_DIR=\"/usr/local/bin\" -c lib/buffer.c -o build/buffer.o
cc -O2 -Wall -pipe -MMD -Iinclude -Ibuild -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DPACKAGE_VERSION=\"2.9.7-mergerfs_2.29.0\" -DFUSERMOUNT_DIR=\"/usr/local/bin\" -c lib/cuse_lowlevel.c -o build/cuse_lowlevel.o
lib/cuse_lowlevel.c: In function 'cuse_lowlevel_new':
lib/cuse_lowlevel.c:170:12: warning: assignment to 'void (*)(struct fuse_req *, fuse_ino_t, int, void *, struct fuse_file_info *, unsigned int, const void *, uint32_t, uint32_t)' {aka 'void (*)(struct fuse_req *, long unsigned int, int, void *, struct fuse_file_info *, unsigned int, const void *, unsigned int, unsigned int)'} from incompatible pointer type 'void (*)(struct fuse_req *, fuse_ino_t, int, void *, struct fuse_file_info *, unsigned int, const void *, size_t, size_t)' {aka 'void (*)(struct fuse_req *, long unsigned int, int, void *, struct fuse_file_info *, unsigned int, const void *, long unsigned int, long unsigned int)'} [-Wincompatible-pointer-types]
lop.ioctl = clop->ioctl ? cuse_fll_ioctl : NULL;
^
cc -O2 -Wall -pipe -MMD -Iinclude -Ibuild -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DPACKAGE_VERSION=\"2.9.7-mergerfs_2.29.0\" -DFUSERMOUNT_DIR=\"/usr/local/bin\" -c lib/fuse.c -o build/fuse.o
lib/fuse.c: In function 'fuse_compat_open':
lib/fuse.c:1402:10: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
err = ((struct fuse_operations_compat22 *) &fs->op)->open(path,
~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
lib/fuse.c:1407:10: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
err = ((struct fuse_operations_compat2 *) &fs->op)
~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
lib/fuse.c: In function 'fuse_compat_release':
lib/fuse.c:1418:11: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
return ((struct fuse_operations_compat2 *) &fs->op)
~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
lib/fuse.c: In function 'fuse_compat_opendir':
lib/fuse.c:1431:10: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
err = ((struct fuse_operations_compat22 *) &fs->op)
~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
lib/fuse.c: In function 'fuse_compat_statfs':
lib/fuse.c:1471:10: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
err = ((struct fuse_operations_compat22 *) &fs->op)
~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
lib/fuse.c:1478:10: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
err = ((struct fuse_operations_compat1 *) &fs->op)
~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
lib/fuse.c: In function 'add_name':
lib/fuse.c:831:2: warning: 'strncpy' output truncated before terminating nul copying as many bytes from a string as its length [-Wstringop-truncation]
strncpy(s, name, len);
^~~~~~~~~~~~~~~~~~~~~
lib/fuse.c:807:15: note: length computed here
size_t len = strlen(name);
^~~~~~~~~~~~
cc -O2 -Wall -pipe -MMD -Iinclude -Ibuild -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DPACKAGE_VERSION=\"2.9.7-mergerfs_2.29.0\" -DFUSERMOUNT_DIR=\"/usr/local/bin\" -c lib/fuse_kern_chan.c -o build/fuse_kern_chan.o
cc -O2 -Wall -pipe -MMD -Iinclude -Ibuild -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DPACKAGE_VERSION=\"2.9.7-mergerfs_2.29.0\" -DFUSERMOUNT_DIR=\"/usr/local/bin\" -c lib/fuse_loop.c -o build/fuse_loop.o
cc -O2 -Wall -pipe -MMD -Iinclude -Ibuild -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DPACKAGE_VERSION=\"2.9.7-mergerfs_2.29.0\" -DFUSERMOUNT_DIR=\"/usr/local/bin\" -c lib/fuse_loop_mt.c -o build/fuse_loop_mt.o
cc -O2 -Wall -pipe -MMD -Iinclude -Ibuild -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DPACKAGE_VERSION=\"2.9.7-mergerfs_2.29.0\" -DFUSERMOUNT_DIR=\"/usr/local/bin\" -c lib/fuse_lowlevel.c -o build/fuse_lowlevel.o
lib/fuse_lowlevel.c: In function 'fuse_add_dirent':
lib/fuse_lowlevel.c:271:2: warning: 'strncpy' output truncated before terminating nul copying as many bytes from a string as its length [-Wstringop-truncation]
strncpy(dirent->name, name, namelen);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
lib/fuse_lowlevel.c:261:21: note: length computed here
unsigned namelen = strlen(name);
^~~~~~~~~~~~
cc -O2 -Wall -pipe -MMD -Iinclude -Ibuild -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DPACKAGE_VERSION=\"2.9.7-mergerfs_2.29.0\" -DFUSERMOUNT_DIR=\"/usr/local/bin\" -c lib/fuse_mt.c -o build/fuse_mt.o
cc -O2 -Wall -pipe -MMD -Iinclude -Ibuild -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DPACKAGE_VERSION=\"2.9.7-mergerfs_2.29.0\" -DFUSERMOUNT_DIR=\"/usr/local/bin\" -c lib/fuse_opt.c -o build/fuse_opt.o
cc -O2 -Wall -pipe -MMD -Iinclude -Ibuild -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DPACKAGE_VERSION=\"2.9.7-mergerfs_2.29.0\" -DFUSERMOUNT_DIR=\"/usr/local/bin\" -c lib/fuse_session.c -o build/fuse_session.o
lib/fuse_session.c: In function 'fuse_chan_recv':
lib/fuse_session.c:211:11: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
return ((struct fuse_chan_ops_compat24 *) &ch->op)
~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc -O2 -Wall -pipe -MMD -Iinclude -Ibuild -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DPACKAGE_VERSION=\"2.9.7-mergerfs_2.29.0\" -DFUSERMOUNT_DIR=\"/usr/local/bin\" -c lib/fuse_signals.c -o build/fuse_signals.o
cc -O2 -Wall -pipe -MMD -Iinclude -Ibuild -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DPACKAGE_VERSION=\"2.9.7-mergerfs_2.29.0\" -DFUSERMOUNT_DIR=\"/usr/local/bin\" -c lib/helper.c -o build/helper.o
cc -O2 -Wall -pipe -MMD -Iinclude -Ibuild -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DPACKAGE_VERSION=\"2.9.7-mergerfs_2.29.0\" -DFUSERMOUNT_DIR=\"/usr/local/bin\" -c lib/mount.c -o build/mount.o
In file included from lib/mount_generic.c:23,
from lib/mount.c:22:
/usr/include/sys/poll.h:1:2: warning: #warning redirecting incorrect #include to [-Wcpp]
#warning redirecting incorrect #include to
^~~~~~~
make[2]: Leaving directory '/tmp/mergerfs/libfuse'
ar rcs build/libfuse.a build/buffer.o build/cuse_lowlevel.o build/fuse.o build/fuse_kern_chan.o build/fuse_loop.o build/fuse_loop_mt.o build/fuse_lowlevel.o build/fuse_mt.o build/fuse_opt.o build/fuse_session.o build/fuse_signals.o build/helper.o build/mount.o
cc -O2 -Wall -pipe -MMD -Iinclude -Ibuild -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DPACKAGE_VERSION=\"2.9.7-mergerfs_2.29.0\" -DFUSERMOUNT_DIR=\"/usr/local/bin\" -o build/mount.mergerfs util/mount.mergerfs.c build/libfuse.a -lrt -pthread
cc -O2 -Wall -pipe -MMD -Iinclude -Ibuild -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DPACKAGE_VERSION=\"2.9.7-mergerfs_2.29.0\" -DFUSERMOUNT_DIR=\"/usr/local/bin\" -Ilib -o build/mergerfs-fusermount util/fusermount.c lib/mount_util.c
make[1]: Leaving directory '/tmp/mergerfs/libfuse'
tools/update-version
grep: src/version.hpp: No such file or directory
mkdir -p build
touch build/stamp
make[1]: Entering directory '/tmp/mergerfs'
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_listxattr.cpp -o build/fuse_listxattr.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/policy_lus.cpp -o build/policy_lus.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_init.cpp -o build/fuse_init.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_read.cpp -o build/fuse_read.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_destroy.cpp -o build/fuse_destroy.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_copydata_readwrite.cpp -o build/fs_copydata_readwrite.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_readlink.cpp -o build/fuse_readlink.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/policy_lfs.cpp -o build/policy_lfs.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/gidcache.cpp -o build/gidcache.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_getattr.cpp -o build/fuse_getattr.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_getxattr.cpp -o build/fuse_getxattr.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_truncate.cpp -o build/fuse_truncate.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/category.cpp -o build/category.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/policy_rand.cpp -o build/policy_rand.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_fchmod.cpp -o build/fuse_fchmod.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/policy_erofs.cpp -o build/policy_erofs.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_copy_file_range.cpp -o build/fuse_copy_file_range.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_chmod.cpp -o build/fuse_chmod.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_mktemp.cpp -o build/fs_mktemp.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_mknod.cpp -o build/fuse_mknod.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_opendir.cpp -o build/fuse_opendir.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_symlink.cpp -o build/fuse_symlink.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/policy_mfs.cpp -o build/policy_mfs.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_statvfs_cache.cpp -o build/fs_statvfs_cache.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_sendfile.cpp -o build/fs_sendfile.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_unlink.cpp -o build/fuse_unlink.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_ficlone.cpp -o build/fs_ficlone.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/policy_epmfs.cpp -o build/policy_epmfs.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/config.cpp -o build/config.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/policy_all.cpp -o build/policy_all.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_movefile.cpp -o build/fs_movefile.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/num.cpp -o build/num.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_removexattr.cpp -o build/fuse_removexattr.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_copy_file_range.cpp -o build/fs_copy_file_range.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_statfs.cpp -o build/fuse_statfs.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/policy_invalid.cpp -o build/policy_invalid.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_base_fadvise.cpp -o build/fs_base_fadvise.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_fallocate.cpp -o build/fuse_fallocate.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_write_buf.cpp -o build/fuse_write_buf.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_base_fallocate.cpp -o build/fs_base_fallocate.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/resources.cpp -o build/resources.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_release.cpp -o build/fuse_release.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fusefunc.cpp -o build/fusefunc.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/policy_eplfs.cpp -o build/policy_eplfs.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_chown.cpp -o build/fuse_chown.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_fchown.cpp -o build/fuse_fchown.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/policy_ff.cpp -o build/policy_ff.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/mergerfs.cpp -o build/mergerfs.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_read_buf.cpp -o build/fuse_read_buf.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_base_futimesat.cpp -o build/fs_base_futimesat.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_flush.cpp -o build/fuse_flush.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_glob.cpp -o build/fs_glob.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/policy_epall.cpp -o build/policy_epall.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_ioctl.cpp -o build/fuse_ioctl.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/branch.cpp -o build/branch.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_path.cpp -o build/fs_path.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_setxattr.cpp -o build/fuse_setxattr.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/policy_cache.cpp -o build/policy_cache.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/policy_newest.cpp -o build/policy_newest.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_futimens.cpp -o build/fuse_futimens.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_xattr.cpp -o build/fs_xattr.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_clonefile.cpp -o build/fs_clonefile.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_info.cpp -o build/fs_info.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/policy_eplus.cpp -o build/policy_eplus.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_rmdir.cpp -o build/fuse_rmdir.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_fgetattr.cpp -o build/fuse_fgetattr.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_cow.cpp -o build/fs_cow.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_access.cpp -o build/fuse_access.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/option_parser.cpp -o build/option_parser.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_link.cpp -o build/fuse_link.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_copydata_copy_file_range.cpp -o build/fs_copydata_copy_file_range.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_fsyncdir.cpp -o build/fuse_fsyncdir.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_flock.cpp -o build/fuse_flock.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_create.cpp -o build/fuse_create.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_acl.cpp -o build/fs_acl.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_rename.cpp -o build/fuse_rename.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_prepare_hide.cpp -o build/fuse_prepare_hide.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_utimens.cpp -o build/fuse_utimens.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/policy_epff.cpp -o build/policy_epff.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_attr.cpp -o build/fs_attr.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/ugid.cpp -o build/ugid.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/policy_eprand.cpp -o build/policy_eprand.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs_clonepath.cpp -o build/fs_clonepath.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_mkdir.cpp -o build/fuse_mkdir.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_releasedir.cpp -o build/fuse_releasedir.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_fsync.cpp -o build/fuse_fsync.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_ftruncate.cpp -o build/fuse_ftruncate.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fs.cpp -o build/fs.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/str.cpp -o build/str.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_write.cpp -o build/fuse_write.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_open.cpp -o build/fuse_open.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fasthash.cpp -o build/fasthash.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_readdir.cpp -o build/fuse_readdir.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/fuse_free_hide.cpp -o build/fuse_free_hide.o
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 -c src/policy.cpp -o build/policy.o
make[1]: Leaving directory '/tmp/mergerfs'
g++ -O2 -static -Wall -Wno-unused-result -MMD -Ilibfuse/include -D_FILE_OFFSET_BITS=64 -DFUSE_USE_VERSION=29 -DUSE_XATTR=1 -DUGID_USE_RWLOCK=0 build/fuse_listxattr.o build/policy_lus.o build/fuse_init.o build/fuse_read.o build/fuse_destroy.o build/fs_copydata_readwrite.o build/fuse_readlink.o build/policy_lfs.o build/gidcache.o build/fuse_getattr.o build/fuse_getxattr.o build/fuse_truncate.o build/category.o build/policy_rand.o build/fuse_fchmod.o build/policy_erofs.o build/fuse_copy_file_range.o build/fuse_chmod.o build/fs_mktemp.o build/fuse_mknod.o build/fuse_opendir.o build/fuse_symlink.o build/policy_mfs.o build/fs_statvfs_cache.o build/fs_sendfile.o build/fuse_unlink.o build/fs_ficlone.o build/policy_epmfs.o build/config.o build/policy_all.o build/fs_movefile.o build/num.o build/fuse_removexattr.o build/fs_copy_file_range.o build/fuse_statfs.o build/policy_invalid.o build/fs_base_fadvise.o build/fuse_fallocate.o build/fuse_write_buf.o build/fs_base_fallocate.o build/resouild/policy.o -o build/mergerfs libfuse/build/libfuse.a -pthread -lrt
mergerfs version: 2.29.0
FUSE library version: 2.9.7-mergerfs_2.29.0
using FUSE kernel interface version 7.31
'build/mergerfs' -> '/build/mergerfs'
26.07.2020 12:27:17 INFO: *sleeping for 5 seconds
26.07.2020 12:27:22 INFO: Mergerfs installed successfully, proceeding to create mergerfs mount.
26.07.2020 12:27:22 INFO: Creating gdrive_vfs mergerfs mount.
26.07.2020 12:27:22 INFO: Checking if gdrive_vfs mergerfs mount created.
26.07.2020 12:27:22 INFO: Check successful, gdrive_vfs mergerfs mount created.
26.07.2020 12:27:22 INFO: Starting dockers.
26.07.2020 12:27:22 INFO: Script complete

 

 

what the folder structure looks like before i run a docker and after:

 

root@unRAID:/mnt/user/gmedia# ls
Movies/  TV/  data/  id_rsa  id_rsa.pub  mountcheck  watch/
root@unRAID:/mnt/user/gmedia# ls
Movies/  TV/  data/  watch/

 

and what happens if i run the script again after starting the docker:

 

 Script location: /tmp/user.scripts/tmpScripts/rclone_mount_plugin/script
Note that closing this window will abort the execution of this script
26.07.2020 12:34:02 INFO: Creating local folders.
26.07.2020 12:34:02 INFO: *** Starting mount of remote gdrive_vfs
26.07.2020 12:34:02 INFO: Checking if this script is already running.
26.07.2020 12:34:02 INFO: Script not running - proceeding.
26.07.2020 12:34:02 INFO: *** Checking if online
26.07.2020 12:34:03 PASSED: *** Internet online
26.07.2020 12:34:03 INFO: Mount not running. Will now mount gdrive_vfs remote.
26.07.2020 12:34:03 INFO: Recreating mountcheck file for gdrive_vfs remote.
2020/07/26 12:34:03 DEBUG : rclone: Version "v1.52.2-250-g4f9a80e2-beta" starting with parameters ["rcloneorig" "--config" "/boot/config/plugins/rclone-beta/.rclone.conf" "copy" "mountcheck" "gdrive_vfs:" "-vv" "--no-traverse"]
2020/07/26 12:34:03 DEBUG : Using config file from "/boot/config/plugins/rclone-beta/.rclone.conf"
2020/07/26 12:34:03 DEBUG : fs cache: adding new entry for parent of "mountcheck", "/"
2020/07/26 12:34:04 DEBUG : mountcheck: Modification times differ by -7m26.662403559s: 2020-07-26 12:34:03.845403559 -0400 EDT, 2020-07-26 16:26:37.183 +0000 UTC
2020/07/26 12:34:05 INFO : mountcheck: Copied (replaced existing)
2020/07/26 12:34:05 INFO :
Transferred: 32 / 32 Bytes, 100%, 35 Bytes/s, ETA 0s
Transferred: 1 / 1, 100%
Elapsed time: 0.8s

2020/07/26 12:34:05 DEBUG : 11 go routines active
26.07.2020 12:34:05 INFO: *** Creating mount for remote gdrive_vfs
26.07.2020 12:34:05 INFO: sleeping for 5 seconds
26.07.2020 12:34:10 INFO: continuing...
26.07.2020 12:34:10 INFO: Successful mount of gdrive_vfs mount.
26.07.2020 12:34:10 INFO: Mergerfs already installed, proceeding to create mergerfs mount
26.07.2020 12:34:10 INFO: Creating gdrive_vfs mergerfs mount.
fuse: mountpoint is not empty
fuse: if you are sure this is safe, use the 'nonempty' mount option
26.07.2020 12:34:10 INFO: Checking if gdrive_vfs mergerfs mount created.
26.07.2020 12:34:10 CRITICAL: gdrive_vfs mergerfs mount failed. Stopping dockers.
plex
sonarr
radarr
requestrr
deluge

 

Edited by remedy
Link to comment
1 hour ago, remedy said:

26.07.2020 12:34:10 INFO: Creating gdrive_vfs mergerfs mount. fuse: mountpoint is not empty

Something is in the folder that is stopping mergerfs creating a mount

 

1 hour ago, remedy said:

and what happens if i run the script again after starting the docker:

Whatever docker you are using is creating a file(s) in the mount location - don't start dockers that add files to the mount outside the script!

Link to comment
16 minutes ago, DZMM said:

Something is in the folder that is stopping mergerfs creating a mount

 

Whatever docker you are using is creating a file(s) in the mount location - don't start dockers that add files to the mount outside the script!

wow, that was it. i was pulling my hair out.

 

so if starting the dockers outside the script breaks it, do i also have to stop the mount before updating the dockers?

Edited by remedy
Link to comment
13 minutes ago, remedy said:

so if starting the dockers outside the script breaks it, do i also have to stop the mount before updating the dockers?

 

No - just make sure that the mount is running before starting dockers - in the docker settings set any docker that could add files to the mount, or go haywire if the mount files aren't available (e.g. plex) to not auto start.

Link to comment

Up until yesterday, I hadn't rebooted my server for 28 days and it was fine. After I rebooted, my mount script wouldn't load properly and after running an ls -l, I noticed that the two mount folders (mount_mergerfs & mount_rclone) were changed to root:root. 

 

I deleted the folders and re-imported all of the scripts; as well as changed all my docker mounts to user --> /mnt/user. The mount folders were re-created using the script with the nobody:users permissions. 

 

A few hours later, I noticed that media wasn't playing again, so I checked the permissions and they went back to root:root. I have checked my settings in Sonarr and Radarr, and the write permissions are turned off. Any other ideas what could be changing these permissions? 

Link to comment

Can anyone recommend a good, cheap dedicated server provider?  I'm probably going to be moving home again and it's looking like I'll only get 110 upload at best, which will make running my Plex server on my machine very hard unless I do a lot of transcoding. 

 

I've looked at Hetzner's auctions, but most of their boxes are SSD only and I need a HDD to hold torrents that are seeding.

Link to comment
On 7/31/2020 at 11:17 AM, DZMM said:

Can anyone recommend a good, cheap dedicated server provider?  I'm probably going to be moving home again and it's looking like I'll only get 110 upload at best, which will make running my Plex server on my machine very hard unless I do a lot of transcoding. 

 

I've looked at Hetzner's auctions, but most of their boxes are SSD only and I need a HDD to hold torrents that are seeding.

You can look at hetzner and their server auction, they have some pretty good server for around 30-40€ depending of your location ofcause. And they have servers with HDDs.

Edited by Thel1988
Link to comment
12 minutes ago, Thel1988 said:

You can look at hetzner and their server auction, they have some pretty good server for around 30-40€ depending of your location ofcause. And they have servers with HDDs.

Thanks I'll look again as I couldn't see any with HDDs and SSDs, just one or the other.  I'm worried browsing will be slow from a HDD - but I guess you can't have it all.

Link to comment
Just now, DZMM said:

Thanks I'll look again as I couldn't see any with HDDs and SSDs, just one or the other.  I'm worried browsing will be slow from a HDD - but I guess you can't have it all.

Maybe you can seperate the 2 use cases? Get a hertzner server for your Plex and a seedbox for your torrents?

Link to comment

So I have done the full install, and unraid mounts the gdrive, but I can't see anything in it via plex, or anywhere in unraid. UNLESS I use a terminal in which case I can see the files listed there from the unraid instance.  But any docker container cannot see it.  Any help would be greatly appreciated. --Allow-other is in the script (provided from the github), and any areas where my naming scheme is required are there. Let me know if any logs would be helpful.
TIA!

Link to comment
On 4/10/2020 at 9:58 PM, DZMM said:

I'd move everything to the team drive - as @testdasi said as soon as you start understanding what you can do with this setup, you'll want a teamdrive.  To move:

 

- stop all mounts, dockers etc

- create a team drive and note the ID - it'll be in the url

- add your google account as a user of the teamdrive if needed

- within google drive move all the files from the gdrive folder to the teamdrive folder - ensure all the paths are the same i.e. gdrive/crypt/sub-folder -->tdrive/crypt/sub-folder.  This should be pretty quick for 1TB

- change your rclone config via the plugin settings page (easiest) to:

 


[tdrive]
type = drive
scope = drive
service_account_file = /mnt/user/appdata/other/rclone/service_accounts/sa_tdrive.json
team_drive = Team DRIVE ID
server_side_across_configs = true

 

 

I am a long time user, i am still running the original scripts with unionFS, never had a issue and still running. I do however also have all my data located in gdrive. So i have decide to make the switch to mergerFS at the same time as relocating and setting up some "shared drives" for each library utilizing the extra service accounts.

 

1. When editing the rclone config, do i set multiple sections like so for each share;

Quote

[gdrive]
type = drive
client_id = ****
client_secret = ****
scope = drive
token = ****
root_folder_id = ****

 

[gdrive_media_vfs]
type = crypt
remote = gdrive:crypt
filename_encryption = standard
directory_name_encryption = true
password = ****
password2 = ****

 

[tdrive1]
type = drive
scope = drive
service_account_file = /mnt/user/appdata/other/rclone/service_accounts/sa_tdrive.json
team_drive = Team DRIVE ID
server_side_across_configs = true

 

[tdrive_media_vfs]
type = crypt
remote = tdrive1:crypt
filename_encryption = standard
directory_name_encryption = true
password = ****
password2 = ****

 

[tdrive2]
type = drive
scope = drive
service_account_file = /mnt/user/appdata/other/rclone/service_accounts/sa_tdrive.json
team_drive = Team DRIVE ID
server_side_across_configs = true

 

[tdrive_media_vfs]
type = crypt
remote = tdrive2:crypt
filename_encryption = standard
directory_name_encryption = true
password = ****
password2 = ****

 

 

2. I then need to edit the mount script to suit, i take it i will need to create Multiple mounts with one merger and upload script? Referring to another previous post I found.

Quote

1. My folder structure looks something like this:

 

mount_mergerfs/tdrive_vfs/movies

mount_mergerfs/tdrive_vfs/music

mount_mergerfs/tdrive_vfs/uhd

mount_mergerfs/tdrive_vfs/tv_adults

mount_mergerfs/tdrive_vfs/tv_kids

 

2. I created separate tdrives  / rclone mounts for some of the bigger folders e.g.

 

mount_rclone/tdrive_vfs/movies

mount_rclone/tdrive_vfs/music

mount_rclone/tdrive_vfs/uhd

mount_rclone/tdrive_vfs/adults_tv

                                        

for each of those I created a mount script instance where I do NOT create a mergerfs mount

 

3. I mount each in turn and for the final main mount add the extra tdrive rclone mounts as extra mergerfs folders:

 

############################################################### ###################### mount tdrive ######################### ############################################################### # REQUIRED SETTINGS RcloneRemoteName="tdrive_vfs" RcloneMountShare="/mnt/user/mount_rclone" LocalFilesShare="/mnt/user/local" MergerfsMountShare="/mnt/user/mount_mergerfs" # OPTIONAL SETTINGS # Add extra paths to mergerfs mount in addition to LocalFilesShare LocalFilesShare2="/mnt/user/mount_rclone/music" LocalFilesShare3="/mnt/user/mount_rclone/uhd" LocalFilesShare4="/mnt/user/mount_rclone/adults_tv"

 

4. Run the single upload script - everything initially gets moved from /mnt/user/local/tdrive_vfs to the tdrive_vfs teamdrive

 

5. Overnight I run another script to move files from the folders that are in tdrive_vfs: to the correct teamdrive.  You have to work out the encrypted folder names for this to work.  Because rclone is moving the files, the mergerfs mount gets updated i.e. it looks to plex etc like they haven't moved

 

 

 

"

for each of those I created a mount script instance where I do NOT create a mergerfs mount

"

So i would duplicate and edit the below section in the mount script for each of my shares that i want mounted.

# create rclone mount
	rclone mount \
	--allow-other \
	--buffer-size 256M \
	--dir-cache-time 720h \
	--drive-chunk-size 512M \
	--log-level INFO \
	--vfs-read-chunk-size 128M \
	--vfs-read-chunk-size-limit off \
	--vfs-cache-mode writes \
	--bind=$RCloneMountIP \
	$tdrive_media_vfs: /mnt/user/mount_rclone/google_vfs &

# Check if Mount Successful
	echo "$(date "+%d.%m.%Y %T") INFO: sleeping for 5 seconds"
# slight pause to give mount time to finalise
	sleep 5
	echo "$(date "+%d.%m.%Y %T") INFO: continuing..."
	if [[ -f "$RcloneMountLocation/mountcheck" ]]; then
		echo "$(date "+%d.%m.%Y %T") INFO: Successful mount of ${RcloneRemoteName} mount."
	else
		echo "$(date "+%d.%m.%Y %T") CRITICAL: ${RcloneRemoteName} mount failed - please check for problems.  Stopping dockers"
		docker stop $DockerStart
		rm /mnt/user/appdata/other/rclone/remotes/$RcloneRemoteName/mount_running
		exit
	fi
fi

 

I am also not following steps 4 & 5. Why run a second upload script in step 5 to move files from the same folders you did in step 4...

 

 

regards

Edited by KeyBoardDabbler
Link to comment

I think I followed the guide pretty well, and I am receiving the following error in the Upload Script:

 

rclone not installed - will try again later.

 

Here is portion of the script that I am using:

 

#!/bin/bash

######################
### Upload Script ####
######################
### Version 0.95.5 ###
######################

####### EDIT ONLY THESE SETTINGS #######

# INSTRUCTIONS
# 1. Edit the settings below to match your setup
# 2. NOTE: enter RcloneRemoteName WITHOUT ':'
# 3. Optional: Add additional commands or filters
# 4. Optional: Use bind mount settings for potential traffic shaping/monitoring
# 5. Optional: Use service accounts in your upload remote
# 6. Optional: Use backup directory for rclone sync jobs

# REQUIRED SETTINGS
RcloneCommand="move" # choose your rclone command e.g. move, copy, sync
RcloneRemoteName="gdrive_media_vfs" # Name of rclone remote mount WITHOUT ':'.
RcloneUploadRemoteName="gdrive_upload_vfs" # If you have a second remote created for uploads put it here.  Otherwise use the same remote as RcloneRemoteName.
LocalFilesShare="/mnt/user/Plex-Media" # location of the local files without trailing slash you want to rclone to use
RcloneMountShare="/mnt/user/mount_Plex-Media" # where your rclone mount is located without trailing slash  e.g. /mnt/user/mount_rclone
MinimumAge="15m" # sync files suffix ms|s|m|h|d|w|M|y
ModSort="ascending" # "ascending" oldest files first, "descending" newest files first

# Note: Again - remember to NOT use ':' in your remote name above

# Bandwidth limits: specify the desired bandwidth in kBytes/s, or use a suffix b|k|M|G. Or 'off' or '0' for unlimited.  The script uses --drive-stop-on-upload-limit which stops the script if the 750GB/day limit is achieved, so you no longer have to slow 'trickle' your files all day if you don't want to e.g. could just do an unlimited job overnight.
BWLimit1Time="01:00"
BWLimit1="off"
BWLimit2Time="08:00"
BWLimit2="15M"
BWLimit3Time="16:00"
BWLimit3="12M"

# OPTIONAL SETTINGS

# Add name to upload job
JobName="_daily_upload" # Adds custom string to end of checker file.  Useful if you're running multiple jobs against the same remote.

# Add extra commands or filters
Command1="--exclude downloads/**"
Command2=""
Command3=""
Command4=""
Command5=""
Command6=""
Command7=""
Command8=""

# Bind the mount to an IP address
CreateBindMount="N" # Y/N. Choose whether or not to bind traffic to a network adapter.
RCloneMountIP="10.0.0.62" # Choose IP to bind upload to.
NetworkAdapter="eth0" # choose your network adapter. eth0 recommended.
VirtualIPNumber="1" # creates eth0:x e.g. eth0:1.

# Use Service Accounts.  Instructions: https://github.com/xyou365/AutoRclone
UseServiceAccountUpload="N" # Y/N. Choose whether to use Service Accounts.
ServiceAccountDirectory="/mnt/user/appdata/other/rclone/service_accounts" # Path to your Service Account's .json files.
ServiceAccountFile="sa_gdrive_upload" # Enter characters before counter in your json files e.g. for sa_gdrive_upload1.json -->sa_gdrive_upload100.json, enter "sa_gdrive_upload".
CountServiceAccounts="15" # Integer number of service accounts to use.

# Is this a backup job
BackupJob="N" # Y/N. Syncs or Copies files from LocalFilesLocation to BackupRemoteLocation, rather than moving from LocalFilesLocation/RcloneRemoteName
BackupRemoteLocation="backup" # choose location on mount for deleted sync files
BackupRemoteDeletedLocation="backup_deleted" # choose location on mount for deleted sync files
BackupRetention="90d" # How long to keep deleted sync files suffix ms|s|m|h|d|w|M|y

####### END SETTINGS #######
 

This is my first time setting something like this up, any help would be appreciated.

Edited by Emilio5639
Added the script I am using.
Link to comment
On 8/2/2020 at 2:55 AM, Millerboy3 said:

So I have done the full install, and unraid mounts the gdrive, but I can't see anything in it via plex, or anywhere in unraid. UNLESS I use a terminal in which case I can see the files listed there from the unraid instance.  But any docker container cannot see it.  Any help would be greatly appreciated. --Allow-other is in the script (provided from the github), and any areas where my naming scheme is required are there. Let me know if any logs would be helpful.
TIA!

When you say any docker, do you mean Krusader?  Best practice is to start dockers after mounting.

Edited by DZMM
Link to comment
On 8/3/2020 at 12:43 AM, KeyBoardDabbler said:

I am also not following steps 4 & 5. Why run a second upload script in step 5 to move files from the same folders you did in step 4...

All looks good.  The reason I do a tdrive-->tdrive transfer as an extra step, is because I only have one mergerfs mount that combines all my tdrives and local files.  The upload script for the associated local folder uploads all the files to a single tdrive, so behind the scenes I move the files to their correct tdrive. 

 

You could run an upload script for each tdrive, but for my setup that be a pain to traffic manage and the tdrive-->tdrive transfers are mega fast as they are done server side.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.