When you delete a file, you are just deleting the directory entry and
decrementing the inode usage count by 1. Only when the inode is used 0
time will the file actually be deleted from the filesystem. Opening the
file counts in the inode usage count as well, so as long as the swap
file is active, the file will still exist on the disk. Only when the
swap file is deactivated will the file be really deleted. Changing the
file's attributes may not work on all filesystems (like vfat/msdos, if
you're really desperate for swap space).
--Brian Gerst
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/