22

I would like to know how to create a ntfs partition on /dev/sdx. I could not figure out if I should use partition type 7 86 or 87.

What is the full list of commands to use?

  • With partition type 7 86 or 87 I assume you mean the fdisk shell partition types, of course. – Sopalajo de Arrierez Oct 6 '17 at 21:02
33
  1. create a partition using fdisk

    fdisk /dev/sdx
    

    Commands:

    • to create the partition: n, p, [enter], [enter]
    • to give a type to the partition: t, 7 (don't select 86 or 87, those are for volume sets)
    • if you want to make it bootable: a
    • to see the changes: p
    • to write the changes: w
  2. create a ntfs fileystem on /dev/sdx1:

    mkfs.ntfs /dev/sdx1
    
  3. mount it wherever you want

    mount /dev/sdx1 /mnt/myNtfsDevice
    
  • 1
    when your disk size larger than 2TB, should use gdisk instead of fdisk. commands are simliar – temple Nov 27 '17 at 0:52
  • 8
    If you have a large file system and dont want to wait hours to write zeroes through it, you can skip that part by running mkfs.ntfs -f /dev/sdx1 instead – DCIndieDev Jun 14 '18 at 1:39
3

You can use fdisk to create the partition "disk" division but for the partition's file system you can use the mkfs.ntfs to create the file system in the partition that will use ...

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.