325 detectads: -stop {/media/My Video/Titanic_20150607_1216-dec}
324 07/06/2015 12:23:25 : -stop {/media/My Video/Titanic_20150607_1216-dec}
323 detectads: -stop {/media/My Video/Titanic_20150607_1216-dec}
322 07/06/2015 12:21:57 : -stop {/media/My Video/Titanic_20150607_1216-dec}
321 /media/My Video/Titanic_20150607_1216-dec.hmt: No such file or directory
320 detectads: -stop {/media/My Video/Titanic_20150607_1216}
319 07/06/2015 12:21:33 : -stop {/media/My Video/Titanic_20150607_1216}
318 detectads: -start {/media/My Video/Titanic_20150607_1216}
317 07/06/2015 12:16:52 : -start {/media/My Video/Titanic_20150607_1216}
316 detectads: -stop {/media/My Video/Gadget Man_20150607_1204}
315 07/06/2015 12:13:41 : -stop {/media/My Video/Gadget Man_20150607_1204}
Some more examples of missing recording start notifications;
I can see no obvious rhyme or reason to explain when the notifications are missing
I'll add this to the next version, thanks.Also, I wondered about those "0" errors and it turns out that "ts fetch" returns either this or an object, but there is no test for the former, so I added one:
I see the same thing on my boxes.
The way this currently works is that it watches for the creation of a .nts file at the top of the My Video tree or one level down.
It then tries to open the associated .hmt file in order to check that the start time recorded in there is within two minutes of the current time.
I know that a .hmt file is periodically rewritten whilst a recording is in progress. What is probably happening here is that there is a race condition where the .nts file has been created but sometimes the associated .hmt is not yet there. I will add a loop and some retries to the .hmt opening code.
There was an update on the 15th of June which added the retries. Time for plan C?
Yes, there is a similar end-time check for recording stops..
If you aren't already, running recmon with the -d flag might help track down the problem. I'll set mine up that way and keep an eye on it.
Thanks not a directory I had explored before!Presumably /mod/etc/init.d/S54recmon
2015-06-30 18:58:12 Event - [/media/My Video/The One Show]
2015-06-30 18:58:12 [CREATE,ISDIR]
2015-06-30 18:58:12 Adding watch.
2015-06-30 18:58:12 30/06/2015 18:58:12 : -stop {/media/My Video/South Today/South Today_20150630_1829}
2015-06-30 18:58:12 detectads: -stop {/media/My Video/South Today/South Today_20150630_1829}
2015-06-30 18:58:13 Event - [/media/My Video/ITV News & Weather/ITV News & Weather_20150630_1829.hmt]
2015-06-30 18:58:13 [CLOSE_WRITE,CLOSE]
2015-06-30 18:58:13 Event - [/media/My Video/South Today/South Today_20150630_1829.hmt]
2015-06-30 18:58:13 [CLOSE_WRITE,CLOSE]
2015-06-30 18:58:14 Event - [/media/My Video/South Today/.series]
2015-06-30 18:58:14 [DELETE]
2015-06-30 18:58:14 Event - [/media/My Video/South Today]
2015-06-30 18:58:14 [DELETE,ISDIR]
2015-06-30 18:58:14 Event - [/media/My Video/South Today/]
2015-06-30 18:58:14 [IGNORED]
2015-06-30 18:58:19 Event - [/media/My Video/The One Show/The One Show_20150630_1858.hmt]
2015-06-30 18:58:19 [CLOSE_WRITE,CLOSE]
2015-06-30 18:29:24 Event - [/media/My Video/South Today]
2015-06-30 18:29:24 [CREATE,ISDIR]
2015-06-30 18:29:24 Adding watch.
2015-06-30 18:29:24 Event - [/media/My Video/South Today/.series]
2015-06-30 18:29:24 [CREATE]
2015-06-30 18:29:24 Event - [/media/My Video/South Today/.series]
2015-06-30 18:29:24 [CLOSE_WRITE,CLOSE]
2015-06-30 18:29:25 Event - [/media/My Video/South Today/South Today_20150630_1829.hmt]
2015-06-30 18:29:25 [CREATE]
2015-06-30 18:29:25 Event - [/media/My Video/South Today/South Today_20150630_1829.hmt]
2015-06-30 18:29:25 [CLOSE_WRITE,CLOSE]
2015-06-30 18:29:25 Event - [/media/My Video/South Today/South Today_20150630_1829.ts]
2015-06-30 18:29:25 [CREATE]
2015-06-30 18:29:25 Event - [/media/My Video/South Today/South Today_20150630_1829.nts]
2015-06-30 18:29:25 [CREATE]
2015-06-30 18:29:25 Event - [/media/My Video/South Today/South Today_20150630_1829.hmt]
2015-06-30 18:29:25 [CLOSE_WRITE,CLOSE]
2015-06-30 18:29:25 detectads: -start {/media/My Video/South Today/South Today_20150630_1829}
2015-06-30 18:29:25 30/06/2015 18:29:25 : -start {/media/My Video/South Today/South Today_20150630_1829}
2015-06-30 18:29:25 Event - [/media/My Video/South Today/South Today_20150630_1829.hmt]
2015-06-30 18:29:25 [CLOSE_WRITE,CLOSE]
It would appear there might be a timing window that is sometimes missing the creation events for the recording files
The window exists between the creation of the recording directory and the successful establishment of the new watches.
The question is why the initial watches aren't being set up with the -r recursive option?
Nice catch. I'll ponder...
Do you mean the -r option that tools like inotifywatch provide? That behaves in the same way as recmon, adding new watches whenever a new directory is created. inotify doesn't have a mechanism for an automatic recursive watch.
recmon only monitors the top level directories in /My Video/ as that's where new recordings will appear. It's also important to keep memory usage down as each watch consumes 540 bytes of kernel memory and we don't have a lot to play with!
Event - [/media/My Video/Formula 1_ Rewind - Great Britain_20150705_1114.nts]
[CREATE]
Start: 0 (0)
Now: 1436091242 (5599036a)
Time mismatch.
#!/mod/bin/jimsh
puts "[clock format [clock seconds] -format "%d/%m/%Y %H:%M:%S"] : $argv"
return