Home of the Squeezebox™ & Transporter® network music players.
Results 1 to 9 of 9
  1. #1
    Senior Member
    Join Date
    Jan 2011
    Posts
    172

    Trackstat Technical Questions, moving to a new Computer system

    I am helping someone setup a new computer and I need to make sure all of his Music Libraries and TrackStat statistics move to the new machine.m So I have a few questions.

    1.) Where is the Actual statistics stored for TrackStat? IOW --- Are they imbedded in the actual songtracks?
    2.) Do I have to use the trackstat Backup and Restore procedures to move the statistics?
    3.) Where are the Tracstat backup files stored?

    Thanks in Advance!
    Last edited by Cut-Throat; 2012-07-06 at 11:33.

  2. #2
    Senior Member erland's Avatar
    Join Date
    Dec 2005
    Location
    Sweden
    Posts
    10,318
    Quote Originally Posted by Cut-Throat View Post
    I am helping someone setup a new computer and I need to make sure all of his Music Libraries and TrackStat statistics move to the new machine.m So I have a few questions.

    1.) Where is the Actual statistics stored for TrackStat? IOW --- Are they imbedded in the actual songtracks?
    2.) Do I have to use the trackstat Backup and Restore procedures to move the statistics?
    3.) Where are the Tracstat backup files stored?

    Thanks in Advance!
    1. It's stored in the SBS/LMS database, in track_statistics and track_history tables.
    2. Using backup/restore is the recomendted way, but if music files are stored on EXACTLY the same place on the new machine (same drive, same folder) it should theoretically work to copy the complete Cache directory (where the database is stored). You can find the location of the cache folder in SBS/LMS Settings/Information.
    3. Depends if the backup is done manually or if it's a scheduled backup:
    - Manual backups are stored in the file you have specified in "Backup/Restore/Clear" section of TrackStat settings page in the "Backup file" parameter
    - Scheduled backups (if enabled) are stored in the directory you have specified in the "Backup/Restore/Clear" section of TrackStat settings page in the "Backup dir" parameter

    Also, please note that if you move the music files to another location on the new machine, it's very important that the "Find alternative files" option is enabled in the "Backup/Restore/Clear" section of TrackStat. This option can make the restore process very slow, but it will be able to recover statistics even if the library has moved to a new drive or a new main directory. If the option is not enabled, the restore process will go a lot faster but it will not recover statistics for files which have been moved to another drive or another main directory.

    Of course, if you have musicbrainz tags in all your music files, TrackStat will recover the statistics independent of the above option.

    Two things to remember:
    1. When doing the restore, make sure you have done a rescan in SBS/LMS first and waited for it to finish.
    2. The restore operation is executed in the background, you will only see in the server.log when it's finished. If the "Find alternative files" option has been enabled and you have a really large library, the restore operation can take several days on some setups. In a smaller library, like my 4000 track library, it takes a few minutes maximum.

    The process of doing backup/restored is described on the following wiki page in the "Upgrade/Reinstall" section:
    http://wiki.slimdevices.com/index.php/TrackStat_plugin
    Erland Isaksson (My homepage)
    (Developer of many plugins/applets (both free and commercial).
    If you like to encourage future presence on this forum and/or third party plugin/applet development, consider purchasing some plugins)
    You may also want to try my Android apps Squeeze Display and RSS Photo Show
    Interested in the future of music streaming ? ickStream - A world of music at your fingertips.

  3. #3
    Senior Member
    Join Date
    Jan 2011
    Posts
    172
    Thanks for the reply!.......I have read about the backup and restore procedure. I have to make sure that those backup files get to the new computer, so that I can run the restore procedure. He has about 50K song tracks....I wonder how long this will take to restore?

    Scheduled backups (if enabled) are stored in the directory you have specified in the "Backup/Restore/Clear" section of TrackStat settings page in the "Backup dir" parameter
    Does this default to a location such as where your Music Library is stored or Playlist?......I don't think he set this up.
    Last edited by Cut-Throat; 2012-07-06 at 12:35.

  4. #4
    Senior Member erland's Avatar
    Join Date
    Dec 2005
    Location
    Sweden
    Posts
    10,318
    Quote Originally Posted by Cut-Throat View Post
    Thanks for the reply!.......I have read about the backup and restore procedure. I have to make sure that those backup files get to the new computer, so that I can run the restore procedure. He has about 50K song tracks....I wonder how long this will take to restore?
    Hard to say, but if you like to save time I would strongly recommend to try to keep the files on the same drive letter and main folder so you can run the restore with "Find alternative files" disabled. With "Find alternative files" disabled it should be fairly fast, can't say an exact time but I would be surprised if it took more than an hour, likely it will go a lot faster.
    If you need to run it with "Find alternative files" enabled it can probably take more than a day to do the restore, maybe even longer

    Quote Originally Posted by Cut-Throat View Post
    Does this default to a location such as where your Music Library is stored or Playlist?......I don't think he set this up.
    It's disabled by default, so in that case just do a manual backup as described on the wiki on the old computer. When doing the manual backup, remember that you need to specify the full path (not just the filename) in the "Backup file" parameter. The backup is usually pretty fast, it's the restore that can take a lot of time if "Find alternative files" are enabled.
    Erland Isaksson (My homepage)
    (Developer of many plugins/applets (both free and commercial).
    If you like to encourage future presence on this forum and/or third party plugin/applet development, consider purchasing some plugins)
    You may also want to try my Android apps Squeeze Display and RSS Photo Show
    Interested in the future of music streaming ? ickStream - A world of music at your fingertips.

  5. #5
    Senior Member
    Join Date
    Jan 2011
    Posts
    172
    OK, I just hooked up his old computer and looked at the Settings where the Backup information was. I am sure that this was some sort of default info, as this guy would not have been able to set this stuff up.

    1.) In the Backup Dir the Playlists Folder was indicated.

    2.) The Backup time was 03:00.

    I did notice a lot of backup files in his playlist folder earlier today.
    I don't have the Playlists folder with me now, so I can't look at the File Names, but I would assume that if I run the restore procedure, with the latest backup file (And I have to run "Find alternative files", as I have merged a lot of his music libraries into the new disk drive, and they have switched Drive Letters and Folder names.)

    My question is how do I know which is the latest backup file? Is the date of the Backup part of the Filename in the Playlists Folder?

    Thanks again for your help!

  6. #6
    Senior Member erland's Avatar
    Join Date
    Dec 2005
    Location
    Sweden
    Posts
    10,318
    Date is part of the file names in the scheduled backups.

    For TrackStat data to be able to survive a restore, even with "Find alternative files" enabled, it's important that the last part of the file path is the same.

    For example, if "Find alternative files" are enabled it will handle:
    Old file: C:\Music\SomeAlbum\SomeTrack.flac
    New file: E:\Music\SomeAlbum\SomeTrack.flac

    And also:
    Old file: C:\OldMusic\SomeAlbum\SomeTrack.flac
    New file: C:\Music\SomeAlbum\SomeTrack.flac

    But it will not handle:
    Old file: C:\Music\SomeOldAlbum\SomeTrack.flac
    New file: C:\Music\SomeAlbum\SomeTrack.flac

    To handle the last case, the files must be tagged with musicbrainz tags.
    If there are a lot of cases like the last one, the best solution is probably to do a backup, manually adjust the data in the backup file in a text editor, restore the modified backup file. However, this can be a lot of work if there are a lot of places that's changed, especially since the data in the backup file is url encoded, so it's not that easy to modify it manually unless you know what you are doing.
    Erland Isaksson (My homepage)
    (Developer of many plugins/applets (both free and commercial).
    If you like to encourage future presence on this forum and/or third party plugin/applet development, consider purchasing some plugins)
    You may also want to try my Android apps Squeeze Display and RSS Photo Show
    Interested in the future of music streaming ? ickStream - A world of music at your fingertips.

  7. #7
    Senior Member
    Join Date
    Jan 2011
    Posts
    172
    And also:
    Old file: C:\OldMusic\SomeAlbum\SomeTrack.flac
    New file: C:\Music\SomeAlbum\SomeTrack.flac
    Our system is similar to this except that we have changed Drive Letter too.

    Like
    And also:
    Old file: C:\OldMusic\SomeAlbum\SomeTrack.flac
    New file: E:\Music\SomeAlbum\SomeTrack.flac

    What is confusing me, is that this guy has run a complete re-scan numerous times and seemed to not lose track-stat data, he has never done a restore. Is this possible?

    He has been using your plugin for about 5 months now.

  8. #8
    Senior Member erland's Avatar
    Join Date
    Dec 2005
    Location
    Sweden
    Posts
    10,318
    Quote Originally Posted by Cut-Throat View Post
    Our system is similar to this except that we have changed Drive Letter too.

    Like
    And also:
    Old file: C:\OldMusic\SomeAlbum\SomeTrack.flac
    New file: E:\Music\SomeAlbum\SomeTrack.flac
    Ok, then the "Find alternative files" function should do the right thing.

    Quote Originally Posted by Cut-Throat View Post
    What is confusing me, is that this guy has run a complete re-scan numerous times and seemed to not lose track-stat data, he has never done a restore. Is this possible?

    He has been using your plugin for about 5 months now.
    As long as you haven't moved or renamed any files, TrackStat data will always survive a full rescan, actually these days even standard SBS/LMS ratings, playcounts and last played times will survive a full rescan.

    If you have moved or renamed files, TrackStat data will only survive a rescan if you have musicbrainz tags in the music files, else you have to do a backup/restore.

    So maybe he just hasn't moved or renamed any files, just added new ones ? In that case TrackStat data will always survive a full rescan.
    Erland Isaksson (My homepage)
    (Developer of many plugins/applets (both free and commercial).
    If you like to encourage future presence on this forum and/or third party plugin/applet development, consider purchasing some plugins)
    You may also want to try my Android apps Squeeze Display and RSS Photo Show
    Interested in the future of music streaming ? ickStream - A world of music at your fingertips.

  9. #9
    Senior Member
    Join Date
    Jan 2011
    Posts
    172
    OK, thanks!......He has not moved any files or re-named them, so now I understand!

    I think I will be able to get him set up right!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •