[mythtv-users] Accessing Mythbackend via UPNP

John Pilkington J.Pilk at tesco.net
Fri Feb 13 17:25:09 UTC 2015


On 13/02/15 15:43, David Hampton wrote:
> Hi,
>
> I'm trying to use UPNP for the first time, and am unable to locate my
> myth backend via the UPNP protocol.  When I run wireshark on my local
> machine I see frequent MDNS and SSDP messages from a file server, but I
> only ever see an occasional MDNS message from the myth backend.  I tried
> enabling upnp logging (-v none,upnp --loglevel debug) on the backend,
> and myth believes its sending SSDP notification messages, but wireshark
> never sees those messages hit the wire.  Here a log excerpt from a
> startup with only upnp logging enabled:
>
> 2015-02-12 23:07:04.750213 I  SSDP::EnableNotifications() - sending NTS_byebye
> 2015-02-12 23:07:04.750269 I  UPnpNotifyTask::SendNotifyMsg : 239.255.255.250:1900 : upnp:rootdevice : uuid:::upnp:rootdevice
> 2015-02-12 23:07:04.903074 I  UPnpNotifyTask::SendNotifyMsg : 239.255.255.250:1900 : uuid: : uuid:
> 2015-02-12 23:07:04.923967 I  UPnpNotifyTask::SendNotifyMsg : 239.255.255.250:1900 :  : uuid:::
> 2015-02-12 23:07:05.010700 I  UPnpNotifyTask::SendNotifyMsg : 239.255.255.250:1900 : urn:microsoft.com:service:X_MS_MediaReceiverRegistrar:1 : uuid:::urn:microsoft.com:service:X_MS_MediaReceiverRegistrar:1
> 2015-02-12 23:07:05.026723 I  UPnpNotifyTask::SendNotifyMsg : 239.255.255.250:1900 : urn:schemas-upnp-org:service:ConnectionManager:1 : uuid:::urn:schemas-upnp-org:service:ConnectionManager:1
> 2015-02-12 23:07:05.101670 I  UPnpNotifyTask::SendNotifyMsg : 239.255.255.250:1900 : urn:schemas-upnp-org:service:ContentDirectory:1 : uuid:::urn:schemas-upnp-org:service:ContentDirectory:1
> 2015-02-12 23:07:05.111431 I  SSDP::EnableNotifications() - sending NTS_alive
> 2015-02-12 23:07:05.111446 I  Starting TaskQueue Thread...
> 2015-02-12 23:07:05.111554 I  TaskQueue Thread Started.
> 2015-02-12 23:07:05.111565 I  SSDP::EnableNotifications() - Task added to UPnP queue
> 2015-02-12 23:07:05.111570 D  UPnp::Start - Returning
> 2015-02-12 23:07:05.111841 I  TaskQueue Thread Running.
> 2015-02-12 23:07:05.111942 I  UPnpNotifyTask::SendNotifyMsg : 239.255.255.250:1900 : upnp:rootdevice : uuid:::upnp:rootdevice
> 2015-02-12 23:07:05.123822 I  MediaServer:Init:End
> 2015-02-12 23:07:05.167536 I  UPnpNotifyTask::SendNotifyMsg : 239.255.255.250:1900 : uuid: : uuid:
> 2015-02-12 23:07:05.286496 I  UPnpNotifyTask::SendNotifyMsg : 239.255.255.250:1900 :  : uuid:::
> 2015-02-12 23:07:05.439684 I  UPnpNotifyTask::SendNotifyMsg : 239.255.255.250:1900 : urn:microsoft.com:service:X_MS_MediaReceiverRegistrar:1 : uuid:::urn:microsoft.com:service:X_MS_MediaReceiverRegistrar:1
> 2015-02-12 23:07:05.481091 I  UPnpNotifyTask::SendNotifyMsg : 239.255.255.250:1900 : urn:schemas-upnp-org:service:ConnectionManager:1 : uuid:::urn:schemas-upnp-org:service:ConnectionManager:1
> 2015-02-12 23:07:05.534329 I  UPnpNotifyTask::SendNotifyMsg : 239.255.255.250:1900 : urn:schemas-upnp-org:service:ContentDirectory:1 : uuid:::urn:schemas-upnp-org:service:ContentDirectory:1
>
> Comparing these to messages from my file server, these messages are all
> missing the actual UUID value.  I poked around, but I don't see where
> this is defined.  I do see the following message when searching other
> myth log files with normal logging enabled:
>
> 2015-02-09 02:22:54.860839 E [12434/12434] CoreContext upnputil.cpp:51
> (LookupUDN) - LookupUDN()- bad device type '', not enough tokens
>
> Looking at the LookupUDN function it appears to be aborting before
> generating and saving a UDN for the device, because the device type is
> NULL.  The question now is why is the device type null?  I think I'm on
> the right track, but I haven't chased it back further than this.  It
> seems like maybe I'm missing something in my configuration?  This is a
> backend that was installed sometime in 2007 and has been upgraded over
> the years, so its entirely possible something may have gotten dropped or
> left out along the way.
>
> Any help would be appreciated.  TIA.
>
> David

You don't say what your real client will be.  I find (with a 
few-days-old master) that the myth debug messages during normal use are 
now quite rare, but on powering up/down my tv I see stuff like this:

