[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

2 feature requests

From: Eric Pearce
Subject: 2 feature requests
Date: Fri, 29 Feb 2008 11:08:04 -0800

(Sorry if this is already done)

1) It would be nice to a "-f" or "--force" option so you could do something destructive using the --script option, i.e.

   # parted --force --script /dev/sda mklabel msdos

2) It would be great if there was a "--commands" option to parted to have it print out the parted commands required to recreate a partitioning scheme, i.e.

   Say this is the output of the following:

   # parted --script /dev/sda print

       Model: DELL PERC 5/i (scsi)
       Disk /dev/sda: 599GB
       Sector size (logical/physical): 512B/512B
       Partition Table: msdos

       Number  Start   End    Size    Type      File system  Flags
        1      32.3kB  156MB  156MB   primary   ext3
        2      156MB   210GB  210GB   primary   ext3
        3      210GB   243GB  33.6GB  primary   linux-swap
        4      243GB   599GB  355GB   extended
        5      243GB   275GB  31.5GB  logical   ext3
        6      275GB   285GB  10.5GB  logical   ext3
        7      285GB   296GB  10.5GB  logical   ext3
        8      296GB   599GB  303GB   logical   ext3

The "--commands" option would generate something like the following:

      # parted --script /dev/sda --commands

       parted --force --script /dev/sda mklabel msdos
       parted --script /dev/sda mkpartfs primary ext2 32.3kB 156MB
       parted --script /dev/sda mkpartfs primary ext2 156MB 210GB
       parted --script /dev/sda mkpartfs primary linux-swap 210GB 243GB
       parted --script /dev/sda mkpart extended 243GB 599GB
       parted --script /dev/sda mkpartfs logical ext2 243GB 275GB
       parted --script /dev/sda mkpartfs logical ext2 275GB 285GB
       parted --script /dev/sda mkpartfs logical ext2 285GB 296GB
       parted --script /dev/sda mkpartfs logical ext2 296GB 599GB

I would find this useful for kickstart or when recreating some system from backups.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]