Win Problem loading Sources from network share using path substitution
#1
Hi,
I'm facing a problem where Kodi won't load the sources from a network share using the path subtitution.
Kodi boots on Windows startup and then sources are not loaded properly.
If a restart Kodi then there's no problem.

I have enabled the logs and when the sources are loaded correctly, the following line is displayed. But if they aren't the line is simply gone and no related error is displayed (believe me, I checked).

Code:
NOTICE: CMediaSourceSettings: loading media sources from special://masterprofile/sources.xml

The library works fine but the sources aren't there.

This is my advancedsettings.xml

Code:
<advancedsettings>
  <videodatabase>
    <type>mysql</type>
    <host>IP</host>
    <port>PORT</port>
    <user>USER</user>
    <pass>PASS</pass>
  </videodatabase>
  <musicdatabase>
        <type>mysql</type>
    <host>IP</host>
    <port>PORT</port>
    <user>USER</user>
    <pass>PASS</pass>
  </musicdatabase>
  <videolibrary>
    <importwatchedstate>true</importwatchedstate>
    <importresumepoint>true</importresumepoint>
  </videolibrary>
    <pathsubstitution>
        <substitute>
            <from>special://profile/sources.xml</from>
            <to>smb://SERVER/xbmc/sources.xml</to>
        </substitute>
    </pathsubstitution>
</advancedsettings>

Thanks.
Reply
#2
Don't use path substitution
Read/follow the forum rules.
For troubleshooting and bug reporting, read this first
Interested in seeing some YouTube videos about Kodi? Go here and subscribe
Reply
#3
I understand using path substitution when you have multiple Kodi installs. That way you modify the sources on one machine and it propagates to all machines. So obviously Martijn's answer isn't the most helpful Rofl

The problem is just because Kodi boots too quickly... Before your network is fully initialized and ready to access shares.

Just delay Kodi enough and all will be fine. You can use a variety of tools to do this:

http://www.thewindowsclub.com/set-delay-...ms-windows

-Pr.
[4 Kodi Clients + 4 Norco RPC-4224 Media Servers w/376 TB HDD Space]
Reply
#4
(2015-03-09, 21:43)Martijn Wrote: Don't use path substitution

Such a useful solution.. Was it necessary?

Delaying the start of Kodi using KodiLauncher app just did the trick.


BTW, this used to work just fine with XBMC 13.2.

Thanks for the suggestion Pr.Sinister.
Reply
#5
(2015-03-09, 22:13)Pr.Sinister Wrote: I understand using path substitution when you have multiple Kodi installs. That way you modify the sources on one machine and it propagates to all machines. So obviously Martijn's answer isn't the most helpful Rofl

The problem is just because Kodi boots too quickly... Before your network is fully initialized and ready to access shares.

Just delay Kodi enough and all will be fine. You can use a variety of tools to do this:

http://www.thewindowsclub.com/set-delay-...ms-windows

-Pr.

Pathsubstitution was never intended for this use. So why was my answer not helpful?
Pathsubstitution should die in a fire
Read/follow the forum rules.
For troubleshooting and bug reporting, read this first
Interested in seeing some YouTube videos about Kodi? Go here and subscribe
Reply
#6
(2015-03-09, 22:21)Martijn Wrote: Pathsubstitution was never intended for this use. So why was my answer not helpful?
Pathsubstitution should die in a fire

LOL! I hope it doesn't... At least until you guys fully implement UPnP and have a Server/Client solution kinda like Plex. That way, we couldn't care less about it since the server handles all the sources, paths and all that.

Big Grin
[4 Kodi Clients + 4 Norco RPC-4224 Media Servers w/376 TB HDD Space]
Reply
#7
(2015-03-09, 22:21)Martijn Wrote:
(2015-03-09, 22:13)Pr.Sinister Wrote: I understand using path substitution when you have multiple Kodi installs. That way you modify the sources on one machine and it propagates to all machines. So obviously Martijn's answer isn't the most helpful Rofl

The problem is just because Kodi boots too quickly... Before your network is fully initialized and ready to access shares.

Just delay Kodi enough and all will be fine. You can use a variety of tools to do this:

http://www.thewindowsclub.com/set-delay-...ms-windows

-Pr.

Pathsubstitution was never intended for this use. So why was my answer not helpful?
Pathsubstitution should die in a fire
Any suggestion to substitute pathsubstitution?
I need to have several installations synced with the same library and sources. Kodi's Wiki suggests my current approach.
Reply
#8
(2015-03-09, 22:38)regi24 Wrote:
(2015-03-09, 22:21)Martijn Wrote:
(2015-03-09, 22:13)Pr.Sinister Wrote: I understand using path substitution when you have multiple Kodi installs. That way you modify the sources on one machine and it propagates to all machines. So obviously Martijn's answer isn't the most helpful Rofl

The problem is just because Kodi boots too quickly... Before your network is fully initialized and ready to access shares.

Just delay Kodi enough and all will be fine. You can use a variety of tools to do this:

http://www.thewindowsclub.com/set-delay-...ms-windows

-Pr.

Pathsubstitution was never intended for this use. So why was my answer not helpful?
Pathsubstitution should die in a fire
Any suggestion to substitute pathsubstitution?
I need to have several installations synced with the same library and sources. Kodi's Wiki suggests my current approach.

It should not be on the wiki or have a big fat warning "use at own risk and it's unsupported "
Read/follow the forum rules.
For troubleshooting and bug reporting, read this first
Interested in seeing some YouTube videos about Kodi? Go here and subscribe
Reply
#9
(2015-03-09, 22:48)Martijn Wrote:
(2015-03-09, 22:38)regi24 Wrote:
(2015-03-09, 22:21)Martijn Wrote: Pathsubstitution was never intended for this use. So why was my answer not helpful?
Pathsubstitution should die in a fire
Any suggestion to substitute pathsubstitution?
I need to have several installations synced with the same library and sources. Kodi's Wiki suggests my current approach.

It should not be on the wiki or have a big fat warning "use at own risk and it's unsupported "

No alternatives to support multiple installations then?
I'll stick with the one (almost) fully working unsupported one..
Reply
#10
(2015-03-09, 21:43)Martijn Wrote: Don't use path substitution

Path subs work just fine in this situation. That is not the issue here.
Reply
#11
Can you get us a debug log (wiki)? That will show if the path subs are being loaded correctly. Be sure to enable debugging and then restart Kodi for it to capture this information in the log.
Reply
#12
(2015-03-09, 22:38)regi24 Wrote: Any suggestion to substitute pathsubstitution?
I need to have several installations synced with the same library and sources. Kodi's Wiki suggests my current approach.

Is it really needed to sync the sources too? I seems to me that you add the sources once and then you don't have to touch it anymore. At least, that's how I've done it. I did not use a path substition to share the sources. I only use a mysql DB to share the library. Just make sure you have the same sources on a machine before you try to perform a clean library call on it.

Remco

BTW, why do you have the importwatchedstate and importresumepoint in your advancedsettings? Aren't those settings that you just want to run once (after which it's imported) and then remove?
Reply

Logout Mark Read Team Forum Stats Members Help
Problem loading Sources from network share using path substitution0