Kodi Community Forum
[RELEASE] Library watchdog - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: Add-on Support (https://forum.kodi.tv/forumdisplay.php?fid=27)
+---- Forum: Service Add-ons (https://forum.kodi.tv/forumdisplay.php?fid=152)
+---- Thread: [RELEASE] Library watchdog (/showthread.php?tid=128896)



RE: [RELEASE] Library watchdog - jenkins - 2013-02-24

Hi,

very nice addon!

is it possible to enable library updates while playing again?


RE: [RELEASE] Library watchdog - takoi - 2013-02-24

(2013-02-23, 22:17)fernandovg Wrote: Did you tried with usb hdd instead of usb flash/drive?

mediasource.xml should not be empty?

Maybe is something related to RASPBMC, the Raspberry Pi OS

How watchdog detects a new usb HDD connected?

Check sources.xml. Watchdog doesn't "detect" new usb hdd connected, there's no need to. The first thing the addon does is call the Files.GetSources json method. This should return all the registered sources, even if it's doesn't exist That method for some reason not giving the media source seems like the most plausible imo.

(2013-02-24, 13:54)jenkins Wrote: Hi,

very nice addon!

is it possible to enable library updates while playing again?

Any particular reason you want that? What will happen is frame drops and big dialogs in front of the video. It does "remember" everything that happens during playback so it will do all the work once playback stops.

(2013-02-24, 00:07)labtopia Wrote:
(2013-02-21, 12:14)jjmucker Wrote: Ive found recently that it doesnt always scan new media coming in. sometimes when i know something has been downloaded and should be in there, it isnt. i then have to manually update the library, anyone else had this?

YES I am seeing the same here, i thouight it might be the screensaver messing it up but disabled it. it will often not pickup on new files. im on windows32bit with auto indefinite subfolders setting.

dave

Like I already said: increase delay or fix the caching on your server. If that doesn't work: debug log


Sv: [RELEASE] Library watchdog - jenkins - 2013-02-24

Yeah thing is I never stop playback... :-)

Joust exits out to main and starts the next thing...

Would be nice with the option at least?


RE: [RELEASE] Library watchdog - fernandovg - 2013-02-25

(2013-02-24, 17:48)takoi Wrote:
(2013-02-23, 22:17)fernandovg Wrote: Did you tried with usb hdd instead of usb flash/drive?

mediasource.xml should not be empty?

Maybe is something related to RASPBMC, the Raspberry Pi OS

How watchdog detects a new usb HDD connected?

Check sources.xml. Watchdog doesn't "detect" new usb hdd connected, there's no need to. The first thing the addon does is call the Files.GetSources json method. This should return all the registered sources, even if it's doesn't exist That method for some reason not giving the media source seems like the most plausible imo.


My userdata/source.xml

There's nothing here about my /media/SAMSUNG as I posted a page ago
Why there's nothing at this file?
How do I have a videolibrary with scrapper with source.xml "empty"?

Code:
<sources>
    <programs>
        <default pathversion="1"></default>
    </programs>
    <video>
        <default pathversion="1"></default>
    </video>
    <music>
        <default pathversion="1"></default>
    </music>
    <pictures>
        <default pathversion="1"></default>
    </pictures>
    <files>
        <default pathversion="1"></default>
        <source>
            <name>Pi</name>
            <path pathversion="1">/home/pi/</path>
        </source>
        <source>
            <name>mp3</name>
            <path pathversion="1">smb://HP-PAVILION/mp3/</path>
        </source>
    </files>



RE: [RELEASE] Library watchdog - mobias1313 - 2013-02-25

Has anyone else seen this add on causing a serious memory leak. I had to disable it because overnight and sometimes randomly throughout the day errors would be thrown and xbmc would consume 3.5gb of memory and the screen would just go black. I had to do a hard reboot to get it to work again. It literally locked up everything on my system.


RE: [RELEASE] Library watchdog - takoi - 2013-02-26

(2013-02-25, 02:37)fernandovg Wrote:
(2013-02-24, 17:48)takoi Wrote:
(2013-02-23, 22:17)fernandovg Wrote: Did you tried with usb hdd instead of usb flash/drive?

mediasource.xml should not be empty?

Maybe is something related to RASPBMC, the Raspberry Pi OS

How watchdog detects a new usb HDD connected?

Check sources.xml. Watchdog doesn't "detect" new usb hdd connected, there's no need to. The first thing the addon does is call the Files.GetSources json method. This should return all the registered sources, even if it's doesn't exist That method for some reason not giving the media source seems like the most plausible imo.
My userdata/source.xml

There's nothing here about my /media/SAMSUNG as I posted a page ago
Why there's nothing at this file?
How do I have a videolibrary with scrapper with source.xml "empty"?

*snip*

Then the problem is found. I'm pretty sure that file should store all the source xbmc know about. sources.xml (wiki). And since xbmc dont know about it, the addon dont know about it. This is beyond what I can help you with so you could take it to the general help and support forum. But before all that, why not try the obvious: delete the .xbmc folder and start over.


RE: [RELEASE] Library watchdog - stevey_frac - 2013-02-27

Hi Takoi,

Ran into a bug with Watchdog that I thought you might want to know about.

I was running into the 'service init failed message'. It failed on line 30 of default.py, and it failed there because somehow, the settings value for polling got set to 'Syscall' instead of '1' or '0'.

When this happens, we attempt to parse the string as an int, and stuff blows up. Setting the value back to 0 fixes the problem, and watchdog operates normally again.

I have a debug log if you really need to see it, but I think i've done enough debugging that you should be able to fix things from here.

Thanks!

--Steve


RE: [RELEASE] Library watchdog - takoi - 2013-02-27

(2013-02-27, 07:08)stevey_frac Wrote: Hi Takoi,

Ran into a bug with Watchdog that I thought you might want to know about.

I was running into the 'service init failed message'. It failed on line 30 of default.py, and it failed there because somehow, the settings value for polling got set to 'Syscall' instead of '1' or '0'.

When this happens, we attempt to parse the string as an int, and stuff blows up. Setting the value back to 0 fixes the problem, and watchdog operates normally again.

I have a debug log if you really need to see it, but I think i've done enough debugging that you should be able to fix things from here.

Thanks!

--Steve

Ty. Looks like a bug PR1691 in eden. I'll change it back to enum since well, it doesn't work at all, but you should really upgrade to frodo. I'm dying to leave eden for dead..


RE: [RELEASE] Library watchdog - jjmucker - 2013-02-28

Part if my errors. Anyone came across these?

00:06:03 T:63584 ERROR: Error Type: <type 'exceptions.ValueError'>
00:06:03 T:63584 ERROR: Error Contents: invalid literal for int() with base 10: 'Syscall'

also,

00:06:45 T:63568 ERROR: Error Type: <type 'exceptions.IOError'>
00:06:45 T:63568 ERROR: Error Contents: (2, 'No such file or directory', 'C:\\Users\\JJs_MediaPc\\AppData\\Roaming\\XBMC\\addons\\service.watchdog\\default.py')
00:06:45 T:63568 ERROR: IOError: (2, 'No such file or directory', 'C:\\Users\\JJs_MediaPc\\AppData\\Roaming\\XBMC\\addons\\service.watchdog\\default.py')
00:07:08 T:29916 ERROR: XFILE::CFile:Big Grinelete - Error deleting file C:\Users\JJs_MediaPc\AppData\Roaming\XBMC\userdata\Thumbnails\0\0a0b24bf.png
00:07:08 T:29916 ERROR: XFILE::CFile:Big Grinelete - Error deleting file special://masterprofile/Thumbnails/0/0a0b24bf.png


RE: [RELEASE] Library watchdog - shedrock - 2013-02-28

I did a fresh in stall of OpenELEC 3.0 (RC3) and I can't seem to get Watchdog to work anymore. On my old install of the same version of OpenELEC it all worked fine from OE (RC2) to (RC3).

I have tried everything I can think of. I have a mounted share setup like this:

I used mklink and created a "Shares" folder and inside that one share I have Movies1, Movies2 etc. I also have TVShows1, TVShows2 etc. I then mount that share in autostart.sh and it has always worked for me.

I also have watchdog set to polling but the weird thing is that if I manually drop a movie in the movies folder or a tv show in the tvshows folder, watchdog picks it up. However, if NZBDrone processes a file and then moves it to the appropriate series folder, nothing happens.

Before this issue I would be watching a movie or tv show and once I am finished watching and exit, I used to see Library Watchdog doing its thing. Anyway, I would really appreciate any help I can get on this.

Thanks in advance.

Shedrock


RE: [RELEASE] Library watchdog - takoi - 2013-02-28

(2013-02-28, 01:59)jjmucker Wrote: Part if my errors. Anyone came across these?

00:06:03 T:63584 ERROR: Error Type: <type 'exceptions.ValueError'>
00:06:03 T:63584 ERROR: Error Contents: invalid literal for int() with base 10: 'Syscall'

also,

00:06:45 T:63568 ERROR: Error Type: <type 'exceptions.IOError'>
00:06:45 T:63568 ERROR: Error Contents: (2, 'No such file or directory', 'C:\\Users\\JJs_MediaPc\\AppData\\Roaming\\XBMC\\addons\\service.watchdog\\default.py')
00:06:45 T:63568 ERROR: IOError: (2, 'No such file or directory', 'C:\\Users\\JJs_MediaPc\\AppData\\Roaming\\XBMC\\addons\\service.watchdog\\default.py')
00:07:08 T:29916 ERROR: XFILE::CFile:Big Grinelete - Error deleting file C:\Users\JJs_MediaPc\AppData\Roaming\XBMC\userdata\Thumbnails\0\0a0b24bf.png
00:07:08 T:29916 ERROR: XFILE::CFile:Big Grinelete - Error deleting file special://masterprofile/Thumbnails/0/0a0b24bf.png
Fist one was discussed one post above. Fix is already underway. Can in the mean time be fixed by resetting settings to default. Second is not addon error but xbmc error. Deleting service.watchdog folder and reinstall will probably do, but clearly you have other issues as well (i.e error deleting thumbnails)

(2013-02-28, 04:23)shedrock Wrote: I did a fresh in stall of OpenELEC 3.0 (RC3) and I can't seem to get Watchdog to work anymore. On my old install of the same version of OpenELEC it all worked fine from OE (RC2) to (RC3).

I have tried everything I can think of. I have a mounted share setup like this:

I used mklink and created a "Shares" folder and inside that one share I have Movies1, Movies2 etc. I also have TVShows1, TVShows2 etc. I then mount that share in autostart.sh and it has always worked for me.

I also have watchdog set to polling but the weird thing is that if I manually drop a movie in the movies folder or a tv show in the tvshows folder, watchdog picks it up. However, if NZBDrone processes a file and then moves it to the appropriate series folder, nothing happens.

Before this issue I would be watching a movie or tv show and once I am finished watching and exit, I used to see Library Watchdog doing its thing. Anyway, I would really appreciate any help I can get on this.

Thanks in advance.

Shedrock
The fact that it doesn't pick it up only in certain scenarios tells me it the nzbdrone doing something weird, but I cant know without debug log...


Sv: [RELEASE] Library watchdog - jenkins - 2013-03-01

Thank for the update dude!


RE: [RELEASE] Library watchdog - Aenima99x - 2013-03-02

(2013-02-25, 02:47)mobias1313 Wrote: Has anyone else seen this add on causing a serious memory leak. I had to disable it because overnight and sometimes randomly throughout the day errors would be thrown and xbmc would consume 3.5gb of memory and the screen would just go black. I had to do a hard reboot to get it to work again. It literally locked up everything on my system.

Same issue here. Lately I've noticed that it will cause CPU spikes every couple seconds and the RAM usage just continues to grow until it consumes it all, freezes the entire system and I have to do a hard reset. (This is with 8GB RAM)

With Watchdog disabled, XBMC sits at a constant 2% CPU and 1.6% RAM - after 5 min, these values were the same.

With Watchdog enabled, XBMC immediately started spiking the CPU every other second. It would be on average from 4-9% and spike as high as 30%. After 5 minutes RAM usage had grown to 5%.

Also as soon as I enable Watchdog, the log begins filling with these
Code:
12:04:39 T:139890431878912   DEBUG: NEWADDON PythonCallbackHandler construction with PyThreadState 0x7f3ad421a190
12:04:39 T:139890406700800   DEBUG: NEWADDON PythonCallbackHandler construction with PyThreadState 0x7f3ad41d3d90
12:04:39 T:139891627116288   DEBUG: NEWADDON PythonCallbackHandler construction with PyThreadState 0x7f3afc005950

I love the addon and I hate to do it, but I've had to disable it for the time being. If I can get you any logs or other info to help troubleshoot this, please let me know Takoi.


RE: [RELEASE] Library watchdog - takoi - 2013-03-02

Those lines are normal. Post the entire log instead of guessing what's relevant. I still can't reproduce the memory leaking myself, and I'm still looking for a debug log for it. The "spikes" are also normal for polling. 30% of the <25% of the time it's active is hardy high imo. Xbmc itself 'spike' a lot more than that. There's a whole section about performance in the first post. Set it to "Depth 1" and it will be ~0%


RE: [RELEASE] Library watchdog - kadeschs - 2013-03-02

I noticed major performance issues and had to uninstall. When I posted about it here, I was told this adding couldn't do anything of that magnitude. So, I just stopped using it.