World Library  
Flag as Inappropriate
Email this Article

Virtual file system

Article Id: WHEBN0000351131
Reproduction Date:

Title: Virtual file system  
Author: World Heritage Encyclopedia
Language: English
Subject: Collaba, Operating system, Sysfs, Sysctl, Sparse file
Collection: Computer File Systems, Virtualization Software
Publisher: World Heritage Encyclopedia
Publication
Date:
 

Virtual file system

A virtual file system (VFS) or virtual filesystem switch is an abstraction layer on top of a more concrete file system. The purpose of a VFS is to allow client applications to access different types of concrete file systems in a uniform way. A VFS can, for example, be used to access local and network storage devices transparently without the client application noticing the difference. It can be used to bridge the differences in Windows, Mac OS and Unix filesystems, so that applications can access files on local file systems of those types without having to know what type of file system they are accessing.

A VFS specifies an interface (or a "contract") between the kernel and a concrete file system. Therefore, it is easy to add support for new file system types to the kernel simply by fulfilling the contract. The terms of the contract might change incompatibly from release to release, which would require that concrete file system support be recompiled, and possibly modified before recompilation, to allow it to work with a new release of the operating system; or the supplier of the operating system might make only backward-compatible changes to the contract, so that concrete file system support built for a given release of the operating system would work with future versions of the operating system.

Contents

  • Implementations 1
  • Single-file virtual file systems 2
    • Implementation of single-file virtual filesystems 2.1
      • PCTask 2.1.1
      • WinUAE 2.1.2
  • See also 3
  • Notes 4
  • References 5
  • External links 6

Implementations

The position of the VFS layer within various parts of the Linux kernel's storage stack.[1]

One of the first virtual file system mechanisms on Unix-like systems was introduced by Sun Microsystems in SunOS 2.0 in 1985. It allowed Unix system calls to access local UFS file systems and remote NFS file systems transparently. For this reason, Unix vendors who licensed the NFS code from Sun often copied the design of Sun's VFS. Other file systems could be plugged into it also: there was an implementation of the MS-DOS FAT file system developed at Sun that plugged into the SunOS VFS, although it wasn't shipped as a product until SunOS 4.1. The SunOS implementation was the basis of the VFS mechanism in System V Release 4.

John Heidemann developed a stacking VFS under SunOS 4.0 for the experimental Ficus file system. This design provided for code reuse among file system types with differing but similar semantics (e.g., an encrypting file system could reuse all of the naming and storage-management code of a non-encrypting file system). Heidemann adapted this work for use in 4.4BSD as a part of his thesis research; descendants of this code underpin the file system implementations in modern BSD derivatives including Mac OS X.

Other Unix virtual file systems include the File System Switch in System V Release 3, the Generic File System in Ultrix, and the VFS in Linux. In OS/2 and Microsoft Windows, the virtual file system mechanism is called the Installable File System.

The Filesystem in Userspace (FUSE) mechanism allows userland code to plug into the virtual file system mechanism in Linux, NetBSD, FreeBSD, OpenSolaris, and Mac OS X.

In Microsoft Windows, virtual filesystems can also be implemented through userland Shell namespace extensions; however, they do not support the lowest-level file system access application programming interfaces in Windows, so not all applications will be able to access file systems that are implemented as namespace extensions. KIO and GVFS/GIO provide similar mechanisms in the KDE and GNOME desktop environments (respectively), with similar limitations, although they can be made to use FUSE techniques and therefore integrate smoothly into the system.

Single-file virtual file systems

Sometimes Virtual File System refers to a file or a group of files (not necessarily inside a concrete file system) that acts as a manageable container which should provide the functionality of a concrete file system through the usage of software. Examples of such containers are SolFS or a single-file virtual file system in an emulator like PCTask or so-called WinUAE, Oracle's VirtualBox, Microsoft's Virtual PC, VMware.

The primary benefit for this type of file system is that it is centralized and easy to remove. A single-file virtual file system may include all the basic features expected of any file system (virtual or otherwise), but access to the internal structure of these file systems is often limited to programs specifically written to make use of the single-file virtual file system (instead of implementation through a driver allowing universal access). Another major drawback is that performance is relatively low when compared to other virtual file systems. Low performance is mostly due to the cost of shuffling virtual files when data is written or deleted from the virtual file system.

Implementation of single-file virtual filesystems

Direct examples of single-file virtual file systems include emulators, such as PCTask and WinUAE, which encapsulate not only the filesystem data but also emulated disk layout. This makes it easy to treat an OS installation like any other piece of software—transferring it with removable media or over the network.

PCTask

