Click here to Skip to main content
15,885,309 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
Hey Guys I've got a serious problem here. We had a bunch of projects which had been built and were ready to go on a Windows 7 machine. We use Visual Studio 2010 for the development (C++).

This is what happened: The machine was being used in RDC and was later disconnected and not shut down. The next day, when we logged back on, it seemed like all of the source (.h,.cpp, vcxproj etc) were missing in the folder but one strange file with no extension with the project name(this seems to be a large pointer or a hint) was found (huge size of 6MB +).

Is there a way to recover these files because according to what I'm thinking they are somehow in that one huge file. Is this a problem which anyone encountered before? Please give me any steps you can think of. Thanks in advance!
Posted
Comments
Sergey Alexandrovich Kryukov 27-Aug-13 1:40am    
Not enough information.

Just keep your files on leash. And don't forget that you are a software developer.

—SA
Nithin Sundar 27-Aug-13 1:44am    
That's kind of the problem here man. The machine was not used for some time but it was still switched on. There's one file left where there were source files before and that one file is taking up a lot of space. Is this one case of automatic defrag in Win 7 gone wrong?

And by the way, I hope you did not mean to cause offence. I know the pressure you get in the Q&A (urgentz, codezz) but there's no need to be "Remember you are a software developer". Thanks.
Sergey Alexandrovich Kryukov 27-Aug-13 2:05am    
No, of course I did not mean any offense. We all start with no or little experience and gradually mature. Me too. I would be very glad to know that you didn't need this reminder, but from time to time I allow myself to write something like that, just because it could be the real problem to be addressed. Some people don't get the requirements imposed by their engineering or other positions. You see, you really need to sharpen your own tools and take care of them. This goes about preserving your asserts, among other things. The naive beginning users may ask: "I lost my e-mail, how to find it?", but for developers, this is a kind of a prerequisite. In this case, you should prevent problems like that, not to address them when it's a bit too late.

By the way, it looks like the file with no "extension" (really, those file endings are not "extension", this is the obsolete term) should not exist, so it could really be some disaster. You should know all the files which are uses as the source code and commit them to the Revision Control System in time.

I hope you understand me.
—SA
Nithin Sundar 27-Aug-13 2:10am    
I really appreciate you taking the time to write this here. Not just beginners, every developer would be required to remember this. :)

But unfortunately the problem is more Windows Oriented. I had included the Visual Studio tag as I thought it could be some weird bug.

Yeah I understand you (sometimes I have been a occasional companion answering questions in the same thread as you so I know what you go through everyday) it's just that Windows 7 seems to throw a new wonderful problem sometimes.
Sergey Alexandrovich Kryukov 27-Aug-13 2:18am    
Yes, I see... And Windows 7 seems to be the most stable so far to me...
—SA

1 solution

Please see my comment to the question.

Let me give you one more supplementary but useful advice. You should not recover files, you should keep them properly. If you are not using one of the Revision Control Systems, you are not really developing software. You valuable code resources belongs not to you, but to the first hardware or software system failure. And such system can be (and I think should be) open-source, very light-weight and reliable.

Please see this discussion: Revision control systems, which to choose from?[^].

—SA
 
Share this answer
 
Comments
Nithin Sundar 27-Aug-13 1:47am    
We already use TFS. The point here is, the machine was switched on and nobody even accessed it from what I heard. It seems like the file modification happened early in the morning (when nobody was accessing it). Do you think this could be a case of the background defrag gone wrong?
Sergey Alexandrovich Kryukov 27-Aug-13 1:52am    
It means that you use TFS incorrectly, maybe not enough regularly. You did not provide any useful information on the file loss. You should not solve the problem, you should prevent it.
—SA
Nithin Sundar 27-Aug-13 1:54am    
I think you are missing the point here. I meant that we already use TFS in response to your Revision Control answer. Development was being done yesterday and it was decided to check in once it was completed today. Only in that space of time did this incident happen. That's the reason I even asked this question here.
Sergey Alexandrovich Kryukov 27-Aug-13 2:08am    
Maybe I did not get it, but you could say that I missed the point if you mentioned TFS in your question, and you didn't.
Are the files missing from revision control data or on a development computer?
—SA
Nithin Sundar 27-Aug-13 2:12am    
You know what the plot thickens!

I opened the huge file through Visual Studio (a random thought generated in the wild) and what do you know....

EVERY single code from the project is here in one file. How the heck does these things happen? I guess the hamsters have decided that the dev machine we have is not worthy!

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900