Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B UNSW 1.0 3/14/84; site qfdts.oz Path: utzoo!watmath!clyde!burl!ulysses!allegra!mit-eddie!think!harvard!seismo!munnari!basser!uqcspe!qfdts!phil From: phil@qfdts.oz (Phil Chadwick) Newsgroups: net.bugs.usg Subject: Re: Sys V r2 version 2 swap bug Message-ID: <49@qfdts.oz> Date: Tue, 16-Jul-85 00:38:00 EDT Article-I.D.: qfdts.49 Posted: Tue Jul 16 00:38:00 1985 Date-Received: Thu, 18-Jul-85 03:28:22 EDT References: <46@qfdts.oz> <943@houxf.UUCP> Organization: Department of Forestry, Brisbane, Australia Lines: 42 Bill Stewart (ho95c!wcs AT&T Bell Labs, Holmdel NJ) writes that in System V r2.0 version 2: >[... Has anyone been able to change swap areas?...] >Yes, I do it all the time. My system boots up with swap on the >root drive, which is boring; in the /etc/rc I do the following: > > swap -a /dev/dsk/1s1 0 70000 # Add 70Kblocks swap on 1s1 > swap -d /dev/dsk/0s0 14320 # Remove 0s0 swap. > swap -l # List what's left I appreciate the advice since it made me think the problem through a little further. I should have said that the problem was on a VAX, although I don't know if it is specific to the VAX. To recap, our VAX panics (as soon as it has to swap) after extra swap space (on a drive type which differs from the initially configured swap device) is added to the system with a swap(1m) command. It does not surprise me that the above swap commands worked because on a VAX at least, /dev/dsk/1s1 and /dev/dsk/0s0 are massbus disks and will both have the same major device code (reflecting either the rm05 or gd driver). Hence using "bmajor(swapdev)" will select the correct driver for both swap areas. I still think that the "swapdev" in line 72 of physio.c is wrong (because it reflects the initially configured swap device, not necessarily the one that should be used): (*bdevsw[bmajor(swapdev)].d_strategy)(bp) I think that "swapdev" should be changed to "dev". But is this all that is required? ---- Phil Chadwick Australia: (07) 2296500 Department of Forestry International: +61 7 2296500 PO Box 5 ACSnet: phil@qfdts.oz Brisbane, Roma Street ARPA: decvax!mulga!qfdts.oz!phil@UCB-VAX.ARPA AUSTRALIA 4001 UUCP: {decvax,vax135,eagle,pesnta}!mulga!qfdts.oz!phil