lkml.org 
[lkml]   [1997]   [Jan]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Swap Files
In linux.dev.kernel you write:

>On Sat, 18 Jan 1997, Ion Badulescu wrote:

>Perhaps rather than modifying the kernel proper it would be easier to
>mount swapfiles using the loop device, then a swapoff -a would (if, of
>course, it were configured as such in fstab) indeed permit the fs to be
>umounted at shutdown. If this were to become standard, then the swap
>utils could be reduced to handling nothing but swap partitions, making
>them all the more simple. It would, however, introduce some
>incompatabilities between the versions of the swap utils and
>configurations. Sorry, but I haven't tried this, as I don't use
>swapfiles.

It is'nt that simple. Turn on swap *partitions* is one of the first things
you do at boot time. Usally before checking and mounting filesystems.
For swap *files* you have to wait until your filesystems are mounted.

Same for shutdown: Turn off swap files has to be done before umounting
filesystems, swap partitions can later.

I use this "two-step" swapon: Have a 40 MB swap partition, and after
mounting all the filesystems I run a script which searches the
DOS-Partitions for 386spart.par files :-) BTW: swap priorities are
handy for this: Of cource it is a good idea to run the swap file at
lower priority...

For the new swapon/off: Would be handy to have a "-t [ file | part ]"
switch.

Gerd


\
 
 \ /
  Last update: 2005-03-22 13:38    [W:0.035 / U:0.028 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site