/disk/format
format
/disk/format 的 RouterOS 命令参考。
disk/format
Conditions: !smips Type: Command
| 参数 | 类型 | 描述 |
|---|---|---|
file-system | enum (fat32 | ext4 | btrfs | xfs | wipe | wipe-quick | exfat | discard | discard-secure) | 用于格式化磁盘的文件系统。 - ext4 - 使用 ext4 格式化;大多数用例的默认值。 - fat32 - 使用 FAT32 格式化,几乎任何设备都可读取。 - exfat - 使用 exFAT 格式化,适用于存储卡和 USB 驱动器上的大文件。 - btrfs - 使用 Btrfs 格式化(数据校验和、快照、RAID);需要 Storage 包。 - xfs - 使用 XFS 格式化;需要 Storage 包。 - discard - 丢弃磁盘的所有块(等同于 blkdiscard),不写入文件系统。 - discard-secure - 相同,但使用安全丢弃,同时擦除底层数据。 - wipe - 覆盖磁盘上的所有数据,使其无法恢复。 - wipe-quick - 移除文件系统而不覆盖数据;速度快,但数据可通过工具恢复。 |
label | string | File system label. Default: <slot>-fs. |
mbr-partition-table | bool | 在格式化时向磁盘写入 MBR 分区表。不启用时磁盘不会获得分区表;之后使用 add type=partition 创建分区,这些分区存储在 GUID 分区表中。默认值:no。 |
| 只读参数 | 类型 | 描述 |
|---|---|---|
output | string | 格式化进度:mkfs 命令行及其输出、进度百分比或字节计数器,以及最后的 format done 行。 |