Messages in this thread | | | Date | Mon, 21 Dec 1998 14:54:13 +0000 (GMT) | From | Riley Williams <> | Subject | Re: Raw-io & Swap partitions |
| |
Hi Peter.
> There seem to be fairly significant parallels between Linux's > support of special partitions for swap, and the arguments for raw > disk I/O.
> If the arguments against raw-io are technically correct, why do we > still support partition level access to swap ?
I'm no expert on this, but my understanding is that swap needs to have the entire swap area in contiguous sectors, which can't be guaranteed for files, but is a given with partitions.
Indeed, as I understand it, on the ext2 file system, ANY file that's over 16 Megs in size is of necessity split into several separate fragments...
> Assuming there's little performance difference between swap > partitions and swap files, swap files are a big win. No hardwired > decision on how much swap is needed, just create a swap file in one > of the filesystems. If you find it's too big or too small it can be > resized easilly. (Unlike a partition).
> On the flip side, if swap partitions do give some advantages, > surely the same justification can be made for supporting raw-io.
I don't believe it can, since the specific advantage gained by swap partitions that I mentioned above is in general irrelevant in all other contexts...
> Note: I'm not saying the two cases are identical, just that there > are fairly major simillarities.
Unfortunately, swap also has some unique requirements which make the difference...
> I appreciate that it's far easier to keep something out of the > kernel in the first place than to remove it later. However in the > case of swap partitions I'm confident they could be removed > painlessly. Just turn the partition into an e2fs one and create one > large file. (Worst case).
Unfortunately wouldn't work - you'd have to creat a whole bunch of separate files, each just below the fragmentation limit, and each residing in a separate "block group" (the kernel's name, not mine), as otherwise, they'd be unusable...
Best wishes from Riley.
- 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/
| |