2015-02-13 17:02:10.986734 I  SSDP Cache adding USN: 
uuid:4D454930-0100-1000-8001-8CC1210C3590::urn:schemas-upnp-org:device:MediaRenderer:1 
Location http://192.168.0.6:55000/dmr/ddd.xml
2015-02-13 17:02:10.986819 I  SSDP Cache adding USN: 
uuid:4D454930-0100-1000-8001-8CC1210C3590::upnp:rootdevice Location 
http://192.168.0.6:55000/dmr/ddd.xml
2015-02-13 17:02:10.987059 I  SSDP Cache adding USN: 
uuid:4D454930-0100-1000-8001-8CC1210C3590::urn:schemas-upnp-org:service:RenderingControl:1 
Location http://192.168.0.6:55000/dmr/ddd.xml
2015-02-13 17:02:10.987241 I  SSDP Cache adding USN: 
uuid:4D454930-0100-1000-8001-8CC1210C3590::urn:schemas-upnp-org:service:ConnectionManager:1 
Location http://192.168.0.6:55000/dmr/ddd.xml
2015-02-13 17:02:10.987409 I  SSDP Cache adding USN: 
uuid:4D454930-0100-1000-8001-8CC1210C3590::urn:schemas-upnp-org:service:AVTransport:1 
Location http://192.168.0.6:55000/dmr/ddd.xml
2015-02-13 17:02:11.191260 I  SSDP Cache adding USN: 
uuid:4D454930-0200-1000-8001-8CC1210C3590 Location 
http://192.168.0.6:55000/nrc/ddd.xml
2015-02-13 17:02:11.191363 I  SSDP Cache adding USN: 
uuid:4D454930-0200-1000-8001-8CC1210C3590::urn:panasonic-com:device:p00RemoteController:1 
Location http://192.168.0.6:55000/nrc/ddd.xml
2015-02-13 17:02:11.191499 I  SSDP Cache adding USN: 
uuid:4D454930-0200-1000-8001-8CC1210C3590::upnp:rootdevice Location 
http://192.168.0.6:55000/nrc/ddd.xml
2015-02-13 17:02:11.191698 I  SSDP Cache adding USN: 
uuid:4D454930-0200-1000-8001-8CC1210C3590::urn:panasonic-com:service:p00NetworkControl:1 
Location http://192.168.0.6:55000/nrc/ddd.xml
2015-02-13 17:06:47.303393 I  SSDP Cache removing USN: 
uuid:4D454930-0100-1000-8001-8CC1210C3590 Location 
http://192.168.0.6:55000/dmr/ddd.xml
2015-02-13 17:06:47.303475 I  SSDP Cache removing USN: 
uuid:4D454930-0100-1000-8001-8CC1210C3590::urn:schemas-upnp-org:device:MediaRenderer:1 
Location http://192.168.0.6:55000/dmr/ddd.xml
2015-02-13 17:06:47.303667 I  SSDP Cache removing USN: 
uuid:4D454930-0100-1000-8001-8CC1210C3590::upnp:rootdevice Location 
http://192.168.0.6:55000/dmr/ddd.xml
2015-02-13 17:06:47.303860 I  SSDP Cache removing USN: 
uuid:4D454930-0100-1000-8001-8CC1210C3590::urn:schemas-upnp-org:service:RenderingControl:1 
Location http://192.168.0.6:55000/dmr/ddd.xml
2015-02-13 17:06:47.304775 I  SSDP Cache removing USN: 
uuid:4D454930-0100-1000-8001-8CC1210C3590::urn:schemas-upnp-org:service:ConnectionManager:1 
Location http://192.168.0.6:55000/dmr/ddd.xml
2015-02-13 17:06:47.305010 I  SSDP Cache removing USN: 
uuid:4D454930-0100-1000-8001-8CC1210C3590::urn:schemas-upnp-org:service:AVTransport:1 
Location http://192.168.0.6:55000/dmr/ddd.xml
2015-02-13 17:06:47.509615 I  SSDP Cache removing USN: 
uuid:4D454930-0200-1000-8001-8CC1210C3590 Location 
http://192.168.0.6:55000/nrc/ddd.xml
2015-02-13 17:06:47.509698 I  SSDP Cache removing USN: 
uuid:4D454930-0200-1000-8001-8CC1210C3590::urn:panasonic-com:device:p00RemoteController:1 
Location http://192.168.0.6:55000/nrc/ddd.xml
2015-02-13 17:06:47.509794 I  SSDP Cache removing USN: 
uuid:4D454930-0200-1000-8001-8CC1210C3590::upnp:rootdevice Location 
http://192.168.0.6:55000/nrc/ddd.xml
2015-02-13 17:06:47.509864 I  SSDP Cache removing USN: 
uuid:4D454930-0200-1000-8001-8CC1210C3590::urn:panasonic-com:service:p00NetworkControl:1 
Location http://192.168.0.6:55000/nrc/ddd.xml

I suppose you have seen this

https://www.mythtv.org/wiki/UPnP

particularly the 'Troubleshooting' bit?

I don't know how useful this might be, but an example from the wild may 
help.

John P



More information about the mythtv-users mailing list