Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ministry sleeping too long and missing recordings #385

Open
perfessor101 opened this issue Sep 17, 2018 · 8 comments
Open

Ministry sleeping too long and missing recordings #385

perfessor101 opened this issue Sep 17, 2018 · 8 comments

Comments

@perfessor101
Copy link

I guess my media library has gotten too big.
Interface hangs for a few minutes at a time.
Currently using a plex docker to play my media content.

Thing that's causing me frustration is that after a long sleep SageTV is missing the first recordings after it hasn't recorded in a few hours.

I was curious if there was a way to adjust the Ministry wait/sleep times?

@Narflex
Copy link
Member

Narflex commented Sep 17, 2018

I don't think Ministry has anything to do with this...that just does automatic transcoding of files. So if you aren't doing any conversion jobs, it isn't actually doing anything.

If you posted logs of your problem and let us know what recordings were missed when we may be able to tell you what's going on. Also, posting a log file from when the interface hangs as well will be useful since those may be related.

@perfessor101
Copy link
Author

I have debug on but I'm only getting about eight hours in a debug file and the batch file telling me what's getting deleted is doing a findstr on a tail so SageTV can't rename the sagetv_0.txt file.

I spent two days writing intoifywait scripts on UnRaid so I can have a log of when it's happening.
Currently tracking .delete files separately from .ts and .mkv to see the patterns

I'll download inotifywait for windows and see if that will alert me to the deletions and then I'll get more log files from SageTV.

any other settings to change?

and it looks like the last Microsoft frustration pack killed my connection to my second sagetv instance doing recordings or something ... SageTV is deleting all the recordings on the second instance within two minutes of recording them saying they are 0 file length. Files recorded on that instance stay on the secondary server, but anything the primary instance says to record are getting deleted.

@Narflex
Copy link
Member

Narflex commented Sep 19, 2018

If you use 'tail -F' then tail will allow you to follow a file that gets renamed, reopened like what happens to the sagetv_0.txt log file.

I'm a little lost on what you're trying to do at this point since now you are talking about file deletions and before it was about missed recordings and UI hangs.

@perfessor101
Copy link
Author

perfessor101 commented Sep 25, 2018

Sorry for confusing things with multiple issues ... a windows update confused the permissions for the Sagetv secondary recording server I have ... I deleted the share and recreated it then it started working again. It would allow files to be created but not modified ... so it would create a *.ts file then not allow writes to it and then SageTV would delete it.

Back to the issue I was confused over with recordings on tuners that haven't been used in a few hours delaying their start .

Here's a google drive folder with most of my debugging files from the last 24 hours.

I'll restart the server and post more from a fresh boot if needed.

https://drive.google.com/drive/folders/1BfSmL81QrctQX35oqnxL1aV_ekCkqcIv?usp=sharing

Thanks for your time and help,
Bobby

ps's-
I'm really bad at writing windows batch files so it took a while to get all this as automated as possible

the sagetv_1.txt files are time and dated then zipped.

the sagetv.directory.changes files are tracking *.temp and *.ts files as well as changes to the sagetv_1.txt file

the recording.schedule files have the schedules for recordings
if you copy the webserver directory from sagetv into the same location as the recording.schedule files it will display it as a webpage

I was doing a tail -F | finstr "delete" and it was dying when the sagetv_0.txt file got renamed and started fresh ... possibly the pipe was causing it to error out

@perfessor101
Copy link
Author

The remote directory recording errors started again a few days later ... should i open a new issue or look elsewhere for networking and file sharing help. I'll check the SageTV port section of the FAQ and try re entering those in Windows Firewall.

Current log files should reflect this. Trying to get them to sync as they get updated.

When using a networked encoder does SageTV in slave mode record direct to the listed hard disk or does it send the file to the main instance and then back to the drive from there?

I'm recording to a locally mapped directory that maps to drive N: on "SageTV-recorder" that is also mapped on the SageTV main instance as a network drive.

@perfessor101
Copy link
Author

I gave up on the SageTV recording only server as the files just kept error-ing out.
It could create / open the files on the recording server, but it couldn't modify them after creation.

@perfessor101
Copy link
Author

So back to the original issue ...
Many (last night 93%) shows are not starting to record until a few minutes after the show actually starts.
(three to fifteen minutes later, last night)

It's like the recording task of SageTV is waiting too long to wake between starting recordings on my system.
(My computer does not have sleep enabled and neither does SageTV)

I have / had 34,716 recordings which might be the main problem.

My shared folder on google drive has all the logs from the last week
https://drive.google.com/drive/folders/1BfSmL81QrctQX35oqnxL1aV_ekCkqcIv?usp=sharing

I wanted to know short of deleting a few thousand files what I can do.

Thanks for your time and help

@Narflex
Copy link
Member

Narflex commented Dec 5, 2018

The problem is because you have so many recordings and it's taking SageTV a long time to verify they all are actually there...I'm guessing you're using network storage and you may have a drive offline or something else that's causing the slowdown. Nonetheless, there are config changes you should be able to make to correct it.

Set this in Sage.properties:
seeker/disable_video_directory_verifications=true

Based on your logs that'll help a lot...but it won't completely fix the issue.
You should also disable 3D acceleration in the local UI on the server...it's spewing out constant log errors about having a problem with the 3D layer as well which is consuming CPU.

Overall though, I think you have a performance issue with your storage (because people have had more recordings than you without issue).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants