filesystem – Makes a filesystem¶
Requirements¶
The below requirements are needed on the host that executes this module.
- Uses tools related to the fstype (
mkfs) andblkidcommand. When resizefs is enabled,blockdevcommand is required too.
Parameters¶
Notes¶
Note
- Potential filesystem on dev are checked using
blkid, in caseblkidisn’t able to detect an existing filesystem, this filesystem is overwritten even if force isno.
Examples¶
- name: Create a ext2 filesystem on /dev/sdb1
filesystem:
fstype: ext2
dev: /dev/sdb1
- name: Create a ext4 filesystem on /dev/sdb1 and check disk blocks
filesystem:
fstype: ext4
dev: /dev/sdb1
opts: -cc
Status¶
- This module is not guaranteed to have a backwards compatible interface. [preview]
- This module is maintained by the Ansible Community. [community]
Authors¶
- Alexander Bulimov (@abulimov)
Hint
If you notice any issues in this documentation, you can edit this document to improve it.