Home
Blogs
Forums
Files


Welcome to The Green Button          Sign in | Join | Help

My Music Slow Performance Issue SOLVED!

Last post 01-06-2008, 10:04 AM by somaamos. 29 replies.
Page 1 of 2 (30 items)   1 2 Next >
Sort Posts: Previous Next
  •  02-12-2005, 12:28 PM 32314

    My Music Slow Performance Issue SOLVED!

    OK Guys- I've figured out a way to increase the "MY Music" Performance Issue for large libraries.  I have about 25,000 WMA Lossless songs loaded on an external (Firewire) terabyte drive.  Before implementing the following approach, it could take up to 2 minutes to load an artist's albums, or do a search for a song (sometimes it never came back).  I have that down to less than 5 Seconds NOW!!!!  I am only going to outline the approach, and what I did, but it can be accomplished with other similar methods.  NOTE:  This is not for the faint of heart!

    The basic concept is:  Keep the Music catalog persistent in memory.

    I basically realized that MCE was encountering performance issues with the music catalog used by Windows Media Player 10.  The catalog is stored in the directory "C:\Documents and Settings\<username>\Local Settings\Application Data\Microsoft\Media Player. The file name is CurrentDatabase_219.wmdb.

    All I had to do was keep it in memory (easier said than done).

    1) I Created a RAMDISK (I used the Software Ramdisk Plus by Superspeed (www.superspeed.com).  Note: Whatever RAMDISK software/drive you use must support NTFS.  Also your hard drive must be an NTFS volume not a FAT32.  The Ramdisk has to be at larger than the size of the CurrentDatabase_219.wmdb file.  My file size was 150mb, so I made my RAMDISK 300M.

    2) I couldn't find a way in the registry or thru Media player 10 options to change the default location of the library database, so I could point it to my new RAMDRIVE.  Instead, I had to create the equivalent of a UNIX symbolic link (A directory which actually points to another drive).  There is a little known command in windows called JUNCTION.exe.  This accomplishes the same thing a symbolic link.  I've read you have to be very careful in how you use and setup junctions (I guess that’s why Bill doesn't make it very well know).  I used some shareware called Junction Link Magic (http://www.rekenwonder.com/linkmagic.htm) to setup my link.  You can also do it thru command line, but it’s a real pain.

    3) Now I created the Link.  I made a backup of  the Directory C:\Documents and Settings\<username>\Local Settings\Application Data\Microsoft\Media Player first.  I then made a junction between C:\Documents and Settings\<username>\Local Settings\Application Data\Microsoft\Media Player and another directory I created on my RAMDISK.

    4) I then copied everything from my backup directory to C:\Documents and Settings\<username>\Local Settings\Application Data\Microsoft\Media Player.  Note:  The C:\Documents and Settings\<username>\Local Settings\Application Data\Microsoft\Media Player directory is actually  a Junction to a directory on my RAMDISK.  The database is now stored in memory!

    5) If you Run the media center and go to "My Music" you notice a phenomenal increase in performance!!!!!!!!!

    Other NOTES:

    Remember, your Library database is now stored in memory (RAMDISK).  This means every time your Media Center is turned of or loses power, you lose your music database.  Depending on the RAMDRIVE software you use, this may or may not be an issue.  The RAMDisk plus software I use automatically writes your RAMDISK to your hard drive on Shutdown, and Restores your RAMDrive on boot up.  This way you won’t have to rebuild your database or worry about losing it.  However, if your PC crashes, you will lose your library.  Just make sure to make backups.  If a crash occurs, just copy from your backup directory, or rebuild the database.

    If anyone else can figure out an easier way of keeping the music persistant in memory, pls post.

    Good Luck all

  •  02-12-2005, 2:07 PM 32328 in reply to 32314

    • AndyC is not online. Last active: 11-19-2008, 1:04 PM AndyC
    • Top 10 Contributor
    • Joined on 03-29-2004
    • UK
    • Elite Member

    RE: My Music Slow Performance Issue SOLVED!

    Well done!  I know that Thomas Hawk will be very happy!

    I just need to buy another 22,000 tracks now.

    Cheers,
    Andy

  •  02-13-2005, 1:20 AM 32405 in reply to 32314

    RE: My Music Slow Performance Issue SOLVED!

    Good thinking there! That is a great idea.

    However, people aren't going to be able to gain the speed benefit when trying to access "My Music" from extenders because each extender uses a separate user account on the MCE machine. Unless you set up multiple RAM disks (a major waste of RAM and PITA to set up) then the extenders will store their WMP databases on the hard drive. It is possible to set up more than one junction point to the same disk, so theoretically you could set a junction point to the one RAM disk under each user's profile folder, but I shudder to think what would happen if they each tried to access the WMP database simultaneously. Has anyone ever tried this or would some brave soul like to try? If it works it would also be a possible solution for the people who actually use multiple user accounts on their MCE machine and hate having to manually copy the WMP library to each user account so they're all the same.

    What MS REALLY needs to do in the next version of WMP (besides indexing the WMP library for faster disk access):

    1. Allow each user the option to use a shared WMP library or use its own.
    2. Allow you to store said libraries anywhere you wish on the disk(s) or over shared network drives.

    It sucks that you have to use a junction point just to be able to put your WMP library on a different disk than the user profiles. There's no reason you shouldn't be able to put it anywhere you want.

    If you have a whole disk to devote to your WMP library (as in this RAM disk (Have you tried using a USB 2.0 flash drive? Would it be any faster than the HDD?), you can use Mount Points instead of junctions. Mount Points can be set up using the Disk Management snap-in built into Windows. Just right-click on My Computer and choose "Manage". Then go to Disk Management and find your RAM disk (I assume it shows up here, right?). Then just right click the RAM disk and choose "Change Drive Letters and Paths". Click the Add button and under the option "Mount in the following empty NTFS folder:" type in the path to the folder where MS keeps its WMP library (though you have to empty the folder of all of its contents first). Hit OK and voila. Then you can copy the library back over (or allow WMP to create a new one next time you load it).

    Anyway, thanks for sharing your solution... it certainly opens the door to some good possibilities!

    Dan
  •  02-13-2005, 3:12 AM 32410 in reply to 32314

    • AndyC is not online. Last active: 11-19-2008, 1:04 PM AndyC
    • Top 10 Contributor
    • Joined on 03-29-2004
    • UK
    • Elite Member

    RE: My Music Slow Performance Issue SOLVED!

    Presumably where the database is stored is a feature of the default profile - couldn't you modify the default profile so that all users shared the same database?

    Cheers,
    Andy

  •  02-13-2005, 11:05 AM 32450 in reply to 32314

    RE: My Music Slow Performance Issue SOLVED!

    Andy,

    Interesting... do you know where to edit the path then for the default profile? I assume you mean the path is stored in a registry key or something. If that is the case, then yes it's possible to change that path, and have it affect the creation of all future users (won't affect already-created users though).

    I wasn't aware that the path to the WMP library existed in the registry. I figured WMP was hard-coded to look for it in [Username]\Local Settings\Application Data\Microsoft\Media Player.


    Dan
  •  02-13-2005, 11:37 AM 32458 in reply to 32314

    RE: My Music Slow Performance Issue SOLVED!

    This is great information.  I have also been dealing with the 'slowness' of the My Music function.

     

    FYI:  Don't bother trying to use a USB flash disc to store the database.  The issue here is speed of access.  A USB flash drive is many times slower than a hard drive, so you'd actually experience much worse performance.  The ramdisk concept works because RAM is the fastest available storage in a computer.

     


    HP M1070n Media Center PC

    • 1GB PC3200 RAM
    • 160GB SATA HD - OS and Audio Storage
    • 2.5TB HD array - Video and DVD ISO Storage
    • x600Pro 256MB PCI Express Video
    • 2x ATI Analog Tuners
    • 1x ATI HDTV Wonder Tuner
    • Linksys Media Extender
    • Xbox Media Extender
  •  02-13-2005, 11:58 AM 32465 in reply to 32314

    RE: My Music Slow Performance Issue SOLVED!

    One other setup I forgot to mention.  Make sure to turn off or set your virtual memory Page size to 0.  Otherwise, since windows treats your RAMDRIVE like any other harddrive, it may end up caching information on your hardrive, thus defeating the purpose of keeping the library in physical memory.  Needless to say this solution requires lots of memory.
  •  06-06-2005, 12:21 PM 53567 in reply to 32314

    RE: My Music Slow Performance Issue SOLVED!

    ok i did it but i dont know if the junction is working correctly i put in the junction point the ramm drive and in the destination the default wmp library

    please reply

    cm_mc
  •  06-06-2005, 11:13 PM 53653 in reply to 32314

    RE: My Music Slow Performance Issue SOLVED!

    Thanks for bumping the thread... I'd been meaning to post about this little bad boy set to debut this summer for $60.

    Gigabyte iRam:

    http://www.itworld.com/Comp/4063/050602boot/


    You can see some pics in this thread:

    http://www.tbreak.com/forums/showthread.php?t=28057

    Basically, it will create a RAMdisk for you, but the cool things are that it doesn't require you to use up your system memory for the task, doesn't depend on any (potentially buggy) third-party software, and best of all, a backup battery will keep its contents alive for hours if there's a power outage.

    The articles discuss the prospect of actually installing Windows on the thing... I'm not sure that's altogether wise, unless you keep religious backups on hard disk. A better use for us MCE'ers with huge music libraries would be to store all users WMP libraries on this thing. Even 512-1024MB of RAM should be plenty to hold everything. You'd still have to create the junction points manually, but everything should persist even if you have to take the system down for maintenance or Windows updates. I'll be eager to get my hands on one of these in July to test it out for this purpose. My music library is gigantic, and growing every day, so it would be really nice to be able to actually use the "My Music" section of MCE (it's worthless to me right now).

    Dan
  •  06-07-2005, 7:46 PM 53826 in reply to 32314

    RE: My Music Slow Performance Issue SOLVED!

    great !! i will buy one!!! but the my last post?? is it right? the junction??
  •  07-19-2005, 1:52 PM 61015 in reply to 32314

    RE: My Music Slow Performance Issue SOLVED!

    You can specify where the Library Database is stored.

    Open RegEdit and go to
    HKEY_CURRENT_USER\Software\Microsoft\MediaPlayer\Preferences

    Create a new String Value called "LibraryDatabasePath"

    Mine points to my RamDrive R:\

    It works fine with the local MCE machine. I have not tried the extender yet so I don't know if this affects it, but it may since the registry entry affects the CURRENT_USER.


    Vista Ultimate with TV Pack
    Core 2 Duo E4500 @ 2.2GHz (OC'd to 2.9) / 4 Gigs Ram
    c: 80 Gig d: 500 Gig SATA
    Tuners: PVR-500 / HDHomeRun x 2 / WinTV 1600
    Extenders: DMA-2200 / DMA-2100 x 2

    Linksys V1 extender (for sale..anyone interested?)
  •  07-19-2005, 11:51 PM 61088 in reply to 32314

    • AndyC is not online. Last active: 11-19-2008, 1:04 PM AndyC
    • Top 10 Contributor
    • Joined on 03-29-2004
    • UK
    • Elite Member

    RE: My Music Slow Performance Issue SOLVED!

    HKEY_CURRENT_USER references the user that is logged on in the session that you are using - you would need to make this mod on the MCX account for an extender.   I don't know what would happen if you had multiple users sharing a single database though.

    Dumb question, but what do you do when you shut the machine down?  Do you copy the database to permanent storage or do you have a RAMdrive card with battery backup?

    Cheers,
    Andy

  •  07-28-2005, 9:33 PM 62706 in reply to 32314

    RE: My Music Slow Performance Issue SOLVED!

    Does this database file also store the information for videos on MCE?  Or are movies done differently.  I have a lot of movies on my HTPC and it takes a long time to load that menu as well.

    Thanks

  •  07-28-2005, 11:52 PM 62720 in reply to 32314

    • AndyC is not online. Last active: 11-19-2008, 1:04 PM AndyC
    • Top 10 Contributor
    • Joined on 03-29-2004
    • UK
    • Elite Member

    RE: My Music Slow Performance Issue SOLVED!

    Just music.

    Cheers,
    Andy

  •  07-29-2005, 7:23 AM 62749 in reply to 32314

    RE: My Music Slow Performance Issue SOLVED!

    I created a couple of script that copies the database from the RAMDisk to the harddrive.

    The login script copies the files from the harddrive to my RAMDisk.
    The logoff script copies the files from the RAMDisk to my harddrive.

    I'm using the eval version of RAMDisk. To register it is only $9.
    The enterprise version is like $15.

    The enterprise version says it can copy contents from the RAMdisk to the harddrive and back on driver load and unload. I haven't tried it yet, but it's cheap enough to be a nice solution.

    I've been using it for about a week and it seems nice so far.
    Check it out and if you try the enterprise version, post your feedback.

    The software is based on a sample of RAMDisks provided by Microsoft.

    You can find it at.
    http://www.ramdisk.tk/
    Vista Ultimate with TV Pack
    Core 2 Duo E4500 @ 2.2GHz (OC'd to 2.9) / 4 Gigs Ram
    c: 80 Gig d: 500 Gig SATA
    Tuners: PVR-500 / HDHomeRun x 2 / WinTV 1600
    Extenders: DMA-2200 / DMA-2100 x 2

    Linksys V1 extender (for sale..anyone interested?)
Page 1 of 2 (30 items)   1 2 Next >
View as RSS news feed in XML
About TGB | Advertise | Link To Us | Donate | Terms Of Use | Privacy Policy
© 2003-2007 The Green Button, Inc. - All Rights Reserved