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
Watchdog #50
Comments
Thanks @subogero for opening a new issue for watchdog problem. |
Useful info here: |
Hi @subogero , |
New news on this watch-dog method? |
I was hoping that the freeze problem of I had to use Next ( I would really really appreciate if you design this watchdog method to avoid these |
I'm currently working on the watchdog.
|
Thanks @subogero for keeping the good work. You mean the older version works better and has less bugs (white flicker between videos, video freeze, etc.) !? |
The old version does not freeze at the end. |
OK. |
The bloody instructions are 6 lines above. Come on!!! |
😋 Anyway, the omxplayer downdated (!!) to the older version. Waiting enthusiastically to enable the watchdog method, so as to get rid of the omxplayer freeze problem. |
It seems that a newer version of omxplayer |
Thanks @subogero for your info. I'll give it a try. By the way, what do you mean by does not freeze at the end of videos ? |
I only saw omxplayer 3.7-xxx hanging at the end of the video. |
If current track has length (unlike internet radios), and play time has exceeded it, kill its omxplayer.bin via omxwd script. omxwd kills all omxplayer.bin processes in its own process group, or just the child of an omxplayer PID supplied on command line.
Please test
|
Thanks @subogero for this Just one question: |
Just click the last commit above and read the commit message. |
Segfault both in client omxd S, and server when watchdog running.
Please use newest commit, it fixes client/server segfault.
|
Are the following process OK?
|
I did the following:
And then I tested the system. In order to reproduce the freeze conditions, I do I think the watchdog would be more applicable and useful if running in the background every 1 or 2 seconds. |
Returning with -1 track length without closing the omxplayer.log.xxx file was not a good idea. While playing internet radios (length -1), the watchdog() called this every 10s, opening more and more fds to the same log file, until the entire system collapsed. Fix: set ret val and break instead of return.
I've started testing with videos instead of mp3s, it's much more sensitive, I guess the videos cause much higher processor load. I've reproduced the flickering screen when more videos are played at once. But the last commit improved it in a big way. The watchdog retries killing the target On the other hand, I could not reproduce the SIGFTE. |
I updated to the latest commit via:
After reboot, one of the videos (KK.mp4) which is the last(!!!) video in the playlist directory begins to play, then a white flicker, then the screen gets black, and it doesn't play any other videos. The following are the status of omxd service, both during playing that video, and also after finishing that video and getting to the black screen:
and
and the following are the last lines of
|
The same scenario happens when I run the script manually:
|
Please post the log from the last |
The following are the logs added to
|
Your Are you sure you're running the same code? What are the outputs of the following three commands?
|
I think I'd better re-write my microSD card with my stable backup, then update omxd to the latest commit. |
I wrote the latest backup to microSD, and then updated the omxd to the latest commit as the following:
The last command ( |
OK. Now it works. Here are the logs from
So, back to the huge-breakthrough commit. |
I tested it with both Now, how can I see what will happen if |
player.c: 1st watchdog start to init(), which is called at all main entry points. Simplify omxplayer track/play time extraction. omxwd: also log attempts to kill specific PIDs.
I found another bug with the periodic watchdog, when there were options added before the first playlist tracks. See last commit. I tested it by editing the
|
This way, each track plays 10s longer than the track length, so the watchdog will shut down the track a bit before the end. Test only works with the 1st track of the playlist. Don't forget to restore |
Another new commit on branch wd related to issue #56. Stange behaviour for command A fixed. |
Can I test the new commits via the following?
|
|
I tested adding It affected the behavior of 1st video in the playlist. Sometimes it wold freeze, and then started the 2nd video from middle. Sometimes it would stop 1st video after 2 seconds, and started 2nd video. |
I restored |
After all these commits, the |
When you added The reason this test works only for the 1st video is that all other videos are started earlier and paused, so the So things look good. If no other issue comes up, I'll merge soon and release version 1.8 |
Noticed a new minor bug: These things happen only on the first boot after updating the playlist. And as I said, it's minor, and easy to ignore; but the info might help solve other bugs. Thanks for your support. |
Is it possible that it takes longer to start videos after the reboot? Because the watchdog does not consider that. It has no mercy! :-) |
I tested it by running the script manually. I didn't see any problem. |
Because there is much more processor load during boot. Additionally, video related subsystems might not be fully initialized. |
How much is the optimum GPU memory to set for playing videos with RPi 3? |
I don't have the faintest clue. |
Run a periodic watchdog to detect and kill stale omxplayer instances that have ignored commands on STDIN.
The text was updated successfully, but these errors were encountered: