•   
  • 1
  • 57
  • 58
  • 59(current)
  • 60
  • 61
  • 179
  •   
[RELEASE] Texture Cache Maintenance utility
(2014-03-29, 21:36)francovilar Wrote: running in ubuntu I get this error: ERROR: Socket closed prematurely - exiting
any ideas?
edit: running gotham beta 3

A debug log (wiki) and a @logfile would help but you really need to explain more what you were doing. Possibly xbmc.bin is dying or being killed which is one explanation for the error you are seeing.
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
(2014-03-30, 13:40)MilhouseVH Wrote:
(2014-03-29, 21:36)francovilar Wrote: running in ubuntu I get this error: ERROR: Socket closed prematurely - exiting
any ideas?
edit: running gotham beta 3

A debug log (wiki) and a @logfile would help but you really need to explain more what you were doing. Possibly xbmc.bin is dying or being killed which is one explanation for the error you are seeing.

logfile:
2014-03-30 15:00:44.062983:MainThread: Command line args: ['./texturecache.py', 's', 'Dr. No']
2014-03-30 15:00:44.063087:MainThread: Current version #: v1.5.9
2014-03-30 15:00:44.063127:MainThread: Current platform : linux2
2014-03-30 15:00:44.063172:MainThread: Python version #: v2.7.5.0 (final)
2014-03-30 15:00:44.064864:MainThread: RPC connection established with IPv4
2014-03-30 15:00:44.065038:MainThread: libVersion.JSON SOCKET REQUEST: [{"jsonrpc": "2.0", "method": "JSONRPC.Version", "id": "libVersion"}]
2014-03-30 15:00:44.065434:MainThread: ERROR: Socket closed prematurely - exiting

xbmclog:
http://www.xbmclogs.com/show.php?id=162134
Reply
(2014-03-30, 16:03)francovilar Wrote: logfile:
2014-03-30 15:00:44.062983:MainThread: Command line args: ['./texturecache.py', 's', 'Dr. No']
2014-03-30 15:00:44.063087:MainThread: Current version #: v1.5.9
2014-03-30 15:00:44.063127:MainThread: Current platform : linux2
2014-03-30 15:00:44.063172:MainThread: Python version #: v2.7.5.0 (final)
2014-03-30 15:00:44.064864:MainThread: RPC connection established with IPv4
2014-03-30 15:00:44.065038:MainThread: libVersion.JSON SOCKET REQUEST: [{"jsonrpc": "2.0", "method": "JSONRPC.Version", "id": "libVersion"}]
2014-03-30 15:00:44.065434:MainThread: ERROR: Socket closed prematurely - exiting

Could you add a "raise" instruction at line 1685 so that it becomes:
Code:
...
        else:
          self.logger.err("ERROR: Socket closed prematurely - exiting", newLine=True, log=True)
          raise
          sys.exit(2)

and then upload another logfile and/or whatever stacktrace you see in the console when you run the modified script. I really don't understand why you should be getting an IOError, so I'm hoping that seeing the detail of the exception might shed some light.
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
(2014-03-30, 21:05)MilhouseVH Wrote:
(2014-03-30, 16:03)francovilar Wrote: logfile:
2014-03-30 15:00:44.062983:MainThread: Command line args: ['./texturecache.py', 's', 'Dr. No']
2014-03-30 15:00:44.063087:MainThread: Current version #: v1.5.9
2014-03-30 15:00:44.063127:MainThread: Current platform : linux2
2014-03-30 15:00:44.063172:MainThread: Python version #: v2.7.5.0 (final)
2014-03-30 15:00:44.064864:MainThread: RPC connection established with IPv4
2014-03-30 15:00:44.065038:MainThread: libVersion.JSON SOCKET REQUEST: [{"jsonrpc": "2.0", "method": "JSONRPC.Version", "id": "libVersion"}]
2014-03-30 15:00:44.065434:MainThread: ERROR: Socket closed prematurely - exiting

Could you add a "raise" instruction at line 1685 so that it becomes:
Code:
...
        else:
          self.logger.err("ERROR: Socket closed prematurely - exiting", newLine=True, log=True)
          raise
          sys.exit(2)

and then upload another logfile and/or whatever stacktrace you see in the console when you run the modified script. I really don't understand why you should be getting an IOError, so I'm hoping that seeing the detail of the exception might shed some light.

http://pastebin.com/xYjLc251
in terminal :

./texturecache.py s "Dr. No"
ERROR: Socket closed prematurely - exiting
007877|0/0469fdec.jpg|1080|1920|0001|2013-07-20 11:04:55|2013-12-13 19:30:14|nfs://192.168.2.84/home/inesergio/Media/Movies2/007 Movie Set/Dr. No (1962)/fanart.jpg
007878|1/13f57ae8.jpg|0720|0512|0003|2014-03-29 19:33:31|2013-12-13 19:30:14|nfs://192.168.2.84/home/inesergio/Media/Movies2/007 Movie Set/Dr. No (1962)/poster.jpg
Matching row ids: 7877 7878
Reply
Bugger, that wasn't quite what I was expecting - you'll also need to change line 6593 from:
Code:
...
    except socket.error:
      pass
to
Code:
...
    except socket.error:
      raise

FYI - when uploading more than a half-dozen lines of log file to the forum it's usually best to use pastebin.com or xbmclogs.com.
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
(2014-03-30, 21:35)MilhouseVH Wrote: Bugger, that wasn't quite what I was expecting - you'll also need to change line 6593 from:
Code:
...
    except socket.error:
      pass
to
Code:
...
    except socket.error:
      raise

FYI - when uploading more than a half-dozen lines of log file to the forum it's usually best to use pastebin.com or xbmclogs.com.

already done that, thank you.

2014-03-30 20:37:27.617703:MainThread: Command line args: ['./texturecache.py', 's', 'Dr. No']
2014-03-30 20:37:27.617816:MainThread: Current version #: v1.5.9
2014-03-30 20:37:27.617858:MainThread: Current platform : linux2
2014-03-30 20:37:27.617906:MainThread: Python version #: v2.7.5.0 (final)
2014-03-30 20:37:27.619707:MainThread: RPC connection established with IPv4
2014-03-30 20:37:27.619897:MainThread: libVersion.JSON SOCKET REQUEST: [{"jsonrpc": "2.0", "method": "JSONRPC.Version", "id": "libVersion"}]
2014-03-30 20:37:27.620275:MainThread: ERROR: Socket closed prematurely - exiting
ERROR:root:** Terminating due to unexpected exception **
Traceback (most recent call last):
File "./texturecache.py", line 7151, in <module>
main(sys.argv[1:])
File "./texturecache.py", line 6893, in main
if not checkConfig(argv[0]): sys.exit(2)
File "./texturecache.py", line 6572, in checkConfig
data = jcomms.sendJSON(REQUEST, "libVersion", checkResult=False)
File "./texturecache.py", line 1669, in sendJSON
newdata = s.recv(BUFFER_SIZE)
error: [Errno 104] Connection reset by peer
Reply
@francovilar thanks. This is all rather odd - it appears that the JSON RPC server is not responding correctly.

I can see from your xbmc.log that the RPC Server is listening on port 9090, and from the script config it is configured to use port 9090, so not entirely sure why the script is not receiving a valid response. It would be great if you were able to test the JSON RPC server using another method, do you have any Android or iOS remote control apps available to you?

I do see this in your xbmc.log:
Code:
14:54:25 T:139861497219008   DEBUG: JSONRPC Server: Failed to bind ipv6 serversocket, trying ipv4
14:54:25 T:139861497219008   ERROR: JSONRPC Server: Failed to bind ipv4 serversocket
14:54:25 T:139861497219008    INFO: JSONRPC Server: Successfully initialized

which makes me wonder if you already have some other process listening on port 9090 on this PC, which is preventing the XBMC RPC server from binding and it's this other process that is responding to the script.

Try:
Code:
netstat -nap | grep 9090
and see what process is listed - should be xbmc.bin, but probably (hopefully!) isn't.
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
(2014-03-30, 22:05)MilhouseVH Wrote: @francovilar thanks. This is all rather odd - it appears that the JSON RPC server is not responding correctly.

