Posts: 115
Joined: Feb 2009
Reputation:
0
I have my kodi data stored in a mysql database. That's great for machines I trust, but the main family TV is pretty much fair game. I'd like to make it so that no one can make any changes to shares, add new media, delete new media (including if a movie gets clicked on that no longer exists, that the dialog that offers to delete from the library, doesn't appear).
Wondering if this is something I can do, and if so, from where? The profiles, DB backend, etc?
Posts: 31,445
Joined: Jan 2011
You could make a read-only user for MySQL for those machines. Maybe. I've never tried it myself, and I don't know what Kodi would do in that situation, but I don't think it would hurt to try.
Posts: 13
Joined: Mar 2015
Reputation:
1
I use a MySQL setup and I only added the library in one on computer. None of the others can add or delete from the library because they don't have direct access to the files.
Posts: 115
Joined: Feb 2009
Reputation:
0
Thanks for the replies...
I scan my libraries from a single machine that has RW access to the network share.
I have set a read-only mysql user in advancedsettings.xml on the Pis that connect to each TV. Starting lately, kodi is hanging on various sql commands that fail due to th DB readonly perms.
So I wanted to give the DB user ReadWrite... but I don't want anyone to be able to remove a movie or tv episode from the library.
So, should I use a settings file to prevent that, or try to figure out which tables on the DB need to be protected?
Posts: 3,575
Joined: Mar 2011
Reputation:
194
Kiosk mode might be worth considering - I've not used it for years (probably on an xbox last time!) but IIRC it takes away options to change things via the context menu / sidebar.
Posts: 115
Joined: Feb 2009
Reputation:
0
Wait, I think I figured it out... looks like when I setup a new profile, I can set delete/mdifying to be disabled. That should solve this, I think.
Posts: 31,445
Joined: Jan 2011
(2016-04-26, 23:29)john_es Wrote: Wait, I think I figured it out... looks like when I setup a new profile, I can set delete/mdifying to be disabled. That should solve this, I think.
Not quite. That only works when you are using the default, local SQLite database. Profiles will require advancedsettings.xml files, so they will be accessing the database the same as any other profile.
Posts: 1,250
Joined: Aug 2007
Reputation:
11
I've got 7 systems running Kodi. 4 of those systems are used by my kids and I didn't want them doing any deletions or updates to the db, setting items as watched, etc. So here's what I do....
All systems have an advancedsettings.xml pointing to the MySQL databases
There are 2 different users in MySQL - xbmc & xbmc2
xbmc has full rights and is the user set in the advancedsettings.xml on the systems I use.
xbmc2 has limited rights in MySQL and is the user set in the advancedsettings.xml on the kids systems
The rights set for xbmc2 in MySQL are only SELECT and CREATE TEMPORARY TABLES
Hope this helps.
Posts: 31,445
Joined: Jan 2011
I believe Kodi will still prompt for removal if it didn't find a file, though. Profiles can still be used to remove/limit various things, though. I would still go with what Aenima99x suggests (or both).