Solved Clean Library on Update
#1
Hi all!

Code:
<videolibrary>
<cleanonupdate>true</cleanonupdate>
</videolibrary>

Could this setting be made more robust? At the moment I have been informed that this can cause the whole Library DB to be wiped out, if connection to the Media NAS is incidentally down when library updates itself.

Normally, I would always want to securely remove media from the library that has been deleted from the Media Source.

Can I suggest for the Team to implement a pre-check to verify that the source connection is working and that some of the current files at the source are found? If this pre-check fails -> don't perform the cleanup.

If it is made secure like this, it can maybe become the default behaviour too for all library updates, and not an "advanced setting".
The Real Skimshady
Reply
#2
There's a good reason it's not in the GUI. How should XBMC know that the source is your NAS and that it is offline and not just a random network source that's not available any longer?
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not PM or e-mail Team-Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply
#3
vdrfan Wrote:There's a good reason it's not in the GUI. How should XBMC know that the source is your NAS and that it is offline and not just a random network source that's not available any longer?

An option to specify that the source can be offline at certain times when adding that certain source to the library would fit the bill.

That way XBMC will only wipe out that source path only if you remove your source totally from the video sources menu
Reply
#4
GreenEyez Wrote:An option to specify that the source can be offline at certain times when adding that certain source to the library would fit the bill.

That way XBMC will only wipe out that source path only if you remove your source totally from the video sources menu

Yes, cleaning without wiping is a much needed feature Smile Gets tiresome to clean manually!
The Real Skimshady
Reply
#5
Please file a new feature request ticket. Maybe we can address it after the upcoming Eden release.
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not PM or e-mail Team-Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply
#6
+1 for this request. @bthusby let me know if you need any help putting in the request ticket.
Image
thegamesdb.net - An open video games database.
scottbrant.net - Blog
Reply
#7
ghostelement Wrote:+1 for this request. @bthusby let me know if you need any help putting in the request ticket.

Yes, I have never made a ticket. Can you at least point me in the direction? Smile
The Real Skimshady
Reply
#8
bthusby Wrote:Yes, I have never made a ticket. Can you at least point me in the direction? Smile

Just go here and follow the directions. http://trac.xbmc.org/
Image
thegamesdb.net - An open video games database.
scottbrant.net - Blog
Reply
#9
Ticket #12597 Smile
The Real Skimshady
Reply
#10
I am hugely in favor of this request but would offer these suggestions:

1 - I agree that there should be an allowance for off-line sources (or perhaps even if more then 50% of the source is missing), and by default I would ignore off-line sources and not delete any data from the database if the source for the data is not accessible.

2 - In order to allow for off-line sources, add a GUI warning that states "the source <source name> is not available. Would you like to ignore this source during clean up or remove all entries in the database that reference this source? [Delete data] [Ignore Source]

2.1 - OR - In cases where a lot of data will change, i.e. more then 50% (or some other amount) of content will be removed from the database related to that source, give a similar warning:"A significant number of items are no longer found in the source <source name>. Would you still like to clean up this source, or ignore it this time? [Ignore this source] [Continue to clean this source]

3 - Possibly add an additional cleanup verification. At the end of the clean-up, show a list of all items that will be deleted from the library and a warning that lists all of the items to be removed. Give the option to either remove all or ignore all. Though this may be difficult to implement, a little confusing to users and is probably unnecessary if the above items are added.

And finally, because some people will love this and some people will hate it, add some advancedsettings.xml overrides:

Quote:<videolibrary>
<cleanonupdate>true</cleanonupdate>
<IgnoreBrokenSourceOnClean>{YES,no,ask}<IgnoreBrokenSourceOnClean>
<WarnOnLargeCleanup>{YES,no,ask}<WarnOnLargeCleanup>
<ShowItemsToClean>{YES,no}<ShowItemsToClean>
</videolibrary>
Reply
#11
Very good and relevant additions to my proposal Smile
The Real Skimshady
Reply
#12
I have last Eden (with mq3)

My movies are on a Qnap NAS and every time I want to delete one or two movies from it I can't use the clean library feature... because whole Library gets wiped out.

cleaning one by one it sucks...

So I need this too Smile

cheers
pjgm
Image
Reply
#13
should be able to do a scipt that will check if the NAS is connected, if it is then runs the clean command, if not, nothing
Reply
#14
A simple check for the source to be online before the clean function would fix this.
Reply
#15
zag2me, unless I'm missing something, that would be a great, simple fix.
...DJVege...
HTPC: G840 + GT430 + 2GB RAM + 30GB SSD
Remote: iPad/iPhone + iRule + USB-UIRT // FireFly RF Remote
Software: XBMC Eden + Eventghost + Win7
Reply

Logout Mark Read Team Forum Stats Members Help
Clean Library on Update1