Jump to content

Emby for Kodi: multi user, multi device discussion


xe`

Recommended Posts

I want to start a discussion on Emby for Kodi in a multi user,  multi device (rooms) system and best practices for maintaining sync, general observations and hopefully ways to improve.

To set the scene this is what I have:

  • One development virtual machine with LibreELEC setup with Emby for Kodi.
  • Several cheap AMLogic devices, one for each TV in my family home also setup with Emby for Kodi.

I was faced with three problems:

  1. How to make Kodi multiuser tie up with Emby multiuser
  2. How to deal with the deprecation of the Kodi shared fanart feature (since it made no sense to have 25+ copies of every image but also cheap AMLogic devices have very little space to utilise).
  3. How to speed up overall database resync work when the Emby for Kodi addon requires a complete reconstruction (either due to problems or upgrade). i.e. as each profile on each device takes several hours to complete then the overall sync time becomes days

 

Making Kodi multiuser tie up with Emby multiuser is actually quite easy as is making multiuser multi device shared fanart work again (accepting that it is unsupported). Essentially the process involves using profiles.xml to define some users in Kodi and advancedsettings.xml path substitution to point all art folders to a central shared nfs store for art. With some trial and error and most of all patience it works... not just works... passes WAF and is usable by small children intuitively. This is a HUGE win for my family and I don't know how I lived without it.

 

This just leaves issue issue three, how to deal with complete resyncs which are required surprisingly often.

 

Currently I cheat. Because all my cheap AMLogic devices are an identical make and model I nominate one as "master" and any time i need to do big changes I do so on this device. Then when this is complete I use rsync to push all off Kodi userdata to every other device excluding a couple of key files. This works quite well and whilst the master device is slow it only takes a couple of minutes to completely update all the rest of the devices (saving a couple of dozen hours).

 

This is a kludge though. It requires that every box be identical, no box can have different addons (say a kids room might want a more child friendly setup or a cinema setup may need differernt sound options) but most of all it touches stuff way outside the scope of Emby and isnt cross platform.

 

On the subject of cross platform, I tested this setup nominating the "virtual machine with LibreELEC" as the "master" and because it is a different CPU architecture it breaks a lot of non Emby stuff but the speed difference is VAST. What takes hours on cheap AMLogic devices take 10 minutes on old VM hardware.

 

Given my successes I really want to push this type of solution into the public domain and discuss ways it can be made slicker, potentially to a point where it is natively supported by the Emby for Kodi addon so that other family's can benefit from it.

 

I can go into more detail on any part but this post was long enough to start.

Link to comment
Share on other sites

TeamB

I have 4 users using 4 raspberry pi devices running libreelic, 2 tablets and 3 laptops.

On the libreelic devices I use fast user switching with the EmbyCon addon, no syncing but it works fine for me.

With auto log off and user selection prompting on screen saver deactivation all the users can jump on and off all libreelic driven devices very easily.

Link to comment
Share on other sites

Last time I tried EmbyCon it was not feature rich enough to be a drop in replacement for Kodi + mysql... but that was then and this is now so I will try again in the coming week. Thanks for the advice. Will report back soon.

Link to comment
Share on other sites

TeamB

It is still not a drop in replacement for native Kodi DB or MySQL.  EmbyCon does not sync your data to the Kodi DB so it will never be a drop in replacement for that use case.

 

It allows you to browse and play back your media, get up and running nearly instantly and because it does not use the local Kodi DB it can fast user switch inside the addon without having to use Kofi profiles.

 

There are pros and cons to each addon, you just need to pick which one best suits your needs.

Edited by TeamB
Link to comment
Share on other sites

I manged to get some time so I installed a clean LibreELEC, Embycon and Embuary on a VM. The install was very smooth and the end experience is very slick. It is also intuitive as I know the native Emby webui quite well.

 

However I did not setup multiuser because I hit a show stopping issue first. It is just too slow. General interaction with the addon is fast enough and it appears some level of caching happens that make second entry into views even faster but as soon as I go off the beaten track it just crawls to a glacial pace. For instance trying to use TV Genre view was a "let it run all night affair" and this morning if i back out of it and enter again its north of a minute view load time.

 

I can only assume this will be much worse of a low end AML box and will surely be a function library size.

 

These were my conclusions the last time I tried Embycon and the reason I settled on Emby for windows.

 

So unless anyone has any suggestions I am going to return to the OT as the only viable way to do Emby for Kodi in a multi user,  multi device (rooms) system at scale.

Link to comment
Share on other sites

TeamB

yep it is slower, but you are hinting at an order of magnitude slower, that should not be the case.

 

For example going into TV Show Genres on my system on a Pi 3 using the EmbyCon main menu interface it takes sub second to view the Genre list.

 

Try accessing the items using the EmbyCon menu directly, it could be a skin issue you are seeing.

 

Anyway it sounds like you need the native Kodi DB speed and are not going to be able to settle on anything slower, if you do find a good simple solution please post.

Link to comment
Share on other sites

I will test some more tonight.

 

Just to be clear though ..."it sounds like you need the native Kodi DB speed" is absolutely not the case. All I need is not slow. A couple to a few seconds to load a view is fine but anything in the tens of seconds or minutes range is not. It quite literally only need it to be "fast enough that it passes WAF" and would far prefer an Embycon solution to the kludge that is multiuser on Emby for Kodi addon currently

Link to comment
Share on other sites

TeamB

If you do see slow access using the actual EmbyCon menu items with the default skin there is a performance profile option under advanced options in the add-on that will save some performance profile logs that lets me see where all the time went.

 

If you are up for some testing this would help track down where all the time is spent.

  • Like 1
Link to comment
Share on other sites

We have not gone away. Essentially something is up and I can make this LibreELEC, Emby, Embuary combo lock on demand in various ways. This feels like a resource issue so before I start feeding back I will rule out that and LibreELEC.

 

This is starting to feel OT for this thread. Would you like a new one (if so where) or are there better real time options e.g. join a common discord, I have a prime candidate in mind

Link to comment
Share on other sites

TeamB

The best way to test is with the default skin with no other addons installed, just EmbyCon.

Use the EmbyCon addon directly to access, any slow access then turn on profile capture in the advanced settings of the addon and upload some of the profile files to a new thread.

Link to comment
Share on other sites

  • 2 weeks later...

I installed a clean instance on a non virtual windows 7 desktop and managed to track down the culprit. It would appear the Embycon Genre views in Estuary are very fast whereas they are very very slow in Embuary. However accessing the genre view by navigating to addons > Embycon > Library - Movies - Genres inm Embuary are also very fast.

 

So this would appear to be a specific Embuary issue.

 

There is a sample "fake" filesystem we used to use to load test OpenELEC and XMBC which I am trying to track down again for use as a common "collection at large scale" so others can see this issue.

Link to comment
Share on other sites

sualfred

It's the slowness of Kodi itself with plugin based listings.

 

I use a hidden container with all available genres and then I'll create custom containers on top of it with 6 random items.

 

If the users has 30 genres per library tag -> 31 plugin calls.

 

With a native Kodi setup this appears in ~ 1s And with a faster machine it will take 1-5s with EmbyCon. Busy dialog is also shown until all is in place.

 

 

5dcbe60f37823_Anmerkung20191113121547.jp

Edited by sualfred
Link to comment
Share on other sites

There may be a bug in here not related to speed as I left this running overnight last night and it never loaded at all in the end. I had to this point assumed it was just crazy slow but 12hours likely means broken in some other way.

Link to comment
Share on other sites

sualfred

Sounds like one container never returned False for Container.IsUpdating. Anyway. I'll get rid of it.

Link to comment
Share on other sites

Sounds like one container never returned False for Container.IsUpdating. Anyway. I'll get rid of it.

OK I have a VM that I can use to test this which (which was subject to this problem and is on yours and the beta Embycon repositories)

 

I would much prefer to use Embycon and Embuary than the complex sync process I have hinted at in the OP as it is really hard to manage keeping over 30 separate profiles directorys in sync home wide.

Link to comment
Share on other sites

TeamB

I had a quick look and can not find that Movie Genre listing in the Emby web interface or Emby Theater, I was looking to see how it is done there in the official apps but it looks like they don't present 6 items items from the genre list only the genre list itself like the EmbyCon Add-on does.

 

I see you mention removing it, I guess it is a balance between oh that is cool and performance.

Link to comment
Share on other sites

For what it is worth Genre View (and year view) are key features in our home. Obviously we can work around it and I am the first to admit I am new to EmbyCon|Embuary so I dont have a good handle on the day to day usage.... but I do know how we use Emby for Kodi.

 

It is worth me saying again though that slow is fine if we are talking in the sub 10s range. The problem I had when testing is it basically locks up the whole experience.

Link to comment
Share on other sites

TeamB

I dont think Genre lists will be removed completely but they will work more like the Emby Theater and Emby Web Client in that you will see a list of genres and then when you pick on you will see items in that genre.

I think what is going to be removed is the preview of 6 items from each genre on the one page listed next to each genre, but @@sualfred can clarify that.

Link to comment
Share on other sites

sualfred

I'm not talking to remove it completely. I'm talking about my "fancy" layout and replace it will a less expensive one.

  • Like 1
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...