1 out of 4 = Exception with filepath in media-monitor.log
  • Hi there,

    1 out of every 4 MP3 entries in the media-monitor.log is reporting an ERROR:

    tail -f /var/log/airtime/media-monitor/media-monitor.log|grep ERROR
    
    2011-10-19 00:17:01,196 ERROR - [Thread #3] [api_client.py : update_media_metadata()] : LINE 437 - Exception with filepath /var/mp3/xx/70s/list_1979[1]/1979/137 Status Quo - Accident Prone.mp3: HTTP Error 500: Internal Server Error


    Strange!
  • 7 Comments sorted by
  • Hi,

    There should be some related information to this in /var/log/apache2/errors.log

    Please post that.
    Airtime Pro Hosting: http://airtime.pro
  • Hi,

    /var/log/apache2/errors.log

    shows the exactly the same lines.

    right after this:

    
    2011-10-19 00:06:23,395 INFO - [Thread #2] [api_client.py : update_media_metadata()] : LINE 416 - update media <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml">
    <head>
            <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
            <title>Airtime</title>  <script type="text/javascript" src="/js/libs/jquery-1.5.2.min.js"></script>
    <script type="text/javascript" src="/js/libs/jquery-ui-1.8.11.custom.min.js"></script>
    <script type="text/javascript" src="/js/libs/jquery.stickyPanel.js"></script>
    <script type="text/javascript" src="/js/qtip/jquery.qtip-1.0.0.min.js"></script>
    <script type="text/javascript" src="/js/airtime/dashboard/helperfunctions.js"></script>
    <script type="text/javascript" src="/js/airtime/dashboard/playlist.js"></script>
    <script type="text/javascript" src="/js/airtime/common/common.js"></script>     <link href="/css/redmond/jquery-ui-1.8.8.custom.css" media="screen" rel="stylesheet" type="text/css" />
    <link href="/css/pro_dropdown_3.css" media="screen" rel="stylesheet" type="text/css" />
    <link href="/css/styles.css" media="screen" rel="stylesheet" type="text/css" /></head>
    <body>
    
    <div id="login-page"><div class="login_box">
      <div class="logobox">&nbsp;</div>
      <h2>Login</h2>
    
      <div id="login" class="login-content clearfix">
      <p class="light">Please enter your user name and password</p>
        <form enctype="application/x-www-form-urlencoded" method="post" action=""><dl class="zend_form">
    <dt id="username-label"><label for="username" class="required">Username:</label></dt>
    <dd id="username-element">
    <input type="text" name="username" id="username" value="" class="input_text" /></dd>
    <dt id="password-label"><label for="password" class="required">Password:</label></dt>
    <dd id="password-element">
    <input type="password" name="password" id="password" value="" class="input_text" /></dd>
    <dt id="submit-label">&nbsp;</dt><dd id="submit-element">
    <input type="submit" name="submit" id="submit" value="Login" class="ui-button ui-widget ui-state-default ui-button-text-only" /></dd></dl></form>  </div>
    </div>
    <div class="footer"> Airtime&nbsp;1.9.4&nbsp;Copyright &copy; Sourcefabric o.p.s 2010-2011. All rights reserved.<br/>
      Maintained and distributed under GNU GPL v.3 by <a href="http://www.sourcefabric.org"> Sourcefabric o.p.s </a> </div>
    </div>
    
    </body>
    </html>
    , filepath: /var/mp3/xx/80s/1989/092 Samantha Fox - I Only Wanna Be With You.mp3, mode: create
    2011-10-19 00:06:23,395 ERROR - [Thread #2] [api_client.py : update_media_metadata()] : LINE 437 - Exception with filepath /var/mp3/xx/80s/1989/092 Samantha Fox - I Only Wanna Be With You.mp3: No JSON object could be decoded
    2011-10-19 00:06:23,395 INFO - [Thread #2] [workerprocess.py : process_file_events()] : LINE 9 - received event {'is_recorded_show': False, 'mode': 'create', 'filepath': '/var/mp3/xx/80s/1987/183 Madonna - The Look Of Love.mp3'}
    2011-10-19 00:06:23,395 INFO - [Thread #2] [airtimenotifier.py : update_airtime()] : LINE 134 - updating filepath: /var/mp3/xx/80s/1987/183 Madonna - The Look Of Love.mp3
    2011-10-19 00:06:23,428 INFO - [Thread #2] [airtimemetadata.py : get_md_from_file()] : LINE 150 - getting info from filepath /var/mp3/xx/80s/1987/183 Madonna - The Look Of Love.mp3
    2011-10-19 00:06:24,107 ERROR - [Thread #0] [api_client.py : update_media_metadata()] : LINE 437 - Exception with filepath /var/mp3/xx/70s/Jaarlijst_1973[1]/1973/222 Roger Daltrey - It's A Hard Life.mp3: HTTP Error 500: Internal Server Error
    2011-10-19 00:06:24,108 INFO - [Thread #0] [workerprocess.py : process_file_events()] : LINE 9 - received event {'is_recorded_show': False, 'mode': 'create', 'filepath': "/var/mp3/xx/70s/Jaarlijst_1973[1]/1973/086 Carly Simon - You're So Vain.mp3"}
    2011-10-19 00:06:24,108 INFO - [Thread #0] [airtimenotifier.py : update_airtime()] : LINE 134 - updating filepath: /var/mp3/xx/70s/Jaarlijst_1973[1]/1973/086 Carly Simon - You're So Vain.mp3
    2011-10-19 00:06:24,139 INFO - [Thread #0] [airtimemetadata.py : get_md_from_file()] : LINE 150 - getting info from filepath /var/mp3/xx/70s/Jaarlijst_1973[1]/1973/086 Carly Simon - You're So Vain.mp3
    2011-10-19 00:06:24,831 ERROR - [Thread #3] [api_client.py : update_media_metadata()] : LINE 437 - Exception with filepath /var/mp3/xx/70s/jaarlijst_1975[1]/1975/221 Rijk de Gooyer - Johanna.mp3: HTTP Error 500: Internal Server Error
    


  • Could you attach the entire error log
    Airtime Pro Hosting: http://airtime.pro
  • Apologies, I scrolled up too far...

    /var/log/apache2/errors.log shows this
    (I can't attach the whole thing I'm afraid)


    [Tue Oct 18 23:39:24 2011] [warn] RSA server certificate CommonName (CN) `www.bistro2000.fm' does NOT match server name!?
    [Tue Oct 18 23:39:30 2011] [warn] RSA server certificate CommonName (CN) `www.bistro2000.fm' does NOT match server name!?
    [Tue Oct 18 23:39:30 2011] [notice] Apache/2.2.21 (Debian) PHP/5.3.8-2 with Suhosin-Patch mod_ssl/2.2.21 OpenSSL/1.0.0e configured -- resuming normal operations
    [Wed Oct 19 00:06:20 2011] [error] [client 127.0.0.1] PHP Fatal error:  Call to a member function getId() on a non-object in /usr/share/airtime/application/controllers/ApiController.php on line 521
    [Wed Oct 19 00:06:21 2011] [error] [client 127.0.0.1] PHP Fatal error:  Call to a member function getId() on a non-object in /usr/share/airtime/application/controllers/ApiController.php on line 521
    [Wed Oct 19 00:06:23 2011] [error] [client 127.0.0.1] PHP Fatal error:  Call to a member function getId() on a non-object in /usr/share/airtime/application/controllers/ApiController.php on line 521



    The non-object message repeated itself several times a second...
  • Previous errors where from a Debian system with a mounted windows drive (possibly an error source).

    Now here's Airtime on a LARGE EC2 instance... so all MP3s are on a ext4 filesystem.

    Again errors from media monitor:

    2011-10-19 19:33:38,390 INFO - [MainThread] [MediaMonitor.py : <module>()] : LINE 83 - Added watch to /srv/airtime/watched/
    2011-10-19 19:33:38,390 INFO - [MainThread] [MediaMonitor.py : <module>()] : LINE 84 - wdd result 6
    2011-10-19 19:33:38,391 ERROR - [MainThread] [MediaMonitor.py : <module>()] : LINE 92 - Exception: 'ascii' codec can't decode byte 0xc3 in position 6: ordinal not in range(128)


    
    root@aws:~# /etc/init.d/airtime-media-monitor status
    CPU                            = Intel(R) Xeon(R) CPU           E5430  @ 2.66GHz
    Total RAM                      = 7860060 kB
    Free RAM                       = 6414348 kB
    OS                             = 6.0.3 x86-64
    AIRTIME_CONFIG_FILES           = OK
    POSTGRESQL_DATABASE            = OK
    PYTHON_KOMBU_VERSION           = 1.2.0
    PYTHON_POSTER_VERSION          = 0.8.1
    PYTHON_MUTAGEN_VERSION         = 1.20
    PYTHON_PYINOTIFY_VERSION       = 0.9.2
    RABBITMQ_SERVER                = OK
    AIRTIME_VERSION_URL            = http://localhost:80/api/version/api_key/%%api_key%%
    APACHE_CONFIGURED              = YES
    AIRTIME_VERSION                = 1.9.4
    PLAYOUT_ENGINE_PROCESS_ID      = 6208
    PLAYOUT_ENGINE_RUNNING_SECONDS = 776
    LIQUIDSOAP_PROCESS_ID          = 6212
    LIQUIDSOAP_RUNNING_SECONDS     = 776
    MEDIA_MONITOR_PROCESS_ID       = 7038
    MEDIA_MONITOR_RUNNING_SECONDS  = 56
    SHOW_RECORDER_PROCESS_ID       = 3966
    SHOW_RECORDER_RUNNING_SECONDS  = 5557
    ICECAST_PROCESS_ID             = 3618
    
      -- System setup looks OK!
    
    
    
  • So ummm... how do I add a codec that can encode all the funny foreign characters?


    2011-10-20 22:28:02,208 ERROR - [Thread #4] [api_client.py : update_media_metadata()] : LINE 437 - Exception with filepath /var/wwwMIRRORmp3/cd/b/1/t/Ballermann Hits 2003 Party cd2/dj ötzi today is the day.mp3: 'ascii' codec can't encode character u'\xf6' in position 61: ordinal not in range(128)


  • Ah, looks like http://dev.sourcefabric.org/browse/CC-2891

    Apparently fixed in upcoming version 1.9.5.