The Amiga emulator PCTask emulated an Intel PC 8088 based machine clocked at 4.77MHz (and later an 80486SX clocked at 25 MHz). Users of PCTask could create a file of large size on the Amiga filesystem, and this file would be virtually accessed from the emulator as if it were a real PC Hard Disk. The file could be formatted with the FAT16 filesystem to store normal MS-DOS or Windows files.[1][2]

WinUAE

The UAE for Windows, WinUAE, allows for large single files on Windows to be treated as Amiga file systems. In WinUAE this file is called a hardfile.[3]

UAE could also treat a directory on the host filesystem -- (Windows, Linux, Mac OS, AmigaOS) -- as an Amiga filesystem.[4]

See also

  • 9P (protocol) – a distributed file system protocol that maps directly to the VFS layer of Plan 9, making all file system access network-transparent

Notes

  1. ^ Emulation on Amiga Comparison between PCX and PCTask, Amiga PC emulators.
  2. ^ See also This article explaining how it works PCTask.
  3. ^ Help About WinUAE (See Hardfile section).
  4. ^ Help About WinUAE (See Add Directory section)

References

  1. ^ Werner Fischer; Georg Schönberger (2015-06-01). "Linux Storage Stack Diagram". Thomas-Krenn.AG. Retrieved 2015-06-08. 
  • Vnodes: An Architecture for Multiple File System Types in Sun UNIX
  • Linux kernel's Virtual File System
  • Rodriguez, R.; M. Koehler; R. Hyde (June 1986). "The Generic File System". Proceedings of the USENIX Summer Technical Conference. Atlanta, Georgia:  
  •  
  • Heidemann, John (1995). Stackable Design of File Systems (Technical report).  
  • The Linux VFS, Chapter 4 of Linux File Systems by Moshe Bar (McGraw-Hill, 2001). ISBN 0-07-212955-7
  • Chapter 12 of Understanding the Linux Kernel by Daniel P. Bovet, Marco Cesati (O'Reilly Media, 2005). ISBN 0-596-00565-2
  • The Linux VFS Model: Naming structure

External links

  • AVFS - A Virtual File System for mounting compressed or remote files
  • fs-driver Ext2 Installable File System for Microsoft Windows
  • Anatomy of the Linux file system by M. Tim Jones
  • Solid File System - (SolFS) cross-platform single-file virtual file system with encryption and compression
  • Callback File System - SDK that lets developers create virtual file systems for Windows in user mode
  • FUSE - Filesystem in Userspace - virtual filesystem for Linux.
  • LUFS - Linux Userland Filesystem - virtual filesystem with support of localfs, sshfs, ftpfs, gnutellafs, locasefs, gvfs, cardfs, cefs and more. Latest file release: 2003-10-29
  • TrueVFS - Virtual File System for Java, with thread-safe read/write access to ZIP, ZIP.RAES, TAR, TAR.BZ2, TAR.GZ, TAR.XZ, ODF, HTTP(S) etc.
  • Commons VFS - virtual filesystem for Java, with support for Cifs, ftp, http, Zip (file format), Tar (file format), gzip, bzip2, and more.
  • MillScript VFS - virtual filesystem for Java, influenced by the KIO subsystem in KDE, Steve Leach's work on a VFS in JSpice and to a limited extent the Apache Commons VFS.
  • KIO - (KDE IO) - a network-enabled file management system
  • flipcode - Programming a Virtual File System
  • Dokan - A free and open source virtual filesystem for Windows (includes C, .NET, and Ruby bindings).
  • JPfm - a cross-platform virtual filesystem in user space library written in java.
This article was sourced from Creative Commons Attribution-ShareAlike License; additional terms may apply. World Heritage Encyclopedia content is assembled from numerous content providers, Open Access Publishing, and in compliance with The Fair Access to Science and Technology Research Act (FASTR), Wikimedia Foundation, Inc., Public Library of Science, The Encyclopedia of Life, Open Book Publishers (OBP), PubMed, U.S. National Library of Medicine, National Center for Biotechnology Information, U.S. National Library of Medicine, National Institutes of Health (NIH), U.S. Department of Health & Human Services, and USA.gov, which sources content from all federal, state, local, tribal, and territorial government publication portals (.gov, .mil, .edu). Funding for USA.gov and content contributors is made possible from the U.S. Congress, E-Government Act of 2002.
 
Crowd sourced content that is contributed to World Heritage Encyclopedia is peer reviewed and edited by our editorial staff to ensure quality scholarly research articles.
 
By using this site, you agree to the Terms of Use and Privacy Policy. World Heritage Encyclopedia™ is a registered trademark of the World Public Library Association, a non-profit organization.
 



Copyright © World Library Foundation. All rights reserved. eBooks from World Library are sponsored by the World Library Foundation,
a 501c(4) Member's Support Non-Profit Organization, and is NOT affiliated with any governmental agency or department.