Welcome to Linux Knowledge Base and Tutorial
"The place where you learn linux"
Linux Magazine: The source for advanced Linux know-how

 Create an AccountHome | Submit News | Your Account  

Tutorial Menu
Linux Tutorial Home
Table of Contents

· Introduction to Operating Systems
· Linux Basics
· Working with the System
· Shells and Utilities
· Editing Files
· Basic Administration
· The Operating System
· The X Windowing System
· The Computer Itself
· Networking
· System Monitoring
· Solving Problems
· Security
· Installing and Upgrading
· Linux and Windows

Man Pages
Linux Topics
Test Your Knowledge

Site Menu
Site Map
Copyright Info
Terms of Use
Privacy Info
Masthead / Impressum
Your Account

Private Messages

News Archive
Submit News
User Articles
Web Links


The Web

Who's Online
There are currently, 67 guest(s) and 0 member(s) that are online.

You are an Anonymous user. You can register for free by clicking here




UMSDOS HOW-TO: Basic principle Next Previous Contents

6. Basic principle

6.1 Introduction

Umsdos map Linux files directly to Ms-DOS files. This is a one for one translation. File content is not manipulated at all. Umsdos only works on names. For special files (links and devices for example), it introduces special management.

For each directory, there is a file named --linux-.---.

6.2 Umsdos can replace the Ms-DOS file-system.

Umsdos can be thought as a general purpose superset of the Ms-DOS file system of linux. In fact this capability or flexibility yields much confusion about Umsdos. Here is why. Try to mount a newly formatted DOS floppy like this.

        mount -t umsdos /dev/fd0 /mnt

And do this,

        ls / >/mnt/LONGFILENAME
        ls -l /mnt

You will get the following result

        -rwxr-xr-x   1 root     root          302 Apr 14 23:25 longfile

So far, it seems that the Umsdos file system does not do much more (in fact nothing at all) than the normal Ms-DOS file system of Linux.


6.3 Directory promotion

Pretty unimpressive so far. Here is the trick. Unless promoted a DOS directory will be managed the same way with Umsdos than the Ms-DOS file-system will. Umsdos use a special file in each subdirectory to achieve the translation between the extended capabilities (long name, ownership, etc...) of Umsdos and the limitation of the DOS file-system. This file is invisible to Umsdos users, but visible when you boot DOS. To avoid cluttering the DOS partition with those file (--linux-.---) uselessly, the file is now optional. If absent, Umsdos behave like Ms-DOS.

When a directory is promoted, any subsequent operation will be done with the full semantic normally available to Unix and Linux users. And all subdirectory created afterward will be silently promoted.

This feature allows you to logically organize your DOS partition into DOS stuff and Linux stuff. It is important to understand that those --linux-.--- file do take some place (generally 2k per directory). DOS generally use large cluster (as big as 16k for a 500meg partition), so avoiding putting --linux-.--- everywhere can save your day.

6.4 How to promote: /sbin/umssync

A directory can be promoted any time using /sbin/umssync. It can be used at any time. Promoting a directory do the following operation

  • Create a --linux-.---.
  • Establish a one to one relation between the --linux-.--- and the current content of the directory.

/sbin/umssync maintain an existing --linux-.--- file. It does not create it from scratch all the time. It simply add missing entries in it (Files created during a DOS session). It will also removed files which do not exist anymore in the DOS directory from the --linux-.---. umssync gets its name from that. It put --linux-.--- in sync with the underlying DOS directory.

6.5 Using /sbin/umssync at boot time

It is a good idea to place a call to /sbin/umssync at the end of your /etc/rc.d/rc.S if it's not there. The following command is adequate for most system:

        /sbin/umssync -r99 -c -i+ /

The -c option prevent umssync from promoting directories. It will only update existing --linux-.---.

This command is useful if you access Linux directory during a DOS session. Linux has no efficient way to tell that a directory has been modified by DOS so Umsdos can't do a umssync operation as needed.

6.6 How to UN-promote

Remove the --linux-.--- file using DOS. You will be sorry.

6.7 What about files created during a DOS session ?

Unless you use umssync on a directory where files have been added or removed by DOS, you will notice some problems:

  • It won't crash the system nor it won't cause major problems, only annoyance :-)
  • Files created by DOS.
    • They will be invisible in Linux.
    • When trying to create a file with the same name, you will get an error message stating that the file already exist.
    • This creates more confusion that real problem. It does not harm the file system.
  • Files deleted by DOS won't cause problem. Umsdos will notice the absence at the first access. A message will be output (and generally written into /var/adm/syslog).

Next Previous Contents

The Linux Tutorial completely respects the rights of authors and artists to decide for themselves if and how their works can be used, independent of any existing licenses. This means if you are the author of any document presented on this site and do no wish it to be displayed as it is on this site or do not wish it to be displayed at all, please contact us and we will do our very best to accommodate you. If we are unable to accommodate you, we will, at your request, remove your document as quickly as possible.

If you are the author of any document presented on this site and would like a share of the advertising revenue, please contact us using the standard Feedback Form.

Show your Support for the Linux Tutorial

Purchase one of the products from our new online shop. For each product you purchase, the Linux Tutorial gets a portion of the proceeds to help keep us going.



Security Code
Security Code
Type Security Code

Don't have an account yet? You can create one. As a registered user you have some advantages like theme manager, comments configuration and post comments with your name.

Help if you can!

Amazon Wish List

Did You Know?
The Linux Tutorial welcomes your suggestions and ideas.


Tell a Friend About Us

Bookmark and Share

Web site powered by PHP-Nuke

Is this information useful? At the very least you can help by spreading the word to your favorite newsgroups, mailing lists and forums.
All logos and trademarks in this site are property of their respective owner. The comments are property of their posters. Articles are the property of their respective owners. Unless otherwise stated in the body of the article, article content (C) 1994-2013 by James Mohr. All rights reserved. The stylized page/paper, as well as the terms "The Linux Tutorial", "The Linux Server Tutorial", "The Linux Knowledge Base and Tutorial" and "The place where you learn Linux" are service marks of James Mohr. All rights reserved.
The Linux Knowledge Base and Tutorial may contain links to sites on the Internet, which are owned and operated by third parties. The Linux Tutorial is not responsible for the content of any such third-party site. By viewing/utilizing this web site, you have agreed to our disclaimer, terms of use and privacy policy. Use of automated download software ("harvesters") such as wget, httrack, etc. causes the site to quickly exceed its bandwidth limitation and are therefore expressly prohibited. For more details on this, take a look here

PHP-Nuke Copyright © 2004 by Francisco Burzi. This is free software, and you may redistribute it under the GPL. PHP-Nuke comes with absolutely no warranty, for details, see the license.
Page Generation: 0.79 Seconds