Differences between current version and revision by previous author of mkswap(8).
Other diffs: Previous Major Revision, Previous Revision, or view the Annotated Edit History
Newer page: | version 6 | Last edited on Tuesday, March 2, 2004 8:51:01 am | by JohnMcPherson | |
Older page: | version 5 | Last edited on Monday, March 1, 2004 7:24:39 pm | by CraigBox | Revert |
@@ -51,5 +51,7 @@
fdisk(8), swapon(8)
----
-;
__After I create a swapfile (with dd), call mkswap on it, call swapon, do I need to edit /etc/fstab so the swapfile will be remounted upon next boot? More details than just "in some boot script" would be nice.__ :
It's distro-specific; for example on DebianLinux, there is an /etc/init.d/checkroot.sh and mountall.sh which run swapon(8) after mounting swap partitions from the fstab(5) file. So, just put it in /etc/fstab as type ''swap'', and your distro should deal with it automatically
+__After I create a swapfile (with dd), call mkswap on it, call swapon, do I need to edit /etc/fstab so the swapfile will be remounted upon next boot? More details than just "in some boot script" would be nice.__
+
+
It's distro-specific; for example on DebianLinux, there is an /etc/init.d/checkroot.sh and mountall.sh which run swapon(8) after mounting swap partitions from the fstab(5) file. So, just put it in /etc/fstab as type ''swap'', and your distro should deal with it automatically. Similarly, [Slackware] does ''swapon -a'' in its /etc/rc.d/rc.S startup script. According to the swapon(8) manpage, "swapon -a" mounts swap devices listed in /etc/fstab. Perhaps swap __files__ (rather than swap __partitions__) need to be handled differently?