INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Library Server with multiple libraries  (Read 2114 times)

RemyJ

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 1249
Library Server with multiple libraries
« on: May 16, 2021, 01:14:23 pm »

After a good 10 years, I'm trying Library Server stuff again but unfortunately, it doesn't seem you can serve more than one library from a single server instance.   I hadn't remembered that.  This is an issue if you have multiple people in the house, each with their own library, or have video, image, and music in their own libraries.   

I could probably run a separate docker container for each library but that's a little more overhead than I'd like.  There used to be an option in General settings to run multiple instances of MC.  It's still in User Settings file but not in the settings dialog any more.  You can set it to 1 in the file and it will work but the next time you save the settings dialog, it gets set back to 0 again.  It also seems that check for multiple instances is based on something other than process name.  Window title maybe?  If I start MC locally, then ssh to my media server and run MC via X forwarding, it won't start because the local instance is detected as another instance when it shouldn't be.  Trything this was how I remembered the multiple instance flag. 

So...  I'd like to see the following...

* The multiple instance flag brought back officially and add a command line option for it.
* Add a command line option to specify a profile directory other than ~/.jriver/.   If running MC as a service, we could use BindPaths for this but it'd be better to have official support for it.
* Add a command line option to specify the library server port.
* Allow MC to run in /MediaServer mode without an X display and a logged in user.

With those enhancements we could create a single service file named mediacenter@.service that would run...
/usr/bin/mediacenter27 /MediaServer /Library %I /NewInstance /ProfileDir /home/mediacenter/.jriver_%I

Now, having said all of that...  You could allow the library server to serve all registered libraries when run in MediaServer mode.  Maybe adding a checkbox to the library manager entry to allow remote access as well.  The client would just append the name of the library to the media key or host.   Still need the X decoupling when in MediaServer mode.

Thoughts?



Logged
Fedora 40 x86_64 Xfce

max096

  • MC Beta Team
  • Galactic Citizen
  • *****
  • Posts: 363
Re: Library Server with multiple libraries
« Reply #1 on: May 17, 2021, 08:28:03 pm »

The docker path is probably not a bad option if you want to do that. I do not think you will even notice the overhead. It's very minimal. CPU overhead should be almost non-existen and my container right now uses 106mb ram while streaming music from (which includes what debian needs to run in docker, not just MC). The client I use to playback from uses 91.4mb RAM on bare medal Fedora (so Fedora not included just MC). Maybe 15.4mb additional ram usage? Big overhead? I mean try it, benchmark it whatever. I doubt you will have a performance issue with it unless you need GPU performance (you can setup your GPU to work in docker I have never, yet, done it).

Proper multiuser support would be great! Ideally without needing to run multiple instances of MC, but actually having multiple users who have seperate playlists, 'continue watch' and permission like 'my kid can only read not edit everything' or some kind of buckets that belong to a user that he can edit and the others can only listen. Currently, we seem to only have the one user and the one read-only user. And that's it. Fortunately, I don't currently need to share my library with anybody. But its a bit lackluster if you have to.
Logged

mwillems

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 5234
  • "Linux Merit Badge" Recipient
Re: Library Server with multiple libraries
« Reply #2 on: May 18, 2021, 01:08:23 pm »

Proper multiuser support would be great! Ideally without needing to run multiple instances of MC, but actually having multiple users who have seperate playlists, 'continue watch' and permission like 'my kid can only read not edit everything' or some kind of buckets that belong to a user that he can edit and the others can only listen. Currently, we seem to only have the one user and the one read-only user. And that's it. Fortunately, I don't currently need to share my library with anybody. But its a bit lackluster if you have to.

Multi-user support (or being able to serve multiple libraries) would make me very happy!  There is currently a "user" concept in MC, but it's not implemented in a way that facilitates multiple users accessing the library at once (it's more like a password protected library filter that the server can switch between).  It's one place where other media servers have a lot more options. I'd like to be able to serve more curated content to my kids while also still being able to access all the content myself.  I'm re-doing my network and I'm about to just standup a second server VM or container and just run two different servers as discussed here.  Multiple users or the ability to serve multiple libraries would save me the trouble. 

Also, the current access control model is actually less flexible than one read only and one regular user. You can set read-only access and authentication at the same time but media center clients have no way to choose which endpoint they hit.  I.e. if you try to connect a library client to a server with both enabled it just auto-connects to the read-only and there's no option to enter credentials.  So in reality there's only one remote "user," but you can choose whether it's read-only or not.  I put in a feature request just to facilitate allowing both authenticated and read-only access at the same time, but there wasn't much interest from other users at the time.
Logged
Pages: [1]   Go Up