Hacking Windows 7 Media Center

Speeding up Media Browser using a Flash Drive

by Michael Healy @ 9:15 am on August 31st, 2009 in media browser with 52 Comments

gnome-dev-flashkey Much of the data retrieved by Media Browser is stored on the hard drive and needs to be retrieved frequently as you browse through your movie collection. Information such as movie metadata and covers is constantly being loaded up as you browse through your movie folders. This data retrieval process leads to some extremely slow performance in large collections and it doesn’t get much more frustrating than knowing what movie you want to watch and taking forever to get to the right listing so you can play it. Luckily, there is something we can do about it.

The idea comes from Washy on the Media Browser forums and is much like our previous guides on speeding up the Live TV buffer using a RamDisk or using a flash drive. For this guide we’re going the flash drive route because the amount of data we’re working with is somewhat prohibitive in regard to using a RAMDisk. It would require quite a bit of spare RAM to operate the disk for Media Browser’s data but using a fairly inexpensive flash disk like the Patriot Xporter XT Boost 4GB Flash Drive can really speed up access times when browsing through your library without spending much money.

Once you’ve got your flash drive ready setting up Media Browser to use it instead of the default location is fairly simple. First open up Windows Explorer and navigate to the location of the cache and settings, typically found at C:\ProgramData\Media Browser. Note that the Program Data folder is typically hidden and you will need to either have hidden folders enabled or type C:\ProgramData into the navigation bar at the top.

media browser folder

Once you’ve located the MediaBrowser Folder inside ProgramData folder you can cut the folder (or copy then delete) to your flash disk. This will create your MediaBrowser cache as it was on your hard drive except on it’s own flash drive increasing read and write speed drastically. Now you should have a MediaBrowser folder on your flash disk and the folder inside ProgramData should be gone.

Next we’ll need to create a symbolic link from the original location to the new location. This will tell MediaBrowser to use our new cache location instead of the old one. The process is fairly simple for this step as well.

mklink

Open a command prompt (start –> “cmd” –> enter) and change to your ProgramData directory by entering “cd C:\ProgramData”. Next create a directory junction by entering “mklink /j MediaBrowser X:\MediaBrowser”. Making sure to change X:\ to the location of your flash disk.

That’s all there is to it! Simple, easy and effective. Now all that reading and writing typically taking place on your hard disk is instead being done from the much faster and more efficient flash disk. You should notice the speed improvement immediately inside Media Browser when browsing your collection. Large collections especially should see a drastic improvement in performance.

Have a Twitter account? Get notified of the latest posts here at Hack7MC directly to your Twitter feed by following our special Hack7MC Twitter stream.

52 Comments


WinduSux
Comment #2992 from WinduSux [Reply]

I know you linked to the 4GB model, but can you provide any data regarding recommended flash drive sizes for large collections? I have a 256 MB flash drive I don’t use anymore and am wondering if it would be large enough. I guess I can just check the size of the Media Browser program data when I get home.

Comment left August 31, 2009 at 4:02 pm Permanent Link
@Reply #2996 from Michael Healy [Reply]

It would depend quite a bit on the size of your library and the cache directory. Larger libraries will need more space to store the cover art and metadata. I’m not 100% sure how many movies I’ve got off hand, around 200 I believe and the cache is in the 2.5gb range so 256mb could be somewhat small but it will vary with library size.

Comment left August 31, 2009 at 5:10 pm Permanent Link

Mike
Comment #2993 from Mike [Reply]

I have a 4gig ram drive dedicated to my MediaBrowser Cache and it works like a charm!

Comment left August 31, 2009 at 4:20 pm Permanent Link

Dravor
Comment #2994 from Dravor [Reply]

Why not just put the cache on a network drive? Preferably one not used for your content? This would work extremely well if you are using multiple clients with MediaBrowser?

Comment left August 31, 2009 at 4:35 pm Permanent Link
@Reply #2995 from Michael Healy [Reply]

Though this would centralize your cache files it would also have the opposite effect on speed adding network latency on top of the networked hard disks own latency.

Comment left August 31, 2009 at 5:04 pm Permanent Link

Vassilis
@Reply #3056 from Vassilis [Reply]

also, you cannot use the mklink to make junctions to a network drive…it only works on local disks.
You must use a different program that can make network junctions

Comment left September 3, 2009 at 7:38 am Permanent Link

user29
Comment #2997 from user29 [Reply]

hmm

Does windows 7 have the same issues that Vista has – that when you go to S3 and come back out it either a)

doesnt recognise the drive or
b
Rebuilds the entire cache

if it does the same behaviour then it is not too usefull for mediabrowser
though obviously great for live tv as that is a “once off”

I believe the people over at MB are working on their caching engine which is a better solution.

However it would be great to understand if the USB out of S3 works fine in W7

Comment left August 31, 2009 at 10:24 pm Permanent Link
@Reply #3006 from Michael Healy [Reply]

I haven’t had any issues on my main machine with S3 sleep though I don’t use S3 sleep on my Media Center machine so I can’t say whether the issue still exists there or not in Windows 7.

Comment left September 1, 2009 at 9:00 am Permanent Link

jkelly
Comment #2999 from jkelly [Reply]

Is there a way you can do this for the Media Center Movies Library – I like Media Browser but find that it causes my Windows media center to perform very sluggishly and at times stop resonding all together unless I restart. So I am using the Movies Library with Metabrowser – but now at 223 movies, browsing the movied in the Movie Library is becoming slow and jiterry to scroll through the movies. I initially though I would be able to build a 1,000+ movie library – but now see I will have to make adjustments. First, it is impossible for the xbox extender to even load the movie library – it hangs – so I have to put movies I want to watch into a video folder for the videos section – it would be nice for the movies library to have folders – that way I could break up each drive into its own folder – Media Broswer has this which is nice but again it makes my media center unstable – also I cannot load media browser on my xbox extender for some reason –

Does anyone else have stability probelms with media browser?

Comment left August 31, 2009 at 11:36 pm Permanent Link
@Reply #3007 from Michael Healy [Reply]

I haven’t tried it myself but the cache files for the native Movie Library are located in C:\Users\YourUsername\AppData\Roaming\Microsoft\eHome. In theory you should be able to use the same process as above. If you do try it out let me know how well it works for you!

Comment left September 1, 2009 at 9:06 am Permanent Link

Staba
Comment #3004 from Staba [Reply]

Can someone explain to me how this would speed up your system in anyway? The suggested USB stick as a max read speed of 32MB/s (and thats even in theory). My harddrive does 60MB/s easy. So how could this do anything but slow my system down even more?

Comment left September 1, 2009 at 7:06 am Permanent Link
@Reply #3005 from Michael Healy [Reply]

The performance improvement comes from the fact that we’re using flash memory to load a large number of small files as opposed to a few large files in which your hard disk would in fact out-perform the flash media. Using a USB flash drive for accessing cache data such as that used in Media Browser will actually result in increased transfer speeds, especially when you consider hard drive access being performed by other programs in the background on your main hard disk.

In fact, this is the same theory that is applied to Windows ReadyBoost.

Comment left September 1, 2009 at 7:53 am Permanent Link
Comment #3061 from neiltoe [Reply]

I do this with the Movie and Music Libraries. I have all my extenders and user accounts connected to a 5gb partition I made on my local disk. I have a limited amount of storage since I use an SSD as my drive. Each account makes approximately 1gb or more cache files on my PC so putting them all into that partition they all share the same cache. The only thing I can’t share is my db files. Also by doing this I can get all my high quality album art done in one run.

Comment left September 3, 2009 at 9:14 am Permanent Link

fourthletter
Comment #3067 from fourthletter [Reply]

I have a movie collection of nearly 300 with an extensive TV collection as well (I use Diamond)
Yet my cache is only 360MB in size any rhyme or reason to the size or am I ok to use my 1GB USB key for this ?