I can see from your xbmc.log that the RPC Server is listening on port 9090, and from the script config it is configured to use port 9090, so not entirely sure why the script is not receiving a valid response. It would be great if you were able to test the JSON RPC server using another method, do you have any Android or iOS remote control apps available to you?

I do see this in your xbmc.log:
Code:
14:54:25 T:139861497219008   DEBUG: JSONRPC Server: Failed to bind ipv6 serversocket, trying ipv4
14:54:25 T:139861497219008   ERROR: JSONRPC Server: Failed to bind ipv4 serversocket
14:54:25 T:139861497219008    INFO: JSONRPC Server: Successfully initialized

which makes me wonder if you already have some other process listening on port 9090 on this PC, which is preventing the XBMC RPC server from binding and it's this other process that is responding to the script.

Try:
Code:
netstat -nap | grep 9090
and see what process is listed - should be xbmc.bin, but probably (hopefully!) isn't.

That was it I had another process using port 9090. I killed the process and restarted xbmc and all is fine now. thank you. btw can I configure another port for XBMC RPC server?
Reply
(2014-03-30, 22:14)francovilar Wrote: btw can I configure another port for XBMC RPC server?

Yes, specify the <tcpport> in advancedsettings.xml that XBMC should use, then add "rpc.port=#" to texturecache.cfg (where # is your chosen port).

By the way to revert your changes to texturecache.py, run "./texturecache.py fupdate".
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
@MilhouseVH

You may be able to help. I noticed doing a 'Clean Library', it ran very fast through my library, but didn't remove episodes that I had deleted from my NAS.

Now, I tried
Code:
./texturecache.py vclean
, which completed within 20 odd seconds, and episodes were still showing in the Library.

Suppose I'd best do a log and post it up, but maybe you had some idea's on why this is occurring.
Note: If I delete a TV Show, Clean Library removes that show from the Library. It's only episodes that don't get removed.
Media Companion Dev.
Media Companion - Kodi / XBMC - Media Companion
Reply
Yep, @logfile and debug log (wiki) from XBMC.

No real idea why it's occurring - as long as the library clean is started then the script has done its job. If XBMC is failing to clean the video library correctly then that probably needs it's own discussion thread as it's more of a general issue with core functionality.
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
(2014-04-03, 03:51)MilhouseVH Wrote: Yep, @logfile and debug log (wiki) from XBMC.

No real idea why it's occurring - as long as the library clean is started then the script has done its job. If XBMC is failing to clean the video library correctly then that probably needs it's own discussion thread as it's more of a general issue with core functionality.

OK, I'll get alog of texturecache and Debug Log of XBMC and post them up. If you think it's and XBMC issue, then I'll bugger off and create a new thread. Be a couple of hours before I'm home to do that.

Thanks.
Media Companion Dev.
Media Companion - Kodi / XBMC - Media Companion
Reply
Right here we go:

XBMC debug log

vclean log file from
Code:
./texturecache.py vclean @logfile=/home/pi/vclean.txt @debug=yes

If you are able to check these, let me know if I need to open a new thread in XBMC.

Thanks
Media Companion Dev.
Media Companion - Kodi / XBMC - Media Companion
Reply
Script looks fine and did its job correctly, so I'd suggest another thread. I can't see the library clean removing anything so it looks like there's a problem of some sort if the episode really is no longer accessible. You could use texturecach.py rdirectory for the tvshow path to determine what it is the XBMC client "sees" for that particular show (tvshowid 53).
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
Thanks. I'll post the XBMC log to Pi Gotham thread first and if no answers there, open a new thread in XBMC.
Media Companion Dev.
Media Companion - Kodi / XBMC - Media Companion
Reply
  •   
  • 1
  • 57
  • 58
  • 59(current)
  • 60
  • 61
  • 179
  •   
 
Thread Rating:
  • 17 Vote(s) - 4.76 Average



Logout Mark Read Team Forum Stats Members Help
[RELEASE] Texture Cache Maintenance utility4.7617