Return to BSD News archive
Newsgroups: comp.os.386bsd.questions Path: sserve!manuel.anu.edu.au!munnari.oz.au!news.Hawaii.Edu!ames!pacbell.com!unet!blunt!dsilvia From: dsilvia@blunt.net.com () Subject: Re: swap space and disklabel Message-ID: <1993Mar2.220730.7729@unet.net.com> Sender: news@unet.net.com Nntp-Posting-Host: blunt Organization: Network Equipment Technologies References: <1993Mar1.213539.1825@linus.mitre.org> Date: Tue, 2 Mar 1993 22:07:30 GMT Lines: 54 In article <1993Mar1.213539.1825@linus.mitre.org> schase@xcalibur.mitre.org (Steven Chase) writes: > >Instead of installing unix, I created partitions on my hard disks and >copied someone else's hard disk. I created a 25 meg partition for >swap space, but couldn't figure out how to tell the system to use it. > >I read that all I have to do is use disklabel to label the partition >'swap'. > >Does anyone know the arguments for disklabel to label the 25 meg partition >'swap'? > >Or does anyone know another way of doing this without reinstalling unix? > >Thanks for any help. > Okay -- here's what I finally did (I think - I made several iterations of the install process before I got around all the 'kmem_malloc', 'extract', and other failures - so my memories may not be exactly right!). I went ahead and let the install do its (very inflexible) thing. I then per- fomed 'disklabel -r wd0 >DiskLabel'. I modified the file to get the ~64Meg swap space I wanted. Next, I booted to the fixit.fs floppy, changed the root to writeable, mounted wd0a on /mnt and grabbed the copy of DiskLabel. Then I executed: 'disklabel -R -r wd0 DiskLabel /usr/mdec/wdboot /usr/mdec/bootwd' I then newfs'd wd0. After that, I booted to the dist.fs floppy and answered no to installing (overwriting I think was the actual question). Once again I mounted wd0a on /mnt and then executed: (cd /; zcat /etc/baselist.Z | cpio -o) | (cd /mnt; cpio -iadm) cd /mnt; zcat /etc/baseutils.cpio.Z | cpio -iadm echo "/dev/wd0a ufs rw 1 1" > /mnt/etc/fstab mv /mnt/etc/base.profile /mnt/.profile [ isn't 'strings' a wonderful command! !;^} ] Finally, I gave it the ol' three finger salute to boot the hard drive and extracted the binaries. Minor details may not be exactly right and you may find you have to do it once or twice for something I left out, but the general approach works. Hope this helps! Dave S.