disk
disk
Conditions: !smips
Type: Directory
| Flag | Name | Description |
|---|---|---|
| X | disabled | The device is disabled and is not used. |
| A | acquired | acquired |
| E | empty | The slot is empty, with no disk present. After eject, the slot stays empty until the disk is rescanned with scan or replugged. |
| B | block-device | The device is a block device, that is, it can be used as storage: formatted or used in a RAID array. Devices without this flag only describe the disk layout. |
| M | mounted | The device is mounted and its files appear in /file. |
| F | formatting | The device is currently being formatted. |
| S | swap-enabled | Swap is enabled on the device (swap=yes); the device is used as swap space, for example by containers. |
| f | raid-member-failed | A member of the RAID array is in failed state. |
| r | raid-member | The device is a member of a RAID array. |
| c | encrypted | The device is encrypted, for example with type=crypted (dm-crypt). |
| g | guid-partition-table | The device has a GUID partition table (GPT). |
| p | partition | The device is a partition of a disk. |
| t | nvme-tcp-export | The device is exported as an NVMe-over-TCP target. |
| i | iscsi-export | The device is exported as an iSCSI target. |
| s | smb-sharing | The device is shared through the built-in SMB server. |
| n | nfs-sharing | The device is shared with the NFS server. |
| m | media-sharing | The device is shared through the DLNA media server. |
| L | self-encrypted-and-locked | self-encrypted-and-locked |
| O | self-encryption-enabled | TCG-Opal self-encryption is active on the drive. |
| o | self-encryption-supported | The drive supports TCG-Opal self-encryption, but it is not enabled. |
| Argument | Type | Description |
|---|---|---|
| type ( mandatory ) | enum (raid | nvme-tcp | iscsi | nfs | smb | partition | tmpfs | ramdisk | crypted | sshfs | file | hardware) | Type of the item:
|
| slot | string | Name of the disk item, normally based on where the device is physically connected, for example nvme1 or usb1. The name is assigned automatically and can be set manually. Other commands and parent refer to the disk by this name. |
| parent | enum () | Parent device of the item. On a type=partition item it selects the hardware disk the partition is created on, for example add type=partition parent=nvme9 ...; on type=crypted it is the drive or partition that is encrypted. |
| mount-point-template | string | Template of the mount point, the folder under which the file system appears in
|
| mount-filesystem | bool | Whether the device's file system is mounted, so its files are available in /file. mount-filesystem=no unmounts the file system, which is required before /disk check or /disk repair. Default: yes. |
| mount-read-only | bool | Whether the mounted file system is read-only. Default: no. |
| compress | bool | Whether the device's file system is mounted with compression. Only supported on btrfs file systems; RouterOS reports compression only available for btrfs when it is set on other file systems. Default: no. |
| partition-number | num | Number of the partition on the parent disk, for example partition-number=1 for the first partition. |
| partition-offset | num | Start offset of the partition on the disk, in bytes. Use it to adjust where the partition begins. |
| partition-size | num | Size of the partition in bytes. When it is not set, the partition takes the remaining space on the disk. See Disks. |
| raid-type (syscap=storage) | enum (0 | 1 | 4 | 5 | 6 | linear) { 0:0, 1:1, 4:4, 5:5, 6:6 } | RAID level of the array:
|
| raid-device-count (syscap=storage) | num | Number of devices (disks) in the RAID array, set when the array is created. |
| raid-max-component-size (syscap=storage) | num | Maximum size of an individual device in the RAID array. |
| raid-chunk-size (syscap=storage) | enum (64K | 128K | 256K | 512K | 1M | 2M | 4M) { 64K:64, 128K:128, 256K:256, 512K:512, 1M:1024, 2M:2048, 4M:4096 } | Size of the chunks (stripes) written across the disks of the array, for example 1M. |
| raid-master (syscap=storage) | enum (none) | RAID block device a disk belongs to. Set it together with raid-role on the member disks to add them to an array created with add type=raid .... On the RAID item itself it is none. |
| raid-role (syscap=storage) | num | Position of the disk within the RAID array, set with raid-master, starting from 0, or spare to mark the disk as a hot spare. |
| raid-member-failed (syscap=storage) | bool | Marks a drive as failed in the RAID array. Used when a non-failed drive needs to be replaced. |
| nvme-tcp-export (syscap=storage) | bool | Whether the device is exported as an NVMe-over-TCP target, so other devices can mount it. Default: no. See NVMe over TCP. |
| nvme-tcp-server-port (syscap=storage) | num | Port on which the NVMe-over-TCP server accepts connections from initiators. See NVMe over TCP. |
| nvme-tcp-server-nqn (syscap=storage) | string | NVMe Qualified Name (NQN) of the exported device, used by initiators to connect. See NVMe over TCP. |
| nvme-tcp-server-allow-host-name (syscap=storage) | string | Hostnames allowed to connect to the NVMe-over-TCP server, for host-based access control. See NVMe over TCP. |
| nvme-tcp-server-password (syscap=storage) | string | Password the NVMe-over-TCP server requires from initiators. See NVMe over TCP. |
| nvme-tcp-address (syscap=storage) | ipAddr | IP address of the NVMe-over-TCP target (host) to mount, on the nvme-tcp client. See NVMe over TCP. |
| nvme-tcp-nqn (syscap=storage) | string | NVMe Qualified Name (NQN) of the target on the server to mount, on the nvme-tcp client. See NVMe over TCP. |
| nvme-tcp-host-name (syscap=storage) | string | Hostname the nvme-tcp initiator (client) identifies itself with; used for identification and authentication on the server. See NVMe over TCP. |
| nvme-tcp-password (syscap=storage) | string | Password used to authenticate the NVMe-over-TCP connection to the server. See NVMe over TCP. |
| nvme-tcp-port (syscap=storage) | num | Port the NVMe-over-TCP target listens on for connections from initiators. Default: 4420. See NVMe over TCP. |
| iscsi-export (syscap=storage) | bool | Whether the device is exported as an iSCSI target. Default: no. See iSCSI. |
| iscsi-server-port (syscap=storage) | num | Port the iSCSI server listens on. See iSCSI. |
| iscsi-server-iqn (syscap=storage) | string | iSCSI Qualified Name (IQN) of the iSCSI server, by default iqn.2000-02.com.mikrotik:<slot>. See iSCSI. |
| iscsi-port (syscap=storage) | num | Port the iSCSI target listens on for connections from initiators. Default: 3260. See iSCSI. |
| iscsi-address (syscap=storage) | ipAddr | IP address of the iSCSI target (host) to mount, on the iscsi client. See iSCSI. |
| iscsi-iqn (syscap=storage) | string | iSCSI Qualified Name (IQN) of the target to mount, on the iscsi client. See iSCSI. |
| nfs-sharing (syscap=storage) | bool | Whether the device is shared with NFS, so network clients can mount it. Default: no. See NFS. |
| nfs-address (syscap=storage) | ipAddr | IP address of the NFS server to mount, on the nfs client. See NFS. |
| nfs-share (syscap=storage) | string | Folder to mount on the NFS server, on the nfs client. See NFS. |
| smb-sharing | bool | Whether the device is shared through the built-in SMB server (/ip/smb) when it is mounted. With auto-smb-sharing=yes in settings it is enabled automatically. Default: no. |
| smb-server-user | enum () | SMB user of the auto-created share of this disk; the default for new disks is taken from auto-smb-user in settings. |
| smb-server-password | string | Password of the SMB user of the auto-created share. |
| smb-server-encryption | bool | Whether connections to the SMB share of this disk must be encrypted. |
| smb-address | ipAddr | IP address of the SMB server to mount, on the smb client. See SMB. |
| smb-share | string | Name of the share to mount on the server, on the smb client. See SMB. |
| smb-user | string | SMB user to authenticate with, on the smb client. See SMB. |
| smb-password | string | Password of the SMB user, on the smb client. |
| smb-encryption | bool | Whether the connection to the remote SMB share is encrypted, on the smb client. |
| media-sharing | bool | Whether the device is shared through the DLNA media server (/ip/media) when it is mounted. With auto-media-sharing=yes in settings it is enabled automatically. Default: no. |
| media-interface | iface_enum { none } | Interface the DLNA media server uses for the share of this disk, set together with media-sharing=yes. |
| tmpfs-max-size | num | Maximum size of a tmpfs folder, in decimal units (100M is 100 000 000 bytes). The folder uses RAM only for the files stored in it. When the size is not set (it reads 0), the folder can grow to about half of the RAM. RouterOS adds up the maximum sizes of all tmpfs folders, counting a folder without tmpfs-max-size as half of the RAM, and refuses a new size when the total is more than the router can provide (too much memory requested for tmpfs/ramdisk). The size in print is rounded up to whole 4 KiB memory pages. A new value applies at once, also to a mounted folder. The contents of a tmpfs are lost on reboot or power loss. See Tmpfs. Default: not set. |
| ramdisk-size (syscap=storage) | num | Size of the RAM block device created with type=ramdisk, rounded up to a multiple of 16 KiB. The RAM is not reserved when the ramdisk is added. A reboot or power loss clears it: the ramdisk stays, but empty and without a file system, so format it again. Needs the rose-storage package. See Ramdisk. |
| crypted-backend (syscap=storage) | enum (none) | The drive or partition to encrypt with type=crypted. See Encrypted storage. |
| encryption-key (syscap=storage) | string | The key used to decrypt the crypted device. See Encrypted storage. |
| self-encryption-password (syscap=storage) | string | Password that enables TCG-Opal self-encryption on a supported (SED) drive; unsetting it disables self-encryption. See Self-encrypting drives. |
| sshfs-address | string | Address (IP address or hostname) of the SSH server to mount, for type=sshfs. See SSHFS. |
| sshfs-port | num | Port of the SSH server to connect to, for type=sshfs (default: 22). See SSHFS. |
| sshfs-user | string | User to log in to the remote SSH server with, for type=sshfs. See SSHFS. |
| sshfs-password | string | Password of the remote SSH user, for type=sshfs. See SSHFS. |
| sshfs-path | string | Path on the remote SSH server to mount, for type=sshfs. See SSHFS. |
| swap | bool | Use the device as swap space. Swap is used only by containers, and its usable size is limited to 10 times the device's RAM. It applies to a whole disk or partition, or to a file with type=file. See Disks. |
| file-path | file | Path and name of the file mounted as a block device with type=file, for example a swap file (swap=yes) or a mounted .iso / .squashfs image. Removing the disk item does not delete the file. See Disks. |
| file-size | num | Size of the file, for example file-size=1G, when creating a type=file device. |
| file-offset | num | Offset in the file at which the block device starts, for example file-offset=0. |
| Read-only Argument | Type | Description |
|---|---|---|
| slot-default | string | Default slot name of the device, shown when no custom slot name is set. |
| fs-label | string | Label of the file system. Formatting sets it automatically to <slot>-fs, unless a label is given to /disk format. |
| fs-uuid | string | UUID of the file system, for example 58470fe2-.... |
| fs | enum (fat32 | ext4 | btrfs | xfs | nfs | smb | wipe | wipe-quick | tmpfs | exfat | ntfs | sshfs | squashfs | iso | discard | discard-secure | -) | File system of the device: ext4, btrfs, xfs, fat32, exfat and ntfs for local file systems, tmpfs for RAM folders, nfs, smb and sshfs for network mounts, and iso / squashfs for mounted images. - means the device has no recognised file system. The values wipe, wipe-quick, discard and discard-secure correspond to the file systems of /disk format. |
| model | string | Model name of the device, for example TS1TUTE210T. |
| serial | string | Serial number of the device. |
| fw-version | string | Firmware version of the device. |
| size | num | Total size of the device in bytes. |
| free | num | Free space on the mounted file system in bytes. |
| total-inodes | num | Total number of inodes of the file system. |
| free-inodes | num | Number of free inodes of the file system. |
| use | num | Used space of the file system in percent, for example 4%. |
| mount-point | string | Mount point of the file system, the folder under which it appears in /file, driven by mount-point-template. |
| sector-size | num | Sector size of the device, for example 512 bytes. |
| interface | string | Interface the device is connected to, for example PCIe 2x8 GT/s or USB 2.00 480Mbps. |
| interface-speed | num | Speed of the interface the device is connected to, for example 15.7Gbps. |
| raid-member-state (syscap=storage) | string | State of the disk as a member of its RAID array, for example 0:in_sync; when the disk is not part of an assembled array, the details of the RAID superblock found on it are shown instead. |
| state | string | State of a RAID array, for example clean. |
| last-seen | string | Model and serial number of the disk that last occupied this slot, shown after the disk was ejected or removed, for example TS1TUTE210T J398770033. |
| raid-uuid (syscap=storage) | string | UUID of the RAID array. |
| nvme-tcp-server-secret (syscap=storage) | string | Secret the NVMe-over-TCP server uses to authenticate connections from initiators. |
| nvme-tcp-secret (syscap=storage) | string | Secret used to authenticate the connection to the NVMe-over-TCP server. |
| sshfs-local-user | string | Local RouterOS user the SSHFS mount runs under, for example admin. Read-only. |
| io-ops | num | Total number of I/O operations on the device, as shown by monitor-traffic. |
| io-errors | num | Total number of I/O errors on the device. |
| read-ops | num | Total number of read operations. |
| read-ops-per-second | num | Number of read operations per second. |
| read-bytes | num | Total number of bytes read. |
| read-rate | num | Rate of reads, for example in bytes per second. |
| read-merges | num | Number of adjacent read operations merged. |
| read-time | time | Time spent on read operations. |
| write-ops | num | Total number of write operations. |
| write-ops-per-second | num | Number of write operations per second. |
| write-bytes | num | Total number of bytes written. |
| write-rate | num | Rate of writes, for example in bytes per second. |
| write-merges | num | Number of adjacent write operations merged. |
| write-time | time | Time spent on write operations. |
| in-flight-ops | num | Number of I/O operations currently in flight. |
| active-time | time | Time the device was busy handling requests. |
| wait-time | time | Time requests spent waiting in the queue. |
| discard-ops | num | Total number of discard (trim) operations. |
| discard-bytes | num | Total number of bytes discarded. |
| discard-merges | num | Number of adjacent discard operations merged. |
| discard-time | time | Time spent on discard operations. |
| flush-ops | num | Total number of flush operations. |
| flush-time | time | Time spent on flush operations. |
| temperature | num | Temperature of the drive in Celsius, reported by S.M.A.R.T. (storage package). See the S.M.A.R.T. info guide and smart-info. |
| temperatures | multi { array-id, slot: num } | Temperatures of the drive's sensors in Celsius, one entry per sensor slot. |
| critical-warning | ubit (spare-space, temperature, reliability-degraded, read-only, volatile-backup-failed) | Bitmask of critical warnings the drive reports: spare-space (available spare is below available-spare-threshold), temperature (temperature out of range), reliability-degraded, read-only (the device entered read-only mode) and volatile-backup-failed. |
| available-spare | num | Remaining spare blocks of the drive in percent, for example 100%. Below available-spare-threshold the drive reports a warning. |
| available-spare-threshold | num | Threshold in percent below which the available spare space of the drive is reported as a warning. |
| percentage-used | num | Estimated percentage of the drive's life used, based on how many spare blocks have been consumed. |
| host-read-bytes | num | Total number of bytes read by the host from the drive. |
| host-write-bytes | num | Total number of bytes written by the host to the drive. |
| host-read-cmds | num | Total number of read commands the host sent to the drive. |
| host-write-cmds | num | Total number of write commands the host sent to the drive. |
| controller-busy-time | time | Total time the drive controller was busy with commands. |
| power-cycles | num | Number of power cycles of the drive. |
| power-on-time | time | Total time the drive was powered on. |
| unsafe-shutdowns | num | Number of unsafe (unexpected) shutdowns of the drive. |
| unrecovered-integrity-errors | num | Number of unrecovered media and data integrity errors of the drive. |
| warning-temperature | num | Temperature in Celsius at which the drive starts reporting a warning. |
| warning-temperature-time | time | Time the drive spent above warning-temperature. |
| critical-temperature | num | Temperature in Celsius at which the drive reports a critical condition. |
| critical-temperature-time | time | Time the drive spent above critical-temperature. |