From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.redhat.com (mail.redhat.com [199.183.24.239]) by listman.redhat.com (Postfix) with ESMTP id 8233C2F218 for ; Sat, 16 Dec 2000 11:43:18 -0500 (EST) Received: (from mail@localhost) by mail.redhat.com (8.11.0/8.8.7) id eBGGhIR06795 for axp-list@listman.redhat.com; Sat, 16 Dec 2000 11:43:18 -0500 Received: from ellpspace.math.ualberta.ca (IDENT:michal@ellpspace.math.ualberta.ca [129.128.207.67]) by mail.redhat.com (8.11.0/8.8.7) with ESMTP id eBGGhHD06791 for ; Sat, 16 Dec 2000 11:43:17 -0500 Received: (from michal@localhost) by ellpspace.math.ualberta.ca (8.9.3/8.9.3) id JAA24141 for axp-list@redhat.com; Sat, 16 Dec 2000 09:43:14 -0700 Date: Sat, 16 Dec 2000 09:43:14 -0700 From: Michal Jaegermann To: axp-list@redhat.com Subject: Re: Disklabel Command Message-ID: <20001216094314.A24115@ellpspace.math.ualberta.ca> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.95.4us In-Reply-To: ; from Rich Payne on Sat, Dec 16, 2000 at 09:40:12AM -0500 X-Loop: axp-list@redhat.com Sender: axp-list-admin@redhat.com Errors-To: axp-list-admin@redhat.com X-BeenThere: axp-list@redhat.com X-Mailman-Version: 2.0beta4 Precedence: bulk Reply-To: axp-list@redhat.com List-Id: Linux and Red Hat on Alpha processors On Sat, Dec 16, 2000 at 09:40:12AM -0500, Rich Payne wrote: > On Sat, 16 Dec 2000, Howard Arnold wrote: > > > The disklabel > > command allowed you to copy the partition table of a disk to a file and > > modify it. It could than be copied back to the disk. > > look at sfdisk, it can read from a file and output to a file. 'sfdisk', which is a short for "scriptable fdisk", works very well, and for years, for FAT type partition tables. If you will try to use for a disk with "disklabel" you will see something of that sort: # sfdisk -l /dev/sda Disk /dev/sda: 8715 cylinders, 64 heads, 32 sectors/track sfdisk: ERROR: sector 0 does not have an msdos signature /dev/sda: unrecognized partition No partitions found I wrote somewhat similar, but simpler and not implemententing full functionality of 'sfdisk' (main stuff is there), utility which reads and writes disklabels, only, as they are used by Linux on Alpha. If there is an interest I may put it up for ftp. I read once a account of somebody very proud of himself who was driving in scripts 'fdisk' from stdout. Not very hard to do, if a bit funny and scary at the same time, but the guy had 'sfdisk' and only was not aware of that. :-) Older distros of Linux for Alpha included 'minlabel' utility. I am not sure how usable it was in scripts, probably it was, but apparently it had some problems. Michal p.s. BTW, the current version of 'bdsfdisk' is improved a bit over the stuff I send a while ago to folks in Red Hat.