MySQL/Sync other parts of Kodi: Difference between revisions

From Official Kodi Wiki
Jump to navigation Jump to search
>Ddc
No edit summary
Line 96: Line 96:
{{editor note|Note what this is and why you would want to do it}}
{{editor note|Note what this is and why you would want to do it}}
{{-}}<br/><br/>
{{-}}<br/><br/>
==Other ways==
===Using MKLINK===
In Windows you can also use mklink.
Copy the map "Thumbnails" into a map on your server or nas and share the map with full rights.
Make a "network location" to the map you shared.
<pre>
  <substitute>
"xbmc (\\server) (X:)"
  </substitute>
</pre>
Now open commandpromt and type
<pre>
  <substitute>
mklink /d "C:\Users\USERNAME\AppData\Roaming\XBMC\userdata\Thumbnails" "x:\Thumbnails"
  </substitute>
</pre>
Do this on every PC with XBMC

Revision as of 18:31, 15 July 2012

HOW-TO:Sync multiple libraries/Contents Many other things can be synced using path substitution. Note that you can also use the Symlink instructions if your OS supports it. DO NOT TRY TO SHARE DATABASES. This works with both directories and single files (requires at least v11/Eden RC1 for single files). The following directories and files are known to be safe for this task:


Steps

  1. Share your existing userdata folder or a new folder with those files via NFS, SMB, or AFP (make sure have write access, not just read-only access). Most users to do this from the same computer/device as the MySQL server.
  2. Copy the text from the right hand boxes and add it to your advancedsettings.xml file, between the <pathsubstitution> and </pathsubstitution> tags.
  3. Note/copy the network path of your shared data folder and use that to replace PROTOCOL://YOUR_NETWORK_SHARE/xbmc/userdata/, for example an SMB share holding your playlists use smb://NAS/share/xbmc_stuff/Playlists/
  4. Make sure all XBMC devices that are being synced have this addition to their advancedsettings.xml file.

Playlists

  <substitute>
    <from>special://masterprofile/playlists/</from>
    <to>PROTOCOL://YOUR_NETWORK_SHARE/xbmc/userdata/playlists/</to>
  </substitute>

The Playlist folder in XBMC contains music, video and mixed playlists. If you have imported from pre-existing media libraries then you can use your old playlist folder to save time on recreating the various playlists. If your playlists include local file paths, you will need to edit them to use network shares instead.


Add-on data

  <substitute>
    <from>special://masterprofile/addon_data/</from>
    <to>PROTOCOL://YOUR_NETWORK_SHARE/xbmc/userdata/addon_data/</to>
  </substitute>

Sync some of the add-on settings and preferences. With the way python/add-ons/xbmc works, add-ons don't always follow path substitution, and might not always use the remote "addon_data" folder/share. You would have to ask the person who made the add-on to support being able to save the data on a remote share if it is not working with path subs.


Keymaps

  <substitute>
    <from>special://masterprofile/keymaps/</from>
    <to>PROTOCOL://YOUR_NETWORK_SHARE/xbmc/userdata/keymaps/</to>
  </substitute>

Editor note: Note what this is and why you would want to do it


Sources

  <substitute>
    <from>special://masterprofile/sources.xml</from>
    <to>PROTOCOL://YOUR_NETWORK_SHARE/xbmc/userdata/sources.xml</to>
  </substitute>
  <substitute>
    <from>special://masterprofile/mediasources.xml</from>
    <to>PROTOCOL://YOUR_NETWORK_SHARE/xbmc/userdata/mediasources.xml</to>
  </substitute>

The sources.xml file contains a list of all the sources your media will be collected from, including both local and network-based media. It's important to make sure it contains only network shared sources (so that they are accessible by all clients) and that it is synchronised between your XBMC instances. If this isn't done, every time the Update Library command is run on a client, your shared database will be updated to reflect that particular client's sources.


RSS Feeds

  <substitute>
    <from>special://masterprofile/RssFeeds.xml</from>
    <to>PROTOCOL://YOUR_NETWORK_SHARE/xbmc/userdata/RssFeeds.xml</to>
  </substitute>

Editor note: Note what this is and why you would want to do it


Favourites

  <substitute>
    <from>special://masterprofile/favourites.xml</from>
    <to>PROTOCOL://YOUR_NETWORK_SHARE/xbmc/userdata/favourites.xml</to>
  </substitute>

Editor note: Note what this is and why you would want to do it


Other ways

Using MKLINK

In Windows you can also use mklink.

Copy the map "Thumbnails" into a map on your server or nas and share the map with full rights.

Make a "network location" to the map you shared.

  <substitute>
"xbmc (\\server) (X:)"
  </substitute>

Now open commandpromt and type

  <substitute>
mklink /d "C:\Users\USERNAME\AppData\Roaming\XBMC\userdata\Thumbnails" "x:\Thumbnails"
  </substitute>

Do this on every PC with XBMC