0

I have fresh instalation of raspbian buster and fresh instalation of kodi 18.7 leia on it. I was trying to lunch upnp client on my Rpi and kodi to play media via windows 10 machine using rpi upnp client. I was using it before on my raspberry pi2 with kodi 18.6 leia without any problems.

Now only at first lunch of kodi after instalation upnp was working then after rebooting rpi4 kodi works OK but no upnp client or server. On kodi i see that is enabled but windows 10 machine doesnt see upnp client anymore.

/home/pi/.kodi/userdata and file upnpserver.xml is

<upnpserver>
<UUID></UUID>
<Port>0</Port>
<MaxReturnedItems>0</MaxReturnedItems>
<UUIDRenderer>cb05649b-8f06-35ef-754b-a61361bdaa17</UUIDRenderer>
<PortRenderer>1186</PortRenderer>

port 1186 is open

these ports r open by kodi

kodi.bin_  513    pi   33u  IPv4  17450      0t0  TCP *:1186 (LISTEN)
kodi.bin_  513    pi   34u  IPv6  17458      0t0  TCP [::1]:9090 (LISTEN)
kodi.bin_  513    pi   44u  IPv4  17445      0t0  TCP *:1513 (LISTEN)
kodi.bin_  513    pi   51u  IPv4  17459      0t0  TCP 127.0.0.1:9090 (LISTEN)

so it seems shoudl be working but no

i have disabled wlan and have only cable connection with eth0. To disable wifi i was using command

rfkill block wifi

now i have only eth0 and lo on ifconfig

for now i dont know that can i do to upnp start to work again, kodi have no plugins that could interferring UPNP

Maybe someone can help with that

after searching i found this strange behavior

maybe its related to start sequence

/etc/systemd/system/multi-user.target.wants/kodi.service

[Unit]
Description = Kodi Media Center
After = remote-fs.target network-online.target
Wants = network-online.target

[Service]
User = pi
Group = pi
Type = simple
ExecStart = /usr/bin/kodi-standalone
Restart = on-abort
RestartSec = 5

[Install]
WantedBy = multi-user.target

when i kill kodi and start in shell manual typeing "kodi" or kodi-standalone its starts and upnp start to work... hm

one more important thing when checking port opened by kodi i see that upnp port goes on secon place with manual start of kodi and upnp is working

sudo lsof -i -P -n | grep LISTEN |grep kodi
kodi.bin_ 1101    pi   36u  IPv4  98108      0t0  TCP *:1517 (LISTEN)
kodi.bin_ 1101    pi   45u  IPv4  98115      0t0  TCP *:1857 (LISTEN)
kodi.bin_ 1101    pi   48u  IPv6  98121      0t0  TCP [::1]:9090 (LISTEN)
kodi.bin_ 1101    pi   49u  IPv4  98122      0t0  TCP 127.0.0.1:9090 (LISTEN)

when kodi is starting with system boot port 1857 (new upnp port) is opened on first place maybe its something on it dont know

1 Answer 1

0

I think its related to raspberry pi 4 and starting script of raspbian buster

/etc/systemd/system/multi-user.target.wants/kodi.service

[Unit]
Description = Kodi Media Center
After = remote-fs.target network-online.target
Wants = network-online.target

[Service]
User = pi
Group = pi
Type = simple
ExecStart = /usr/bin/kodi-standalone
Restart = on-abort
RestartSec = 5

[Install]
WantedBy = multi-user.target

when system starts with kodii 've logged via SSH and type

sudo systemctl stop kodi
sudo systemctl start kodi

sudo lsof -i -P -n | grep LISTEN |grep kodi
kodi.bin_ 1173    pi   34u  IPv4 183733      0t0  TCP *:1432 (LISTEN)
kodi.bin_ 1173    pi   48u  IPv6 183752      0t0  TCP [::1]:9090 (LISTEN)
kodi.bin_ 1173    pi   50u  IPv4 183743      0t0  TCP *:1184 (LISTEN)
kodi.bin_ 1173    pi   53u  IPv4 183753      0t0  TCP 127.0.0.1:9090 (LISTEN)

and kodi with upnp is working again, upnp port is different so its related when kodi is starting with system. I think its dirty resolution of this problem but it works and maybe help others

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.