Thread Closed

general computing questions

 
Share Thread Thread Tools
Oct1-09, 12:32 PM   #1
 

general computing questions


I've been reading the thread on completely erasing hard drives as well as a bit on the File Allocation Table (i.e. FAT). Apparently formatting your computer does not completely erase your data from the disk. So I have some questions:

1) Does the FAT contain a collection of "pointers" to files? Perhaps it's similar to a reference in Java where it simply tells you where something lives in memory?

2) So formatting your hard drive just erases pointers from the FAT, and doesn't actually delete the file from memory? Isn't that the same as, or at least similar to, a memory leak?

--Jonathan
 
PhysOrg.com
PhysOrg
science news on PhysOrg.com

>> Heat-related deaths in Manhattan projected to rise
>> Dire outlook despite global warming 'pause': study
>> Sea level influenced tropical climate during the last ice age
Oct1-09, 01:02 PM   #2
 
Recognitions:
Homework Helper Homework Help
Science Advisor Science Advisor
Quote by Chromium View Post
1) Does the FAT contain a collection of "pointers" to files? Perhaps it's similar to a reference in Java where it simply tells you where something lives in memory?
Sort of - the FAT contains the file name and the start cluster number which is analogous to a memory location. The drive maps that cluster to a particular head/cylinder/sector to get the actual data

2) So formatting your hard drive just erases pointers from the FAT, and doesn't actually delete the file from memory? Isn't that the same as, or at least similar to, a memory leak?
It doesn't delete the data from the magnetic surface of the drive. It just deletes the entry in the FAT. When the OS comes to write more data it will use the next free cluster, which might overwrite previously deleted data. The strategies for cluster reuse get a bit more complex in more modern filesystems.

A memory leak (in memory) occurs when you have marked some memory as 'in use' by allocating it but have lost the pointer that stored where that memory is an so you can't ask for it be deallocated/free'd when you don't need it - not really the same thing.
The leak comes from the fact that you can't allocate that memory for anything else while it is in use.

In fact when you free memory in and ask for some more you might get back memory that contains the previous data, exactly like reusing disk space - since freeing memory doesn't generally set the contents to 0.
 
Thread Closed
Thread Tools


Similar Threads for: general computing questions
Thread Forum Replies
Optical Computing: special issue - Natural Computing, Springer General Physics 1
Optical Computing: special issue - Natural Computing, Springer General Physics 0
Optical Computing: special issue - Natural Computing, Springer General Physics 0
Optical Computing: special issue - Natural Computing, Springer General Physics 0
Optical Computing: special issue - Natural Computing, Springer General Physics 0