bill@twwells.com (T. William Wells) (02/09/90)
In article <15161@bfmny0.UU.NET> tneff@bfmny0.UU.NET (Tom Neff) writes: : In article <PCG.90Feb5191855@rupert.cs.aber.ac.uk> pcg@rupert.cs.aber.ac.uk (Piercarlo Grandi) writes: : >Well, in most timesharing applications your system _should_ swap. : >A very rough rule of thumb is that if a resource is less than 30% : >used it is wasted (and if over 60% used it is insufficient, because : >queues will form on a resource that is more than 60% committed on average). : > : >Given that the majority of processes in a timesharing system is : >inactive, and possibly for fiarly long times, swapping/paging is : >healthy. If it does not occur, than you have too much memory for : >your application mix. If you don't want it to occur because it is : >too slow, this means that the swap bandwidth is undersized. : : These principles apply to large multi-user timesharing systems but not : to supermicro workstations, which are mostly where UNIX/386 runs. : : On a 386/486 workstation you should shoot for very little swapping. : Memory is fairly cheap and performance already has enough bottlenecks : to contend with. AT386 bus and disk controller performance will definitely : exact a penalty if you start swapping significantly. Damn straight. When my system swaps, even a little, I really notice. My system is disk bound even when there is no swapping going on. Accordingly, every time that happens, I go out and buy more memory. Here's a question for you gurus: I *don't* want swapping. Of any kind. I'm up to 12Meg now and when my system swaps it is invariably because I've just run one of my data compressions that takes all of memory for its data. And when that happens, I don't want to wait for the program to finish (it won't in less than geological time; these programs don't have enough locality of data reference!) I just want it to die. Can swapping be disabled? Can I reclaim the 16M of disk space being wasted on the swap partition? My system is a Microport SysV/386 3.0e and I have kernel source. I've directed this discussion to comp.unix.wizards because I suspect that most people who would have something useful to contribute would be there. --- Bill { uunet | novavax | ankh } !twwells!bill bill@twwells.com
frk@mtxinu.COM (Frank Korzeniewski) (02/10/90)
In article <1990Feb8.225524.17560@twwells.com> bill@twwells.com (T. William Wells) writes: > >Damn straight. When my system swaps, even a little, I really >notice. My system is disk bound even when there is no swapping >going on. Accordingly, every time that happens, I go out and buy >more memory. > >Here's a question for you gurus: I *don't* want swapping. Of any >kind. I'm up to 12Meg now and when my system swaps it is >invariably because I've just run one of my data compressions that >takes all of memory for its data. And when that happens, I don't >want to wait for the program to finish (it won't in less than >geological time; these programs don't have enough locality of data >reference!) I just want it to die. > >Can swapping be disabled? Can I reclaim the 16M of disk space >being wasted on the swap partition? > >My system is a Microport SysV/386 3.0e and I have kernel source. > >I've directed this discussion to comp.unix.wizards because I >suspect that most people who would have something useful to >contribute would be there. > >--- >Bill { uunet | novavax | ankh } !twwells!bill >bill@twwells.com I have several commentss, the trivial ones first: 1) If you have kernel source why are you asking this question? If I had kernel source, I would just read the code to find the answer. 2) How in the world did you get kernel source? I would like it also, as I have the same OS. 3) I do not read comp.unix.wizards. So let me know if they have any better information than I have. 4) In my expirience, SystemV does not swap. It just pages heavily and little usefull work gets done. Then the system suspends processes until the paging rate goes back down. 5) I had only 4MB on my system and was unhappy with the performence. Unable to afford the 32 bit memory, I wrote an EMS ram disk driver. At boot I would use swapadd to make the ram disk a swap area and remove the hard disk swap partition. This was somewhat ok, but still a lot of disk activity. So I made a second ram disk and copied over a lot of commonly used programs. The hard disk was then VERY quiet. It seems that program text is paged in from the executable on disk. Now the data (modified pages) come from the swap partition. This generally means long seeks when a program is alternatly faulting on data and text (this seems to be common!!). Anyway, now I have 10MB of 32 bit memory, but I still have an 8MB ram disk with common programs on it. This performs about the same as the system with two ram disks. I have found that 16 bit EMS memory is cheaper than the 32 bit main memory. So I will probably add more ram disk as I exceed the 10MB I have now. One complication with replacing the swap area is that you should redirect the /dev/swap device. PS will always use this dev to get info on paged out processes. If you don't redirect, then you get random junk in the PS printout. Also, I posted the ram disk driver to comp.unix.microport several months ago, if anyone is interested. Frank Korzeniewski (frk@mtxinu.com)