I have to setup/install a number of machines. Some machines have Windows 7 installed. Some machines not. The machines have either 0, 2, or 3 partitions. Every machine has enough free diskspace (20 to 250 GB).

I installed an "golden client" and built a .tar archive of this client. Now, every client boots up a small linux via pxe, and runs a script. This script should create an ext4 and a swap partition using the whole free space. After this, mount the ext4-partition, copy tar, chroot, and so on.

I can create partitions using fdisk. But how can I figure out the partition number of the new partition. For example, do I have to mount /dev/sda3 or /dev/sda1?

Furthermore, how can I figure out if the partition is unallocated space, and how much space there is?

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Browse other questions tagged or ask your own question.