Jump to content

ServerWMC Deleted my Recordings? Help


CFC
Go to solution Solved by krustyreturns,

Recommended Posts

My WMC recordings have been deleted by ServerWMC, and I'm trying to figure out how it happened.

Please see the attached log starting at 20:15:03.957 there are several lines like:

 

2016/02/29 20:15:03.957 Received client request: MediaBrowser^@THASERVER@|192.168.1.100|DeleteRecording|10977524097282978
2016/02/29 20:15:03.957 RecordingCache_Delete> succeeded: true (Id: 10977524097282978)
2016/02/29 20:15:03.957 Finished request DeleteRecording in 0.00s
2016/02/29 20:15:03.957 DeleteRecording_background> deleting Recording by Id: 10977524097282978, Title:
2016/02/29 20:15:03.957 DeleteRecording_background> Recording found: Downton Abbey on Masterpiece - Downton Abbey on Masterpiece Id:0xE00000001CFFF (3940649674067967) at 2/28/2016 10:30:03 PM (10977524097282978)
2016/02/29 20:15:04.035 Received client request: MediaBrowser^@THASERVER@|192.168.1.100|DeleteRecording|10977524097282995
2016/02/29 20:15:04.035 DeleteRecording> fast consecutive delete detected, count: 1
2016/02/29 20:15:04.035 RecordingCache_Delete> succeeded: true (Id: 10977524097282995)
2016/02/29 20:15:04.036 Finished request DeleteRecording in 0.00s
2016/02/29 20:15:04.036 DeleteRecording_background> deleting Recording by Id: 10977524097282995, Title:
2016/02/29 20:15:04.036 DeleteRecording_background> Recording found: Downton Abbey on Masterpiece - Downton Abbey on Masterpiece Id:0xE00000001C9F4 (3940649674066420) at 2/28/2016 9:28:01 PM (10977524097282995)
2016/02/29 20:15:04.073 Received client request: MediaBrowser^@THASERVER@|192.168.1.100|DeleteRecording|10977524095207214
2016/02/29 20:15:04.073 DeleteRecording> fast consecutive delete detected, count: 2
2016/02/29 20:15:04.073 RecordingCache_Delete> succeeded: true (Id: 10977524095207214)
2016/02/29 20:15:04.073 Finished request DeleteRecording in 0.00s

 

 

...and sure enough those recordings, are wiped out.
What is that about?

I didn't request deletion, why did this happen?

Looking at the Emby server log at that same time (around 20:15) I see this:

2016-02-29 20:15:02.0838 Info App: Deleting item from database Downton Abbey on Masterpiece because path no longer exists. type: LiveTvVideoRecording path: \\THAHTPC\Recorded TV\Downton Abbey on Masterpiece_KUHT-HD_2016_02_28_16_30_01.wtv2016-02-29 20:15:02.0994 Info HttpServer: HTTP GET http://192.168.1.100:8096/dlna/418700fade277f4bef7256f2eb535948/description.xml. UserAgent: 2016-02-29 20:15:02.1462 Info HttpServer: HTTP Response 200 to 192.168.1.148. Time: 47ms. http://192.168.1.100:8096/dlna/418700fade277f4bef7256f2eb535948/description.xml2016-02-29 20:15:02.1618 Info App: Deleting item from database Downton Abbey on Masterpiece because path no longer exists. type: LiveTvVideoRecording path: \\THAHTPC\Recorded TV\Downton Abbey on Masterpiece_KUHT-HD_2016_02_28_15_28_00.wtv2016-02-29 20:15:02.1774 Info HttpServer: HTTP SUBSCRIBE http://192.168.1.100:8096/dlna/418700fade277f4bef7256f2eb535948/contentdirectory/events. UserAgent: 2016-02-29 20:15:02.1774 Info HttpServer: HTTP Response 200 to 192.168.1.148. Time: 0ms. http://192.168.1.100:8096/dlna/418700fade277f4bef7256f2eb535948/contentdirectory/events2016-02-29 20:15:02.2086 Info App: Deleting item from database The Walking Dead because path no longer exists. type: LiveTvVideoRecording path: \\THAHTPC\Recorded TV\The Walking Dead_AMCHD_2016_02_28_19_58_00.wtv2016-02-29 20:15:02.2398 Info App: Deleting item from database Downton Abbey on Masterpiece because path no longer exists. type: LiveTvVideoRecording path: \\THAHTPC\Recorded TV\Downton Abbey on Masterpiece_KUHT-HD_2016_02_28_18_30_01.wtv2016-02-29 20:15:02.2866 Info App: Deleting item from database Downton Abbey on Masterpiece because path no longer exists. type: LiveTvVideoRecording path: \\THAHTPC\Recorded TV\Downton Abbey on Masterpiece_KUHT-HD_2016_02_28_17_30_01.wtv2016-02-29 20:15:02.3178 Info App: Deleting item from database Talking Dead because path no longer exists. type: LiveTvVideoRecording path: \\THAHTPC\Recorded TV\Talking Dead_AMCHD_2016_02_28_21_02_05.wtv2016-02-29 20:15:02.3646 Info App: Deleting item from database Eddie Murphy: Raw because path no longer exists. type: LiveTvVideoRecording path: \\THAHTPC\Recorded TV\Eddie Murphy- Raw_CMDHD_2016_02_29_01_13_00.wtv

