Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!thunder.mcrcim.mcgill.edu!snorkelwacker.mit.edu!usc!zaphod.mps.ohio-state.edu!uakari.primate.wisc.edu!aplcen!boingo.med.jhu.edu!haven.umd.edu!wam.umd.edu!ignatz From: ignatz@wam.umd.edu (Mark J. Sienkiewicz) Newsgroups: comp.sys.3b1 Subject: Re: swap space Message-ID: <1991Jun14.231953.6095@wam.umd.edu> Date: 14 Jun 91 23:19:53 GMT References: <1991Jun9.170520.4087@yenta.alb.nm.us> <1991Jun11.030216.6155@ceilidh.beartrack.com> Sender: usenet@wam.umd.edu (USENET Posting) Organization: University of Maryland at College Park Lines: 39 Nntp-Posting-Host: avw In article <1991Jun11.030216.6155@ceilidh.beartrack.com> dnichols@ceilidh.beartrack.com (DoN Nichols) writes: >In article <1991Jun9.170520.4087@yenta.alb.nm.us> dt@yenta.alb.nm.us (David B. Thomas) writes: >>How does the 3b1 know where to find swap space, and can it use the "swap >>partition" on the second hard disk? > > It looks for the special device file "/dev/swap". Here, we see that This is not correct. It uses partition #1 on hard disk #0. This just happens to be named /dev/swap, but the kernel does not look in /dev to find it. It just uses the block device with major number 0, minor number 1. > You should be able to simply replace "/dev/swap" with a link to the as described above, this doesn't work. >other, so you could increase the space to handle emergency conditions, since >the actual "swap" proceedure is used only under relative emergency >conditions, with paging used for normal conditions. The swap area is used both to swap processes and to store DATA pages when they are paged out. Read only TEXT pages are never swapped out, but they are sometimes thrown away and re-read from the a.out file you are executing. >and general understanding. If I gave wrong advice, I'm sure I'll hear about >it :-) Congrats! I wish more people on the net had this attitude. There are variables in most unix kernels: _swapdev major/minor # of swap device _swplo first block number on device available for swapping _nswap number of blocks available Not all unixes have these. If you are knowledgeable, brave, or foolhardy, you can use ADB to modify your kernel to change these. DO NOT DO THIS TO A RUNNING KERNEL. cp /unix /unix.hacked; adb /unix.hacked; then boot the modified kernel. happy hacking.