Comment left September 3, 2009 at 4:51 pm Permanent Link

ADavis
Comment #3072 from ADavis [Reply]

I have a movie collection of over 700 movies, my mediabrowser cache folder is almost 3gigs, I’ve made the changes stated but I’m not seeing an increase in the speed, it honestly appears to load mediabrowser slower as well as loading my backdrop images and dvd cover images slower. Is it possible that I’m not benefiting because my collection is so large?

Comment left September 3, 2009 at 9:44 pm Permanent Link
@Reply #3073 from Michael Healy [Reply]

I could understand it loading slower say if you are loading the majority of the 3gig cache at once since sustained load would be slower but seeking and loading single images and small portions of the data should be significantly faster when utilizing solid state storage.

Comment left September 3, 2009 at 9:58 pm Permanent Link

ADavis
@Reply #3084 from ADavis [Reply]

OK, is there another way to set it to load single images and smaller portions of data to make it faster?

Comment left September 4, 2009 at 9:16 am Permanent Link

fourthletter
@Reply #3115 from fourthletter [Reply]

Does your USB key qualify as fast enough for ReadyBoost ? If it doesn’t it probably isn’t any faster than a HDD and might be a bit slower.

Comment left September 5, 2009 at 12:52 pm Permanent Link

fourthletter
Comment #3116 from fourthletter [Reply]

It’s also maybe worth deleting your movie browser cache, point it at the USB key then once it’s rebuilt it should be faster.

Comment left September 5, 2009 at 12:53 pm Permanent Link

fourthletter
Comment #3117 from fourthletter [Reply]

Thank you for this Michael it’s made my Media Browser alot snappier.
On a slightly different note, I recently changed my setup from a 7600GS graphics card to intergrated 7100 (both Nvidia) I notice the animation is alot choppier now, is Media Browser’s interface excellerated by a graphics card ?

Comment left September 5, 2009 at 12:55 pm Permanent Link

Sangster
Comment #3128 from Sangster [Reply]

I’m using Windows 7 RTM and there is no Media Browser Directory in ProgramData. I have enabled the option to be able to see hidden files. I can see ProgramData but nothining in it called Media Browers. Is this trick only for Vista?

Comment left September 6, 2009 at 7:45 pm Permanent Link
@Reply #3131 from Michael Healy [Reply]

Nope, this should work in both Vista and Windows 7 as long as you’ve got the Media Browser movie library plugin installed.

Comment left September 6, 2009 at 10:02 pm Permanent Link

Sangster
Comment #3143 from Sangster [Reply]

Oh, Ok. I thought this was for speeding up the native Music and Video Libraries. I have over 1000 CDs and the Music Library is sluggish. Wondering if I can relocate the CurrentDatabase_xxx.wmdb file to flash drive using this method to speed up the Music Library

Comment left September 7, 2009 at 3:13 pm Permanent Link
@Reply #3151 from Michael Healy [Reply]

You can use the same process to speed up the music library’s art cache which is located in “C:\Users\USERNAME\AppData\Microsoft\ehome\Art Cache”. Just move the cache folder over to your usb and create and mklink to the new folder. I don’t think moving the database itself would be an improvement in speed since it’s a single large file as opposed to many small files.

Comment left September 8, 2009 at 9:59 am Permanent Link

Jeansy
Comment #3171 from Jeansy [Reply]

Didn’t work for me. I spent $70 on a Corsair voyager GT Flash drive & it now takes forever to load my library of about 400 movies. Some don’t load at all where as they used to when stored on C: drive

Comment left September 10, 2009 at 2:07 am Permanent Link

Jeansy
Comment #3173 from Jeansy [Reply]

I found it alot quicker to partition my velociraptor boot drive and load the cache from there. It is almost instant to load whereas my corsair voyager gt flash drive took at least 15 sec to fully load. It was worth a try. Thanks anyway.

