Jump to content

server crashes only when viewing specific library in web browser


psybertech

Recommended Posts

psybertech

Sounds like a certain movie is causing it

 

That was my initial thought (after changing a few images)... any way to test for that?

Bad characters in the image file name was my initial thought...

 

The images were allowed to be saved on my local Windows PC and then uploaded (that was my workflow when this started). Not sure if any characters allowed in my default Windows 10 United States install might cause problems. I'd assume I couldn't save them if there were conflicts. I just clicked the add button, browsed and selected the images to replace.

 

Any db tricks I can use to find and replace or convert? I'm not much of an SQLite guy, but very good with mySQL and SQL server for the most part.

 

SELECT *      
FROM ??.db??      
WHERE xxxFIELDxxx LIKE '%[' + CHAR(127)+ '-' +CHAR(255)+']%'  COLLATE something 

 

or something else... I hate fookedd up charsets... not familiar enough with them by heart but know they are a b!tch to find without me searching a ton for helpers.

 

I'll start trying to do a time-walk back and check things out, but I think it will be near impossible to remember and guess to what to change.

 

Help please! I am more than willing to whack through the weeds via SQL.

 

Thanks!

 

J

Link to comment
Share on other sites

psybertech

I suppose you could try setting the limit to 1 and step through them all

 

hahahhahaha............ hahahahahahaahhahhaha..............bwaaaahahahahahhahaha  :D  :P  :lol:  :wacko:

 

Yeah, that's not gonna work with ~5K movies.  :ph34r:

 

I'm trying to pull blocks out based off of modified time and rescanning.... so far... well... it is working but all my artwork is gone. Weird. I just moved 20 movies outside the scan path and everything is missing art except collections BUT the scan is still running so I will wait and see. I'm not sure why the filesystem modified times seem to change when emby scans (ok, edits database items for an entry... not just a scan), but some of them seem to be possible. Migrating to a new system can be challenging I guess. :)

 

I'll report back after I try this and more.......... uggghhhhh  :unsure:

Edited by psybertech
Link to comment
Share on other sites

psybertech

Just an update...

 

I have it narrowed down to about 50 movies that might be causing issues. Only one of which I really care about to modify images and collections, etc. 

So... it seems to be some bad metadata in one of them, just not sure which one and I don't really want to drill down to figure out which one.

Once it starts, it seems I have no choice but to start the library over. I think I know what one it is, but it is odd since I had that one movie (with extras) already changed updated a couple days before this started. But this one movie would also kill the server when browsing it via the metabrowser feature. So something was definitely up with it, but I am not 100% convinced it was THE root cause.

 

Regardless... I am back up and running with all plugins, all movies and my tweak to show 1000 movies per page (which is nice, but if I couldn't get it back wasn't a show stopper of course).

 

So... I think it is done for now and at least I have a clue that bad metadata can possibly kill things. So I won't be doing massive bulk actions without refreshing a lot in the future.

 

I hesitate to change the title to [RESOLVED] since the last time I did that I found another way to break it again.

I'll try to remember to do that in a day or two.

 

cheers!  :D

 

J

Link to comment
Share on other sites

psybertech

Well...

 

Its happening again.

This time a different movie and this time I can't figure it out.

 

Long story - my backend went offline before a scheduled library scan so emby wiped everything.

While re-doing images again, the same issue popped up.

At a certain point in browsing, the server crashes when browsing via the web browser. Yes, everything for troubleshooting has been disabled (plugins & my *.js tweaks are not enabled - even though I know they have nothing to do with this)

 

The issue before was easier to figure out since I found the issue after changing images on less than 50 or so movies. This time however, I did 500 or so movies and I have no idea where to start finding the issue. It is not the same item as last time. If I could sort and remove the A/An/The from the sort, I might have a better time, but without  it, it is not gonna work via the GUI. (4600+ movies).

 

 

Its a bad image/metadata issue. And if not, then something happens when changing images and corrupts the item. Not sure which but changing images is the common denominator.

 

I really want to be able to find it via SQL. 

 

Please tell me there is a way to look for known characters that can crash the server.  If not characters, then other known issues I can search for via SQL.

 

Manually scrolling and guessing is not going to work this time. My only recourse is to, once again, delete the library and start again. I REALLLLLY do not want to to that.

I've done a full rescan of 4600+ movies 4 four times since installing 2 weeks ago. I don't mind the scan (1/2 a day) but then the manual tweaks to change the artwork images just kills me.

 

I will rsync this once it is stable, but man........... owch......... I don't want to setup any backup that will also break until I know what the heck is breaking my setup..

Please help!

 

 

Link to comment
Share on other sites

