Library compiling is a joke..?!

Hi all I’ve just added 6 standard definition avi tv episodes to my box and the media library recompile is currently at 18 mins and still going strong… Does it really need to do this every single time I add content or have I got a setting wrong?

Still going 2 hours later… I notice out gives me the option to use fonder only view while it is building the library. I only use folder view anyway so is there any way to disable the library build?

Yeah, you can turn Media Library off in the setup menu.

Excellent news what exactly does having it on give you?

if you have valid xml’s for everything

it gives you a lot of content sorting options

It also appears to enable the favourites feature which I love… Shame as I would like folder view but with the favourites option!

It really is a joke.  I have software from the late 1990’s that did a better job of keeping track of newly added files.  I currently have media monkey scan my media folder on my PC for any new additions and it adds the new ones I put in the folder nearly instantaneously without any prompting, resetting or cycling the power.

WD did make an update in 2012 to add a re-scan feature for the media library, but unfortunately the design they implemented re-scans the whole hard drive, rather than just watching for changes to select folders.  This means every time you make a change to the files on the device (add, delete, rename, etc), it’ll re-scan and recompile the media library from scratch instead of ONLY THE CHANGES.  I love every feature of my Hub except for this.  Once WD fixes this, I’ll look into buying more hubs and other devices to stream content within my house. 

airider wrote:

  This means every time you make a change to the files on the device (add, delete, rename, etc), it’ll re-scan and recompile the media library from scratch instead of ONLY THE CHANGES.

That’s incorrect.   A rescan only rescans the folder you choose.  I use the feature quite often.   Rescanning the whole library takes mine about 30 seconds.   Rescanning a select folder only takes about 5-6 seconds.

I get similar results, using Samba shares with around 500 movies and TV shows:  ~30 secs to clear Media Library and have it “rebuilt” and mere seconds to rescan the movies directory, etc.  Heck, I even deleted the .cas files at one point (since I couldn’t get the SMP to quit showing an old icon) and had it recreate those files.  Still <1minute.

Under a minute?  Wow, I wish mine performed like that.  Even if there’s been no changes at all, it will say media compiling for at least 10 minutes after I turn the device on.   The last time I cleared the media library and had it rebuild from scratch it took several hours and that was probably the best it’s ever done.  I’m using a gigabit ethernet connection between the wdtv and the media servers, so I doubt it’s a network issue.

I have about six different Samba shares.   I while back I had posted how I think the uniondb.cas file is a big part of the slowdown.  Everytime you restart the WDTV and it reconnects the drives it ‘randomly’ picks one of the shares to be the site for the uniondb.cas file.   If that’s different then the last time then it goes through the process of making a new one.  It seems to do that as it steps through each media file, versus doing it all once at the end of media compiling.

Even if it doesn’t have to rebuild the uniondb.cas file it still goes through the process of checking each of the wdtv.cas2 files and the uniondb.cas file.   Basically my guess is the more shares you have the slower it’s going to be.

One thing that seems to help is plugging a drive into the WDTV.  If there’s a drive plugged into it then that will almost always be the location of the uniondb.cas file.

I have had two devices (first, and RMA) The library only worked once, each. Upon a crash/hang, the media scanning is broken. This is no matter how I clean my HDD of the metadata…

impdust wrote:

Under a minute?  Wow, I wish mine performed like that.  Even if there’s been no changes at all, it will say media compiling for at least 10 minutes after I turn the device on.   The last time I cleared the media library and had it rebuild from scratch it took several hours and that was probably the best it’s ever done.  I’m using a gigabit ethernet connection between the wdtv and the media servers, so I doubt it’s a network issue.

 

I have about six different Samba shares…

 

Are you using Samba running on a Linux server?  Or are you actually using an NAS, with some potentially modified (and hence buggy) version of Samba, and a low power CPU?  I am using Samba running on a Linux server.  Since my two SMPs both spend <30secs from boot recompiling the Media Library, I cannot believe yours should be taking so long if the shares are on a Linux server.

As for your problems with the cas files moving around, well let me explain my setup, since I don’t have that issue:  I have two 3 TB external drives that are shares Videos1 and Videos2, but I didn’t want the SMPs (or any device) writing onto those drives, since they represent a great deal of work on my part, so they are read only.  I created a third, relatively small share, Videos, using spare space on an internal drive on the server.  Videos effectively merges the Videos1 and Videos2 shares, plus gives the SMPs a place to write their ML info.  The trick is that the actual video files from Videos1 and Videos2 are represented by symlinks in Videos, with Samba set to follow symlinks.  Works great.

Oh, yeah, just updated firmware on my two SMPs, and definitely under 30 secs each recompiling their MLs after the final reboots.  5 TB of videos (~ 500 movies and TV shows).  Perhaps you should try changing your share configuration?

Ahhh…so my experience apparently doesn’t happen and I’m a liar and the hours spent waiting for the media library to compile doesn’t happen…

Helps if I type accurate info.  They’re actually Window Shares.  Spread between two computers.  The size of the shares range between 3 and 10TB.  They’re on two computers.  One with a i5-2500k processor and the other is an Core Two Duo E8400, both with 16GB of Memory and Sata Drives.   So I don’t think the problem is on the ‘servers’.

I also have an G850 based XBMC system that has no problem scanning the entire media library in about a minute.

I had previously thought about using your solution to reduce the number of cas files being created, but that would merge all my media together.  I actually like having the different types of media files seperated into different shares.

I fully understand that my choice to have six shares contributes to the slowdown, however I think there’s optimizations to the media library process that WD could do that would significantly improve performance for those with multiple shares.

impdust wrote:

Helps if I type accurate info.  They’re actually Window Shares.  Spread between two computers.  The size of the shares range between 3 and 10TB.  They’re on two computers.  One with a i5-2500k processor and the other is an Core Two Duo E8400, both with 16GB of Memory and Sata Drives.   So I don’t think the problem is on the ‘servers’.

 

I also have an G850 based XBMC system that has no problem scanning the entire media library in about a minute.

 

 

Just remember that Microsoft is free to change their file sharing protocol at will, and Linux-based boxes like the WD TV units will then be forced to try to adapt, eventually.  For example, are you aware that Windows 8 introduced a new version of the file sharing protocol, which MS is now calling SMB 3.0?  MS has been more forthcoming with Samba/Linux devs since the EU forced them to disclose SMB details, but there most certainly could be incompatibilities between your particular Windows server software and the WD TV boxes implementation of the protocols.  Whether you choose to blame this on WD or on MS probably depends on your use of MS products.  Since my SMPs compile so quickly with shares on a true Linux-based Samba server, I do not see how incompabilities in file sharing protocols between the WD TV units and your version of Windows can be ruled out.

impdust wrote:

I had previously thought about using your solution to reduce the number of cas files being created, but that would merge all my media together.  I actually like having the different types of media files seperated into different shares.

 

I fully understand that my choice to have six shares contributes to the slowdown, however I think there’s optimizations to the media library process that WD could do that would significantly improve performance for those with multiple shares.

 

 

I haven’t merged any of my media types together.  The single share, Videos, has several top-level directories, including Movies and TV.  All the movies from the true shares get linked into Videos/Movies, instead of them being spread over Videos1 and Videos2 shares–but movies are still separate from TV shows (and other video categories I use).

If recompiling the Media Library took 10 minutes after rebooting an SMP, I would be unwilling to use the ML.  So if I wanted the features that ML provides on the SMPs, I would explore alternatives that I myself could implement that might fix the time problem–instead of sitting around and hoping WD will fix it (when it isn’t clear what is causing the problem for certain users).