Help! I lost my file! How do I get it back?

> I accidently wrote over files in a directory this morning. Is there any
> way I can get them back?

Unfortunately no. Over writting a file on any system is impossible to get back. Even if the file was only erased. On a multi-user system, when the allocated space has been freed, the next file to be written is put in the freed space.

If this was a program for a class, here is a suggestion. Make a subdirectory called 'backup'. Every time you go to work on your program, copy('cp') that file into the backup directory with a version number appended to the file, such as 'program.c.1'. This way if you need to get to a previous version for one reason or another, it's there. Don't worry about disk space, because you'll only keep the source code versions, which is small compared to the executable. After you've turned in your program, just delete the entire backup subdirectory. There is software called 'Source Code Control System' (sccs) on csc, but beginners might find it a little difficult to work with. If you are interested, you can find more information on it by typing 'man sccs'.


Home | Information | Academics | People | Resources | Contact

The Department of Computer Science at the University of Illinois at Springfield
Copyright© 2002 University of Illinois at Springfield