Jump to content


Photo

Emby Server - Full Symbolic Support

symlink feature request

  • Please log in to reply
4 replies to this topic

#1 immortal OFFLINE  

immortal

    Newbie

  • Members
  • 4 posts
  • Local time: 06:11 AM

Posted 15 June 2015 - 02:11 PM

Full symbolic link support would be a great addition to the emby project. At the moment they are not followed.

 

Why would you want symbolic links?

 

1. This allows users to optimize their library by renaming the symbolic link to a more suitable file name where the original file needs to remain the same.

 

2. Allows users to have a single destination specified within a library, reduces clutter and makes file browsing easier.



#2 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 126753 posts
  • Local time: 01:11 AM

Posted 15 June 2015 - 02:27 PM

Well we actually get this from the native file system. In windows, I believe they are followed. On linux, OSX, etc, we get this from Mono and it's possible that it hasn't fully implemented it yet.



#3 AncientGeek OFFLINE  

AncientGeek

    Newbie

  • Members
  • 1 posts
  • Local time: 06:11 AM

Posted 16 June 2015 - 11:33 AM

Perhaps this will help?

http://stackoverflow...d-pipes-in-mono

(First ever reply, so please kindly inform me if I didn't do it correctly.)



#4 hjone72 OFFLINE  

hjone72

    Advanced Member

  • Members
  • 31 posts
  • Local time: 05:11 AM

Posted 08 July 2015 - 05:44 AM

I am using Windows and use Folder Junctions instead of Symbolic Links and they work perfectly.

 

I find that Junctions work better as they are also followed by network clients. For example; \\tower\TV Shows\Game of Thrones - is shared via a TV Show folder that is made purely by Junctions that are scattered over a number of different hard drives.



#5 somechap OFFLINE  

somechap

    Newbie

  • Members
  • 5 posts
  • Local time: 06:11 AM

Posted 10 August 2015 - 11:37 AM

A note for future readers, because I originally wept copiously when reading this thread :-)

My video collection consists entirely of symlinks.  I rip VOB files straight off my DVDs and symlink them with names like ShowName_S01E01.mpg into a neat folder structure.  XBMC/Kodi reads this fine, but Emby and Plex both completely ignore the Symlinks.

The solution for me was to convert all of these symlinks to hard links instead.  There are certain considerations in doing this (a hard-link is essentially one file with multiple different names, whereas a symlink is a file pointing to the path of another file; for example, your backup program might back all the hard linked files up twice?) but I think I've got around those now.

Emby is quite happy reading the hard links.

Anyway, in case it's of use to somebody in the future, the bash commands were:

# 1 - (optional) make a full copy of all the symlinks (takes no time and no extra room):
cp -r ./old_lib/ ./new_lib


# 2 - find all the symlinks in the new library and make them into hard links using readlink and ln -f:
cd ./new_lib
find -type l -exec bash -c 'ln -f "$(readlink -m "$0")" "$0"' {} \;

This should also be quick and not take up disk space!

I'm sure there are a few caveats here.  For example, this won't work for people who are symlinking whole folders (you can't Hard-Link a directory), and you can only create hard links within the same partition.  I'm sure there are others, so try at your own risk!  Probably a good idea to run some tests before you dive in to doing your whole collection.

 







Also tagged with one or more of these keywords: symlink, feature, request

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users