Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cornell!uw-beaver!rice!sun-spots-request From: todds@cognos.uucp (Todd Sandor) Newsgroups: comp.sys.sun Subject: Re: fixing bad ND partitions Message-ID: <5136@faerie_queene.UUCP> Date: 3 Feb 89 00:36:55 GMT References: <8901171645.AA16782@gpu.utcs.toronto.edu> Sender: usenet@rice.edu Organization: Cognos Inc., Ottawa, Canada Lines: 38 Approved: Sun-Spots@rice.edu Original-Date: Thu, 26 Jan 89 08:23:53 EST X-Sun-Spots-Digest: Volume 7, Issue 134, message 4 of 5 >In v7n105, Tony Tran (versatc!tran@sun.com) asks: >>We have a server with 12 ND partitions, 4 of which are bad. What is the >>easiest/safest way to fix these partitions ? Below is a simple script I use to fix nd partitions, please note though: 1) Bad nd must be halted. (If bad probably halted anyway :-)). 2) The /etc/mkfs must be tailored to the disk using (use dkinfo to find out) 3) The /etc/dump must use a good working nd partition (ndl2 in this case. 4) The editing of rc.boot must have hostname recreating the partition from. I used this many times, partition dumping from doesn't have to be shutdown, at least hasn't given me any problems yet. I call this ndcreate and used ndcreate nd_partition_number hostname to use it. Also good to use to recreate all nd partitions on server (except one dumping from) after an install once tailor the dumpfrom nd partition exactly the way want it (create a ndall script with all entries in it), saves me a lot of time on new installations. #!/bin/csh -v cd / echo "making /dev/ndl$1 " /etc/mkfs /dev/ndl$1 16080 67 15 8192 1024 mount /dev/ndl$1 /mnt cd /mnt /etc/dump 0f - /dev/ndl2 | (cd /mnt; restore xf -) cd /mnt/etc ed rc.boot<