How can I use an input file to script partitioning operations with sfdisk?

Updated -

sfdisk can take a file as input and create the partitions specified in the file on a disk.

For example, to create a Linux partition on /dev/sdb starting at cylinder 1 and ending at cylinder 260, create a file named partition with the following contents:

1,260,83

Each line in the file represents one partition and consists of four columns: s...

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.