Comment left September 10, 2009 at 5:02 am Permanent Link

John Bones
Comment #3199 from John Bones [Reply]

I’m another that found this did not work for my situation. I’m running my operating system off an SSD drive and there’s no comparison.

Thanks for the idea it was worth a try.

Comment left September 11, 2009 at 2:04 pm Permanent Link
Comment #3200 from Bear64 [Reply]

I can’t wait for eSata flash sticks to become more common place (http://www.techreport.com/discussions.x/17568),

Moving all the media center caches to one of these should smoke!

Comment left September 11, 2009 at 2:38 pm Permanent Link

Oliver Phillips
Comment #3234 from Oliver Phillips [Reply]

Hi,

I have a number of hard drives installed in my PC. If I used the same process you have described here, but instead moved the cache to one of my lesser used hard drives do you think I would experience any noticible difference?

Thanks, Oli

Comment left September 14, 2009 at 9:36 am Permanent Link
@Reply #3235 from Michael Healy [Reply]

Certainly, moving the cache to a drive with fewer programs accessing it simultaneously is sure to have an impact on the performance.

Comment left September 14, 2009 at 10:09 am Permanent Link

SpiggyTopes
Comment #3238 from SpiggyTopes [Reply]

Hi,

How can I undo the mlink junction?

I’d like to revert to loading from the hard drive.

Cheers

Comment left September 14, 2009 at 11:21 am Permanent Link
@Reply #3245 from Michael Healy [Reply]

Open up the folder in Windows Explorer and just delete mklink junction which should appear similar to a folder shortcut icon.

Comment left September 14, 2009 at 8:50 pm Permanent Link

SpiggyTopes
Comment #3262 from SpiggyTopes [Reply]

Many thanks and also for the tips.

I’ll revert to the hard disk and see if it is slower than the mem stick.

Comment left September 15, 2009 at 7:31 am Permanent Link

Anonymous
Comment #3808 from Anonymous [Reply]

Hey guy, I got a little question before I do this.
MB did not find pics for some of my movies, even with metabrowser, so I had to save them to the movie folder as “folder” and “backdrop”. Is there a way to save those to cache?Hmmm

Comment left October 5, 2009 at 2:45 pm Permanent Link

Tester
Comment #4156 from Tester [Reply]

I tried this tweak and have not seen any improvement with MediaBrowser, not that it was slow to begin with.
For a cache I used both a 2gig stick and a laptop 60gig drive. I also tried it with a few other programs such as WMP. It does seems smoother at times, but it is hard to notice.
Where exactly during the MediaBrowser operation should I see an improvement ?

Comment left October 22, 2009 at 10:32 am Permanent Link

nelcruz
Comment #4232 from nelcruz [Reply]

does this work with Mediabrowser 2.1.3.0Win 7?

Comment left October 25, 2009 at 10:38 pm Permanent Link

ncarty97
Comment #4690 from ncarty97 [Reply]

Quick question. Does this mklink command make it permanent or does it need to be executed every time you boot the computer?

Comment left November 9, 2009 at 11:06 pm Permanent Link

CBers
Comment #4780 from CBers [Reply]

What is it that is held in the MB cache folder ??

The folder/jpgs and backfrop.jpgs are held in the movie/tv folder and not in ProgramData, and as my movie/tv folder are on a NAS device, I’m not sure this tip would make any difference.

Would it ??

Comment left November 13, 2009 at 6:48 am Permanent Link
@Reply #4786 from Michael Healy [Reply]

Actually, MediaBrowser makes copies of the backdrop and folder images and stores them in a central location on each local machine to cut down on load time under ProgramData/ImageCache by default. Have you checked your folder to see if there is a cache stored there? This is the default behavior on each of my machines when loading from the local machine or over the network.

Comment left November 13, 2009 at 11:05 am Permanent Link
Comment #4849 from CBers [Reply]

Yes, I have a ProgramData\Cache with Cache, ImageCache and ImagesByName sub-solders. Is this what you mean ??

Comment left November 15, 2009 at 5:10 pm Permanent Link

jules
Comment #5184 from jules [Reply]

This didn’t improve speed for me at all despite using a decent flash drive… how do you undo this? I want to load from my hard drive again.

Thanks

Comment left November 29, 2009 at 3:51 pm Permanent Link
@Reply #5192 from Michael Healy [Reply]

Delete the folder shortcut created by the mklink program then copy the original data back to the original location.

Comment left November 29, 2009 at 11:12 pm Permanent Link
Comment #5502 from Calan [Reply]

I didn’t like the idea of having my cache “vulnerable” if my USB stick got pulled out. Also, my USB stick has an orange activity light that would probably get annoying when watching things in the dark.

I instead opted to move my cache from my OS/pagefile drive to my RAID5 array. I know that many users will not have a HTPC with a RAID array in it. I am actually planning to make this computer (or its RAID at least) into a server and build a HTPC with an SSD, so I’m largely testing Win7 MC to see if it will do everything I want it to do (in previous experience, things won’t be a complete solution – right now my only problem is subtitles though). For now, though, the I’m noticing the slowdowns with only a couple hundred movies (a 600mb MediaBrowser folder).

So I copied the cache to my RAID5 and defragmented. I just opened up media center now, and library validation took 18 seconds – usually takes about 5. I guess that makes sense because of the nature of RAID5.

Anyway, for anyone wanting to go down that road, I’d say don’t. Flash drive is probably a better way to go, or frequently-defragmented partition on your harddrive.

Comment left December 9, 2009 at 1:25 am Permanent Link

Brian Barry
Comment #5782 from Brian Barry [Reply]

I tried this and it actually made the program much slower… I’ve no idea why, on a 2GB flash drive Media Browser was using around 835MB of data, so it wasn’t a case of it being filled and choking because of it. So, I have no idea why.

It’s a shame because it’s quite slow enough as it is.

Comment left December 17, 2009 at 3:19 pm Permanent Link

Brian
Comment #6081 from Brian [Reply]

I just posted this on the Live TV Buffer tip but I’d also like to try this out. Can this be done with a SD CARD instead of a USB thumb drive? I have a reader built in on my computer that doesn’t get used. It would be nice to stick a card in and forget about it.

Comment left December 28, 2009 at 12:22 pm Permanent Link

Attiska
Comment #6414 from Attiska [Reply]

What do you think about to use a small (like 160GB) notebook sata drive-as cheap as an 8gb pendrive…

Comment left January 7, 2010 at 5:20 pm Permanent Link

Amish
Comment #8027 from Amish [Reply]

I found it to be much faster as long as you dont use back drops. when u turn on backdrops it slowed down.

Comment left February 24, 2010 at 1:39 am Permanent Link

SBM
Comment #10836 from SBM [Reply]

Does this also work using Media Browser on a Xbox 360? Or does the Xbox create its own cache?

Comment left May 10, 2010 at 10:02 am Permanent Link
@Reply #10846 from Michael Healy [Reply]

I don’t think the Xbox Creates it’s own cache but I’m not sure how much this will speed it up either considering it’s got the network to traverse as well.

Comment left May 10, 2010 at 2:18 pm Permanent Link

Anonymous
Comment #13337 from Anonymous [Reply]

tried this with the drive you listed. Made mine work much slower

Comment left June 29, 2010 at 9:40 am Permanent Link

Stephen Fisher
Comment #13866 from Stephen Fisher [Reply]

I use the RamDisk software from Qsoft and just have the imagecache folder on the ramdrive and the images load in less than a second, I’m going to transfer the playstate files to the ramdrive too as loading them is what is slowing mediabrowser down now *tut*

Brilliant tip though, saved my media browser a few minutes of loading time :)

Comment left July 18, 2010 at 8:21 am Permanent Link

Leave A Comment

Post Anonymously, Fill in your details or Use one of the Social Networks below to login and post a comment!