I think bad image is more likely than bad metadata. I have a feeling it is image processing. We use skia to resize your original image based on the needs of each emby app. We do catch errors reported from Skia but this sounds like something we're unable to crash, and that's why it brings down the whole server process.

 

If you attach a new server log we might be able to look at the content at the end of the log to try and hunt down which library item is causing it.

Link to comment
Share on other sites

psybertech

Luke,

 

If this happens again, I will attach a new log, but so far, every time, the server exits there is no info.

But I am more than happy to attach as many more logs as requested.

 

FYI.... I found the latest movie that caused this mishap.

 

This time it was another movie that shared one similarity to the last one (the ones before I don't know).... I grouped the movies.

 

So this time, and the last, I moved my suspected movies outside the directories that were being scanned, re-scanned, checked and when all was good I re-moved them back and re-scanned again. Once all was OK again, I re-grouped and everything still was OK. It didn't occur to me that the grouping was the cause. Again... this movie is not the same as the last. Av** this time and St** Wa** the last.

 

Anyway... I know the signs now and unfortunately setting movies to 10 limit for browsing is the only way to sort out what one is broken (well, that gets me in the right area and using the metabrowser feature I can figure it out now since the mb browser sorts the same as the GUI).

 

cheers!

 

J

Link to comment
Share on other sites

yes please attach it. and actually if you do figure out an example, you could try deleting the image for that title and see if that resolves it.

Link to comment
Share on other sites

MikePlanet

[...]

 

This time it was another movie that shared one similarity to the last one (the ones before I don't know).... I grouped the movies.

 

[...]

@psybertech: Can you describe, how and where you grouped the movie - I was able to reproduce a situation that leads to the issue you describe - the server process exiting, when such grouped item is called from the server for display - see here.

 

 

I think bad image is more likely than bad metadata. I have a feeling it is image processing. We use skia to resize your original image based on the needs of each emby app. We do catch errors reported from Skia but this sounds like something we're unable to crash, and that's why it brings down the whole server process.

[...]

 

@Luke: You asked me to remove the libskiasharp.dll which I did and it did not prevent the crash - see here.

Link to comment
Share on other sites

psybertech

@@MikePlanet

 

For me, I didn't look at the collections in any of my scenarios.

 

I simply was browsing my movie library (/web/movies.html) and when I saw 3 versions of a movie, I right clicked one, then selected the other 2 then from the 3 dots on the top right and chose to group.

I then did some more image changing on a bunch of titles. When I refreshed the page to see the group and new images for other titles, it was busted.

 

The last time this happened to me, it too was related to a movie I had multiple versions of that I grouped. I just didn't think of that until the last time.

But in all cases, grouping from the main movies library view does it.

No indication in the logs that I could see, but I will post the log if/when this happens again.

 

My plan moving forward is to disable library scans and restart the server any time I change images or mess with any metadata to keep the logs as small as possible for debug.

OH, and don't do more than 5 or 6 changes without hitting F5! :)

Edited by psybertech
Link to comment
Share on other sites

MikePlanet

@@psybertech

ok, thanks - so it seems the workflow was different. As I am still trying to get to the root cause, one more thought: Did the movies you grouped together belong to different library entries? (e.g.I have 3 movie libraries - "current", "children" and "archive" - which are merged in teh GUI to a single view ("group automatically to a single view"). Thus, a movie might exist in different versions and be located in different libraries - maybe this is causing issues? I know this was the case in one sample flow I linked, though I thought it had a relation to the (auto)box-view and grouping. Still waiting for @@Luke to confirm the issue as described - I was able to reproduce it here.

Link to comment
Share on other sites

psybertech

@@psybertech

ok, thanks - so it seems the workflow was different. As I am still trying to get to the root cause, one more thought: Did the movies you grouped together belong to different library entries? (e.g.I have 3 movie libraries - "current", "children" and "archive" - which are merged in teh GUI to a single view ("group automatically to a single view"). Thus, a movie might exist in different versions and be located in different libraries - maybe this is causing issues? I know this was the case in one sample flow I linked, though I thought it had a relation to the (auto)box-view and grouping. Still waiting for @@Luke to confirm the issue as described - I was able to reproduce it here.

In the last case [#x1], no. All 3 were in the same library.

In the one prior [#x2], yes. I have two movie libraries. 1 for everything and 1 for 4k/BluRay. The last case was grouping between 2 libraries.

 

Interesting note, and probably not worth anything... the resolution difference in grouping...

 

In [#x1], same library, but had 1080 & 720 versions that I grouped.

In [#x2], different libraries, but had 1080 and 2160 versions that I grouped.

 

Important? I don't see how, but just wanted to note that.

Link to comment
Share on other sites

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...