Page 1 of 1

tmpfs

Posted: Tue Aug 21, 2018 5:58 am
by looren
Hi

I'm wondering regarding creating a tmpfs drive, if anyone has a clue here..
If I were to make a 1mb ram-drive, with a 1mb file, and remove it, is it possible by any means to recover it?
If that is the case, if I overwrite the whole area with 1mb new data, would this overwrite the same parts of ram as the old data was stored in or is the allocation of space dynamic?

Re: tmpfs

Posted: Tue Aug 21, 2018 6:09 am
by gm10
Depends what kind of means you are envisaging. See https://en.wikipedia.org/wiki/Cold_boot_attack

tmpfs has no fixed location in ram. It can even get swapped to disk (ramfs cannot, but don't run out of memory if you use it). Whatever data you copy into the ramdisk may be buffered and cached in addition, plus whatever programs you create or use that data with will create a copy in their part of the memory. The latter can get swapped, too.

Re: tmpfs

Posted: Tue Aug 21, 2018 9:50 am
by looren
Thanks for your reply gm10 ! interesting reading,

I was unaware of ramfs, only thought there was tmpfs.
Cold boot attack aside, after reading about ramfs, I think it would be better suited.