I couldn't post the complete emby log of the day because it was too large, but I posted the portion around the time the deletion happened.

 

In the meantime, I've disabled the serverWMC plugin.

 

Help please. Pretty please.

 

ServerWMC Log --> ServerWMC.log

Emby Log --> server-63592300803.txt

CFC

Link to comment
Share on other sites

krustyreturns

Yikes.  Sorry that happened to you.  Swmc is just doing what Emby is asking it to do (i.e. delete the recordings).  Have you done anything different in emby before this mass deletion happened?

  • Like 1
Link to comment
Share on other sites

What happened here is the server realized the recording paths were inaccessible, so it sent a command to the tv provider to delete the recording from its' database. This change was actually made for the built-in provider to handle the situation of users deleting recording files directly, this requiring the database to be cleaned up after the fact. I can see how this would negatively affect the other TV providers though, so I will adjust it. Until the next release, the workaround to prevent this from happening is keep the network drive holding the recordings accessible while Emby Server is running.

  • Like 1
Link to comment
Share on other sites

Yikes.  Sorry that happened to you.  Swmc is just doing what Emby is asking it to do (i.e. delete the recordings).  Have you done anything different in emby before this mass deletion happened?

Not that I can think of.

I suppose the log may indicate something, but as far as I can remember, no.

I did notice a call to clean the database at 20:14

The trigger for that task is just every 24hrs.

 

CFC

Link to comment
Share on other sites

What happened here is the server realized the recording paths were inaccessible, so it sent a command to the tv provider to delete the recording from its' database. This change was actually made for the built-in provider to handle the situation of users deleting recording files directly, this requiring the database to be cleaned up after the fact. I can see how this would negatively affect the other TV providers though, so I will adjust it. Until the next release, the workaround to prevent this from happening is keep the network drive holding the recordings accessible while Emby Server is running.

Well, the network drive is always accessible. It's on my HTPC which is always on.

I suppose if there's some kind of home network bobble, that could perhaps show it as inaccessible, but it was not taken offline.

I don't want to take that chance, so I'll keep the TV plugin uninstalled.

Pretty disappointing, but at least it seems to be understood.

Please advise when it's safe again :lol:

 

CFC

Link to comment
Share on other sites

krustyreturns

If I understand what Luke is saying, it seems like this would only happen if you added the recorded tv folder as a media source folder to Emby.  Is that right?

Link to comment
Share on other sites

If I understand what Luke is saying, it seems like this would only happen if you added the recorded tv folder as a media source folder to Emby.  Is that right?

The recorded TV folder was NOT a media source in my configuration.

 

CFC

Link to comment
Share on other sites

krustyreturns

I guess I don't get it, never mind then.  

 

A couple of revs ago I built into swmc protection against a mass deletion (because it was possible to trigger one in kodi too, by accidentally deleting the '..' directory in a recording subfolder).  If more then 10 recording deletion requests happen very quickly swmc ignores deletion requests until the flurry stops.  It looks like your deletion was just on the order of around seven files, so it didn't get triggered.  This threshold can be set in swmc to a lower number if you ever are brave enough to try using it again.

Edited by krustyreturns
Link to comment
Share on other sites

I guess I don't get it, never mind then.  

 

A couple of revs ago I built into swmc protection against a mass deletion (because it was possible to trigger one in kodi too, by accidentally deleting the '..' directory in a recording subfolder).  If more then 10 recording deletion requests happen very quickly swmc ignores deletion requests until the flurry stops.  It looks like your deletion was just on the order of around seven files, so it didn't get triggered.  This threshold can be set in swmc to a lower number if you ever are brave enough to try using it again.

Ha. I'll be using serverWMC as long as you let us.

 

Where can that setting be found? Is there an option to simply not allow swmc to delete at all?

I don't really manage through it, I prefer to do that either on main HTPC, or extenders at home.

I use it to watch on the road, and occasionally assign a recording. Wouldn't hurt my feelings if it couldn't delete.

Thanks for the help

 

CFC

Link to comment
Share on other sites

krustyreturns

Edit the settings file of swmc (see the debug tab).  Then search the xml for:

 

FastMassDeleteCountMax

 

setting it to zero will make it only possible to delete one file at a time i.e. no two quick deletes in succession.  Which is counter-intuitive now that I think about this corner case, so I will change this so that if its set to zero no deletions are possible.  I will be in the next rev.

  • Like 1
Link to comment
Share on other sites

Edit the settings file of swmc (see the debug tab).  Then search the xml for:

 

FastMassDeleteCountMax

 

setting it to zero will make it only possible to delete one file at a time i.e. no two quick deletes in succession.  Which is counter-intuitive now that I think about this corner case, so I will change this so that if its set to zero no deletions are possible.  I will be in the next rev.

Thanks!

I'll look forward to that.

I assume if I change the setting to zero now, when the new rev hits, it'll essentially change to "no delete".

 

CFC

Link to comment
Share on other sites

krustyreturns

Yes, that's correct.  I just tested it and it completely disables deletions.  If you haven't already, set serverwmc updates to 'Preview' and you'll get it as soon as I release it.

  • Like 1
Link to comment
Share on other sites

Yes, that's correct.  I just tested it and it completely disables deletions.  If you haven't already, set serverwmc updates to 'Preview' and you'll get it as soon as I release it.

Perfect. Yes, I'm on the preview updates. I'll get to it when I get home this evening.

Do you think this is an option that should be more forward facing, on the settings GUI?

Even though my Emby user account is not allowed to delete media, it still happened on the backend.

I know @@Luke will be making the change to help with that, but that might not be the case for the other apps who can also interface with serverWMC.

 

Thanks again for the really quick help.

CFC

Link to comment
Share on other sites

  • Solution
krustyreturns

The preview is up and I took your advice and added it to the gui (see Recordings tab).  Thanks.

  • Like 1
Link to comment
Share on other sites

The preview is up and I took your advice and added it to the gui (see Recordings tab).  Thanks.

 

 

the beta branch also has the server changes i mentioned.

 

Awesome.

 

Smooth sailing on this side.

 

Thanks guys.

CFC

Link to comment
Share on other sites

Just a note to some who might chose to disable deletion from client with serverWMC.

This works as expected.

What I didn't realize, is that it also disallows deleting future scheduled recordings.

I also didn't realize that the "allow media deletion" setting only affects the general media library items, and doesn't affect recordings.

The "Allow Live TV Recording Management" takes care of that. If that option is turned off, the delete button is removed, but no recordings can be scheduled.

You have to at least change the "FastMassDeleteCountMax" to 1, to get full control of the recording schedule.

CFC

 

edit: see @@krustyreturns message here

Edited by CFC
Link to comment
Share on other sites

krustyreturns

Some more info: If you tell serverwmc to not accept DeleteRecording commands from clients, all it means is that clients like Emby and Kodi won't be able to use serverwmc to delete recordings - i.e. if they send the commands serverwmc will ignore them.  However the wmc service will still monitor your disk space and delete recordings as set by your preferences in wmc.  I personally never bother to delete recordings manually using a serverwmc client, I just let the wmc service handle it as it does this very well.

 

I'm not sure what you mean by: What I didn't realize, is that it also disallows deleting future scheduled recordings.   Do you mean you can't delete things you have scheduled to record?  because that setting should have no effect on that - it only effects recordings you have.

Link to comment
Share on other sites

Some more info: If you tell serverwmc to not accept DeleteRecording commands from clients, all it means is that clients like Emby and Kodi won't be able to use serverwmc to delete recordings - i.e. if they send the commands serverwmc will ignore them.  However the wmc service will still monitor your disk space and delete recordings as set by your preferences in wmc.  I personally never bother to delete recordings manually using a serverwmc client, I just let the wmc service handle it as it does this very well.

 

I'm not sure what you mean by: What I didn't realize, is that it also disallows deleting future scheduled recordings.   Do you mean you can't delete things you have scheduled to record?  because that setting should have no effect on that - it only effects recordings you have.

 

Hmm... if that's the case, then for some reason Emby server is not allowing me to delete future scheduled recordings. You're right (but you knew that), I toggled the setting in serverWMC, but still the same behavior.

I apologize for not rigorously testing it first.

I'll amend my post.

That being said though, the scheduled recordings aren't being deleted when I choose "Cancel Recording" for that item in the web client. Bug in Emby, or something screwy with my setup.

 

Thanks again for the reply and clarification.

CFC

Edited by CFC
Link to comment
Share on other sites

krustyreturns

Feel free to post the serverwmc log after you fail try to cancel a recording and I can see if its failing on that side.

Link to comment
Share on other sites

Feel free to post the serverwmc log after you fail try to cancel a recording and I can see if its failing on that side.

Got a chance to test it out today, and all worked as expected. Must've been something funky with configuration.

Thanks again for the help.

 

CFC

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