[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
"losing" a file in the ext2 file-system
As far as my understanding of the Linux ext2 filesystem (and a UNIX fs in
general) goes every file has its inode number which exclusively points to
its content. A directory is simply a file that contains a list of
filenames, their associated inode numbers, and other info such as
permissions. I noticed that I can use the "joe" editor to edit directories,
and it displays their binary content as if they were regular files.
Now, suppose I use joe to edit a directory and (with the proper knowldege
and calculations) delete the entry of a file which has no other symbolic
links, and then "save" it. Will the:
1. kernel ext2 filesystem handler not allow it?
2. ext2 fs handler remove the file from the inode table?
3. The file will be stuck in the hard disk, thus occupying space, and not
easily removeable?
Shlomi Fish
-----------------------------------------------------------------------------
Shlomi Fish Smart Link Ltd.
Home E-mail: shlomif@ibm.net Work E-mail: shlomi@slink.co.il
Home Page: http://www.slink.co.il/~shlomi
"Had I not been already insane, I would have long ago driven myself mad."
The Enemy and how I Helped to Fight it.
-----------------------------------------------------------------------------
Follow-Ups: