Click to See Complete Forum and Search --> : [RESOLVED] SourceSafe Analyze
MMock
Jul 29th, 2009, 12:31 PM
A salesperson just kicked my power cord which turned off my PC. I had VSS up and running. So now I have to run Analyze. I don't know if I'm dreaming (it's more of a nightmare really) but I could've sworn in the past (like on Monday) I was able to open SourceSafe Administration and under Tools there was an Analyze utility. I don't have it now. I don't want to use the command line, this should be a simple analyze. Do you have it? Where could mine have gone?
MMock
Jul 29th, 2009, 12:52 PM
This may be worse than I thought. The database seems to be gone. If I choose Open SourceSafe Database while in Visual SourceSafe Administrator and it lists Available databases, there is one listed but it is greyed out. Is that normal? And when I open up Visual Studio, I get all kinds of messages like "the database does not exist or cannot be accessed at this time" so now I am scared it got too corrupted even for Analyze to recover...
Merrion
Jul 30th, 2009, 08:00 AM
analyze can be run from the command line...
Usage: analyze [options] [@<response file>|<List of files>] <SourceSafe data path>
-? or -h Display this message.
-b<folder> Specify the folder to use for backup.
-c Compress unused space.
-d Delete unused items.
-db Delete backup.
-dc Disable common messages (bad case in physical file names).
-df Disable free space check.
-dw Run SourceSafe 2005 reference checking only.
-f Automatically fix files with corruptions.
-fl Automatically fix files with corruptions and re-build the label cache.
-fp Automatically fix files with corruptions and remove invalidly named physical files.
-i- When the analysis is complete the program exits.
-refv6 Run SourceSafe 6 reference checking instead of SourceSafe 2005 reference checking.
-s Slow project rebuild (slower but more rigorous scan for child items).
-x Do not attempt to lock the database when analyzing. If -x is specified, -c, -d, and -f are not allowed.
-v1 Show only critical errors.
-v2 Show only significant errors.
-v3 Show all errors and inconsistencies.
-v4 Show errors, inconsistencies, and informational notes.
MMock
Jul 30th, 2009, 08:05 AM
Thanks...not to be lazy, but I've always done it from the UI so that is what I wanted to do. I'll see what switches I need and try that later. All those options are overwhelming but I guess if I just say "analyze" with no switches, that is a good start.
MMock
Jul 30th, 2009, 11:46 AM
Okay, I was able to open it. I'm still confused, but at least I've got my source code now. Thanks...
:confused:
emartinho
Jul 30th, 2009, 01:13 PM
First of all, do you have a backup? If not, at least backup what you currently have immediately before analyzing, just in case you need to go back to your current DB for some reason.
The command line that is in the shortcut "Analyze VSS DB" on the Start menu is:
"C:\Program Files\Microsoft Visual Studio\COMMON\VSS\win32\ANALYZE.EXE" -x -v1 "C:\Program Files\Microsoft Visual Studio\Common\VSS\data"
Just replace "C:\Program Files\Microsoft Visual Studio\COMMON\VSS\win32\ANALYZE.EXE" -x -v1 "C:\Program Files\Microsoft Visual Studio\Common\VSS\data" with the path to your VSS DB's data directory.
Hope this helps.
-EM
MMock
Jul 30th, 2009, 01:19 PM
Yes, that is helpful.
May I ask how to backup the database? I didn't even find where it is...
emartinho
Jul 30th, 2009, 02:07 PM
Hmm, to access the VSS DB you need to navigate to the srcsafe.ini of the DB and that is usually in the root dir of the DB. Anything in that root dir and above (below.... whatever, everything within the folder!) should be backed up.
MMock
Jul 30th, 2009, 02:11 PM
Okay, I noticed that ini file when I was poking around earlier. So by backup you just mean copy the folder somewhere, not do a sql server backup-equivalent-type-thing... Right?
emartinho
Jul 30th, 2009, 02:24 PM
Correct. The VSS "Database" is really just a collection of files in a specific folder structure. Copy all the files and you copy the Database.
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.