Jump to content

Movies Folder Directory in Multiple Libraries


Go to solution Solved by GrimReaper,

Recommended Posts

Trafford1240
Posted

Hi,

 

Wondering if anyone can answer this as an updated answer as I have looked through the forums and the answers seem to be from 2019 to 2021 so I don't know if it is possible now or not.

 

Basically I have a movies folder that I need to have linked to two libraries, what is the best way to do this without causing issues with EMBY. I dont need to have different perms setup set, just two libraries with the same settings pointing to the same root media folder.

 

Any help would be appreciated thank you 😀

 

 

Cheers

 

 

Chris

Posted

Hello Trafford1240,

** This is an auto reply **

Please wait for someone from staff support or our members to reply to you.

It's recommended to provide more info, as it explain in this thread:


Thank you.

Emby Team

  • Solution
GrimReaper
Posted
Just now, Trafford1240 said:

Basically I have a movies folder that I need to have linked to two libraries, what is the best way to do this without causing issues with EMBY. I dont need to have different perms setup set, just two libraries with the same settings pointing to the same root media folder.

STRM Files

Overlapping/nested folders are not supported nor recommended (though it can work if same content-type libraries and one being particular about structuring it), so it is generally advisable to avoid creating two/multiple libraries pointing to the same source/root folder. 

Trafford1240
Posted

Thank you,

 

Yeah having two seperate ones makes it harder as the storage is doubled, may have to have a look at using windows server deduplication to have two seperate folders but use one lot of storage.

 

Cheers

 

 

Chris

GrimReaper
Posted
8 minutes ago, Trafford1240 said:

as the storage is doubled

It is not, read Strm files link above. You just point those to your media files. 

  • Like 1
Trafford1240
Posted

Ah completely missed that bit. Just had a look and that will do exactly what i want.

 

Thank you

 

Will look at going through and setting the strm files.

 

Cheers

 

 

Chris

  • Thanks 1
Posted

Let us know how you get on. Thanks.

Trafford1240
Posted (edited)

Thank you all for the advice etc it has been really useful.

 

I have attached a windows powershell script that I tweaked after the help from ChatGPT. Anyone is free to use it if it helps them as its automated the process.

 

Basically in the script you input your source folder, and then destination folder (where I wanted a copy of my library). I have added the common video extensions but these can be expanded / changed. 

 

The script then does the following.

  • Scans the source folder for sub folders, then scans for media files.
  • Then script the script will replicate the folder structure in the new directory, it will then create an ".strm" with the movie name and then inputs the source path to the media. 
  • The script then copies all other files within the source folder such as NFO data, images etc.
  • The script also checks to see if the data in the source has already been copied and strm created etc and skips if it has, to save time re-creating items already there. Only downside is if you change a media image, this will not re-replicate to the copied destination.

 

I then rescanned my new library and everything loaded and played as normal.

 

As per any script you get from the internet, please test this on sample folders etc first before running on your live stream. 

The script was created and ran on Windows Server 2022 Datacenter

 

Hope this helps someone else as there is a alot of conflicting things over the STRM which I found confusing etc. This script really will help now as I have ran it as a scheduled task so that any new media in a source folder gets added to the copy folder. 

 

I have seen loads of comments saying why would you need copies etc, and people have there own setups with there own requirements. Without going into detail my set up was putting a family members DVD's into a library (he is keeping all the dvds etc just to make it easier to watch), so the library needs to be just his films and nothing else. I then want to have his films included in my films library which is when I seen that others said this can cause problems etc.

 

So happy to say all sorted and have it automated. So thank you for your responses and I hope this thread helps others down the line. Anyone is free to do what they like with the script, change it, modify etc. 

 

Cheers

 

 

Chris

EMBY_Clone_Library_to_STRM.zip

Edited by Trafford1240
Update regarding file skipping.
  • Like 2

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...