Re: How to get a disk's partition table in a non-interactive way ?

From: Darren Dunham (ddunham_at_redwood.taos.com)
Date: 05/26/03


Date: Mon, 26 May 2003 18:00:44 GMT

stefan <schms@web.de> wrote:
>> > PS: I know
>> > /usr/sbin/prtvtoc /dev/rdsk/c1t0d0s2
>> > but its output does not meet my needs.
>>
>> Can I ask why? It would probably be easier to modify that data than
>> guarantee that you'll do the right thing with format.

> I would like to have the follwing information as I need it in case of
> desaster incident during the recovery process of a system. In this
> process I use a FLASH archive which is a system image (only /, /var,
> /opt/ ) and which is regularly created. When I restore this system
> image ( boot from cdrom, select a flash installation, select the FLASH
> archive with the system image)I am being asked to key in the disk
> layout. That is why I need this information ( partition, Size in GB )

But prtvtoc has all that information, yes?

Is all you need the number in prtvtoc converted from blocks to
gigabytes?

Here's a perl one liner... It could be modified to present other
information, or information in a different format.

# prtvtoc /dev/rdsk/c0t0d0s0 | perl -lane 'next if /^\*/; $gb = $F[4] / (1024 * 1024 * 2) ; printf ("%u %5.2f %s\n", $F[0], $gb, $F[6]); '

The information is "slice#, size(GB), mountpoint".

-- 
Darren Dunham                                           ddunham@taos.com
Unix System Administrator                    Taos - The SysAdmin Company
Got some Dr Pepper?                           San Francisco, CA bay area
         < This line left intentionally blank to confuse you. >


Relevant Pages

  • Re: never ending problems
    ... you're modifying a heading style. ... In the Modify Style dialog there is a Format button. ... Modify:>> Format: Paragraph applies only to paragraph formatting, ...
    (microsoft.public.word.numbering)
  • Re: Word Manuscript -> Book Format
    ... What you want to do is modify the styles. ... if your body text is 12 pt TNR in your manuscript but you want it ... > Suzanne S. Barnhill wrote: ... The manuscript is in A4 format, ...
    (microsoft.public.word.formatting.longdocs)
  • Re: Outline Styles
    ... Styles pane and choose Modify from the context menu. ... Click Format, Paragraph. ... them hang because I hang the second line. ...
    (microsoft.public.word.docmanagement)
  • Re: Formatting applies to whole document
    ... With the cursor in some text that shows the problem, go to Format | Style. ... Uncheck the "automatically update" box in the Modify dialog. ... version 11.3) has started applying most formatting instructions to the ... instructions, bullet points for example, the document goes back to the ...
    (microsoft.public.mac.office.word)
  • Re: Wanted @ gigspot.co.uk - Live bands and music venues
    ... so they will all be in the same format. ... lists daily or even more frequently but do sessions on web forums no ... There are certainly outdated entries for sessions ... >>> email address is the guarantee of quality. ...
    (uk.music.folk)