mtools: Working with Floppies on UNIX

Marius Nita

CS Tutors - Portland State Universiry

September 22, 2005

Introduction

mtools is a set of UNIX tools which facilitate access to DOS and Windows floppy disks on our SPARC systems in the UNIX lab. In essence, the floppy disk can be queried and files can be copied back and forth between the floppy and a UNIX user account, all via a set of Unix tools which simulate the DOS command set.

Getting started

First, the mtools package must be added. This is done via the addpkg system, by running the command addpkg mtools, logging out, and logging back in. To see a listing of all the available mtools commands, type mtools at the command line. Output such as the following should be listed:

Supported commands:
mattrib, mbadblocks, mcd, mcopy, mdel, mdeltree, mdir, mformat
minfo, mlabel, mmd, mmount, mpartition, mrd, mread, mmove
mren, mtoolstest, mtype, mwrite, mzip
Most of the listed command correspond to well known DOS commands, such as attrib, cd, copy, etc., and behave similarly.

mtools commands

Some commands, such as mcopy, can take as arguments file names for files which may reside on both the floppy or the UNIX file system. In the former case, the file must be prefixed with the drive name and path, such as a:/foo/bar.txt. In the latter, a normal UNIX path should be specified, such as foo.txt or foo/bar.txt.

A brief and incomplete list of commands will be given here:

Further help

Users are encouraged to read the mtools manual page, by typing man mtools at the command prompt. Further help can be obtained by emailing CS tutors at tutors@cs.pdx.edu or joining our chat channel, #cschat on irc.cat.pdx.edu.