Hi, I have just switched two drives from RAM Disk to RAM File System, with the option to save on shut down.
One disk is 3 GB and the other is 11 GB.
When I was using RAM Disk the .img image files were 3 GB and 11 GB. Now the .rfs files are 47GB and 127 GB.
Have I missed something or done something wrong in the setup of the disks?
SoftPerfect Support Forum
All Forums
► RAM Disk & RAM File System
► Current topic
RAM FS image files are much larger than RAM volumes
|
RAM FS image files are much larger than RAM volumes 04 August 2026, 00:43 |
Registered: 6 days ago Posts: 2 |
|
|
Re: RAM FS image files are much larger than RAM volumes 04 August 2026, 07:37 |
Admin Registered: 20 years ago Posts: 2 060 |
Thanks for the report. You haven't missed anything in the setup. What you're almost certainly seeing is the logical size of the .rfs file rather than the space it actually occupies.
Could you please confirm one thing: right-click each .rfs file, then open its Properties, and tell us both values: the "Size" and the "Size on disk"?
Why the logical size is much larger
RAM Disk saved a fixed block image, so its .img was always exactly the disk size. RAM File System instead saves the contents as a set of 2 MB storage slots, where each file takes at least one slot of address space regardless of how small it is. A disk holding tens of thousands of small files (browser cache, temp, build output) therefore spans a very large range while holding little actual data. The image is stored as a sparse file so the unused parts take up nothing on disk. Your figures suggest roughly 12,000 to 24,000 files on the 3 GB disk and 33,000 to 65,000 on the 11 GB one.
Also, for ensuring that crash and power loss events are safety managed, save operations write the changed data to new slots before releasing the old ones, so a save is never left half-written if anything happens That can briefly double the space taken by the data being saved. It affects the actually used space rather than the logical figure, so it isn't what accounts for the bulk of what you're seeing, but is still worth knowing about.
In future releases, we're planning to implement packing of multiple small files into a shared slot, which would bring the figure down substantially and cut the per-file overhead on disk too, and reduce the file's reported size after a save.
Could you please confirm one thing: right-click each .rfs file, then open its Properties, and tell us both values: the "Size" and the "Size on disk"?
- If "Size on disk" is no larger than the disk itself (up to roughly 3 GB and 11 GB in your case), everything is working as intended and the 47 GB and 127 GB figures you are seeing reflect the address space, not the disk usage. Windows Explorer and the dir command report the logical figure for this type of file; it may look alarming, but in reality it's fine.
- If "Size on disk" shows 47 and 127 GB, something is wrong, and in that case please also tell us which filesystem the drive that is holding those images uses.
Why the logical size is much larger
RAM Disk saved a fixed block image, so its .img was always exactly the disk size. RAM File System instead saves the contents as a set of 2 MB storage slots, where each file takes at least one slot of address space regardless of how small it is. A disk holding tens of thousands of small files (browser cache, temp, build output) therefore spans a very large range while holding little actual data. The image is stored as a sparse file so the unused parts take up nothing on disk. Your figures suggest roughly 12,000 to 24,000 files on the 3 GB disk and 33,000 to 65,000 on the 11 GB one.
Also, for ensuring that crash and power loss events are safety managed, save operations write the changed data to new slots before releasing the old ones, so a save is never left half-written if anything happens That can briefly double the space taken by the data being saved. It affects the actually used space rather than the logical figure, so it isn't what accounts for the bulk of what you're seeing, but is still worth knowing about.
In future releases, we're planning to implement packing of multiple small files into a shared slot, which would bring the figure down substantially and cut the per-file overhead on disk too, and reduce the file's reported size after a save.
|
Re: RAM FS image files are much larger than RAM volumes 05 August 2026, 21:20 |
Registered: 6 days ago Posts: 2 |
The size on disk for the image is right, but when I copy it for backup it takes long time while copying the larger image (127 GB), and at the destination it has the size of the full image on disk. I saw your answer about this in another topic, so I'm looking forward to the new version to solve this.