mmove
Atomically move files and directories
SYNOPSIS
mmove [options] source [source ...] destination
PARAMETERS
-v
Verbose output.
Displays the name of each file or directory as it is moved or renamed.
-a
Ask before overwriting.
Prompts the user for confirmation before overwriting an existing destination file.
-p
Preserve attributes.
Attempts to preserve the original file's modification date and time during the move operation.
-o
Overwrite without prompting.
Overwrites an existing destination file without asking for user confirmation.
-n
No overwrite.
If the destination file already exists, the move operation is skipped, and the existing file is not overwritten.
-N
Long to short filename conversion.
If the source filename is a long filename and the destination filesystem does not support it, mmove attempts to convert it to a short (8.3) filename.
DESCRIPTION
mmove is a utility from the mtools suite designed to move and rename files and directories on MS-DOS filesystems from a Linux environment. It functions similarly to the standard Unix mv command but is specifically tailored for MS-DOS conventions, including the 8.3 filename limit and case-insensitivity during lookup (though often preserving original case for display).
This command is invaluable for interacting with legacy media like floppy disks or disk images formatted with MS-DOS, or for systems that require direct manipulation of MS-DOS partitions without full kernel-level mounting. It supports wildcard characters for moving multiple files and can move files between different MS-DOS drives or rename them within the same directory. mmove typically handles file attributes like modification times, depending on the options used.
CAVEATS
mmove strictly operates on MS-DOS filesystems and does not function on native Linux filesystems. It adheres to MS-DOS file naming rules (e.g., 8.3 character limit, case-insensitivity in lookup) and does not support advanced Linux filesystem features like permissions, symbolic links, or hard links. Proper configuration of MS-DOS drive letters via the mtools configuration file (e.g., ~/.mtoolsrc) is essential for specifying target drives (e.g., 'a:', 'c:').
MS-DOS DRIVE SPECIFICATION
When using mmove to move files to or from different MS-DOS drives, these drives are specified using a drive letter followed by a colon (e.g., a:, c:). The mapping of these drive letters to actual devices or partitions on the Linux system is typically configured in the mtools configuration file.
WILDCARD SUPPORT
mmove supports standard MS-DOS wildcard characters in the source path. These include * (which matches any sequence of characters) and ? (which matches any single character), allowing for batch moving or renaming of multiple files.
HISTORY
The mtools suite, including mmove, emerged to bridge the gap between Unix-like operating systems and MS-DOS filesystems. Its development began in an era when floppy disks were prevalent and seamless file exchange with MS-DOS was a common requirement. mtools provided direct access to MS-DOS media without requiring kernel-level drivers to mount them, offering a convenient command-line interface. While less critical for modern desktop Linux due to improved kernel support for FAT filesystems, mtools and mmove remain valuable tools for legacy systems, forensic analysis, or embedded environments that still rely on MS-DOS partitions.