mirror of
https://github.com/webmin/webmin.git
synced 2026-02-09 08:42:20 +00:00
484 lines
20 KiB
HTML
484 lines
20 KiB
HTML
<title>Filesystem Manager</title>
|
|
<body bgcolor=#ffffff>
|
|
<center><img src="images/mount.gif"></center><p>
|
|
<h2><i>This help page is incomplete</i></h2>
|
|
|
|
<hr>
|
|
<h3>Introduction</h3>
|
|
The purpose of this module is to simplify mounting of local disks,
|
|
remote file shares and virtual memory. Before a Unix system can access
|
|
files on any hard disk, CDROM, Jaz drive, floppy disk or file server
|
|
it must be <tt>mounted</tt> at some point in the filesystem. The system
|
|
keeps a list of filesystems that it knows about, typically to mount at
|
|
bootup time. Filesystems can also be mounted temporarily, to be forgotten
|
|
about when they are unmounted or the system is rebooted. <p>
|
|
|
|
All Unix systems when installed will mount at least one filesystem
|
|
at bootup time, and almost certainly more. There will always be one
|
|
filesystem mounted as the root directory <tt>/</tt>, and maybe others
|
|
as <tt>/usr</tt>, <tt>/proc</tt> or <tt>/net</tt>. Unless your Unix
|
|
system is a diskless workstation, the root directory will be mounted
|
|
from a local hard disk. Others filesystems may be mounted from file
|
|
servers, local disks or even be 'magic' filesystems like <tt>/proc</tt>
|
|
that do not contain real files. <p>
|
|
|
|
One special case is virtual memory. Your system should always have at
|
|
least one virtual memory swap file, which is used by the OS as an
|
|
extension of physical memory. A swap file can either be a normal file
|
|
in some filesystem, or a dedicated partition on a local disk. <p>
|
|
|
|
This module works by reading and updating the file <tt>/etc/fstab</tt> or
|
|
<tt>/etc/vfstab</tt> to manage known filesystems. Currently mounted
|
|
filesystems are found by reading the file <tt>/etc/mtab</tt> or
|
|
<tt>/etc/mnttab</tt>. Webmin will totally ignore any comments in the
|
|
known filesystems table. <p>
|
|
|
|
<hr>
|
|
<h3>Listing Current Filesystems</h3>
|
|
The main page of the <tt>Filesystem Manager</tt> module lists all the
|
|
known filesystems. For each filesystem, the following details will be
|
|
displayed :
|
|
<ul>
|
|
<li><b>Mount point</b><br>
|
|
The directory at which this filesystem is mounted, or
|
|
<i>Virtual Memory</i> if this is a swap file. Only one
|
|
filesystem can be mounted at one mount point. <p>
|
|
|
|
<li><b>Filesystem type</b><br>
|
|
The full name of this filesystem type. This depends on the
|
|
type of mount (local or remote) and how the disk was formatted.
|
|
Mounts from local disks have types like <tt>Linux Native
|
|
Filesystem</tt>, <tt>MS-DOS Filesystem</tt> or <tt>Solaris Unix
|
|
Filesystem</tt>. Remote mounts will almost always have the
|
|
type <tt>Network Filesytem</tt>. <p>
|
|
If you want to use the short names for filesystem types
|
|
(such as <tt>ext2fs</tt> instead of <tt>Linux Native
|
|
Filesystem</tt>), change the <tt>Use long filesystem types</tt>
|
|
option in the <a href="../config.cgi?mount">module options</a>.<p>
|
|
|
|
<li><b>Mounted from</b><br>
|
|
The device file or remote system name and directory that this
|
|
filesystem was mounted from. Under Unix, all local disks have
|
|
a device file in the <tt>/dev/</tt> directory that is used
|
|
to access that disk. Device files have pathnames like
|
|
<tt>/dev/dsk/c0t1d0s3</tt> or <tt>/dev/hda1</tt>. When you
|
|
edit or create a mount, Webmin will covert the device file name
|
|
to a disk and partition number automatically. <p>
|
|
|
|
<li><b>In use?</b><br>
|
|
Yes if this filesystem is currently mounted, No if not. <p>
|
|
|
|
<li><b>Permanent?</b><br>
|
|
Yes if this filesystem is permanently recorded, no if it will
|
|
be forgotten when unmounted. <p>
|
|
</ul><p>
|
|
|
|
<hr>
|
|
<h3>Adding a New Filesystem</h3>
|
|
To add a new mount, choose the filesystem type from the selector
|
|
below the list of existing mounts. This will display a form for entering
|
|
the mount point, mount source and other options for the new mount. Each
|
|
filesystem type for each Unix version has a different set of options,
|
|
and many types have different possibilities for mount sources. <p>
|
|
|
|
No matter what filesystem type you choose, some inputs will be the same
|
|
on the <tt>Create Mount</tt> form. The most important is the mount
|
|
point, which is the directory at which the filesystem is to be mounted.
|
|
All filesystem types except virtual memory require you to enter this.
|
|
If the directory you enter does not exist, Webmin will attempt to create
|
|
it for you. <p>
|
|
|
|
For most types of filesystem you will have 3 options for saving the mount :
|
|
<ul>
|
|
<li><b>Save and mount at boot</b><br>
|
|
The mount will be recorded permanently, and mounted at bootup
|
|
time when the system is started. <p>
|
|
<li><b>Save</b><br>
|
|
The mount will be permanent, but not mounted at boot time. <p>
|
|
<li><b>Don't save</b><br>
|
|
The mount will only be temporary. <p>
|
|
</ul><p>
|
|
|
|
For most filesystem types, you can also choose whether to mount now or
|
|
not. Choosing not to mount or save a new filesystem is pointless, and
|
|
will display an error. <p>
|
|
|
|
There are however some types of filesystem which will not present all the
|
|
options listed above. Some examples are :
|
|
<ul>
|
|
<li><tt>Virtual Memory</tt> under Linux<br>
|
|
Whenever this type is mounted it is saved, and whenever it is
|
|
unmounted it is deleted. Saved VM mounts are always added at
|
|
bootup time. <p>
|
|
<li><tt>Windows Networking</tt> under Linux<br>
|
|
This filesystem type can only be mounted using the
|
|
<tt>smbmount</tt> command, so cannot be saved. <p>
|
|
<li><tt>Automounter Filesystems</tt><br>
|
|
Permanent Automounter filesystems are always mounted at boot
|
|
time. <p>
|
|
</ul><p>
|
|
|
|
All filesystem types require you to choose the mount source and mount
|
|
options. Because the source and options differ significantly between
|
|
different Unix flavours and filesystem types they are described
|
|
individually in the list below :
|
|
<ul>
|
|
<li><b>Redhat Linux 4.0+</b> and <b>Slackware Linux 3.0+</b><br>
|
|
For most Linux filesystem types, the mount source can be
|
|
one of the following :
|
|
<ul>
|
|
<li><b>IDE device</b><br>
|
|
For this choice you must enter the IDE device letter
|
|
and partition. The device letter is typically <tt>a</tt>
|
|
for the 1st internal hard disk, <tt>b</tt> for the 2nd
|
|
internal disk, and <tt>c</tt> for the CD-ROM. The
|
|
partition number depends on which partition you want
|
|
to mount. Use the <tt>fdisk</tt> command to see the
|
|
available partitionson your disks. <p>
|
|
<li><b>SCSI device</b><br>
|
|
For this option you must enter the SCSI device letter
|
|
and partition. The device letter does NOT correspond
|
|
to the SCSI target number - each SCSI device is assigned
|
|
a letter by Linux in the order they are found by the OS.
|
|
<p>
|
|
<li><b>Floppy disk</b><br>
|
|
This choice only requires you to enter the floppy device
|
|
number. This will be <tt>0</tt> for your primary drive
|
|
or <tt>1</tt> for the secondary. <p>
|
|
<li><b>Other device</b><br>
|
|
If you choose this option, you can type in any device
|
|
pathname that you want to mount. This is useful for
|
|
mounting other RAOD devices, PCMCIA cards and other paths
|
|
that Webmin doesn't know about. <p>
|
|
</ul><p>
|
|
Before a filesystem on a local IDE or SCSI disk partition
|
|
can be mounted, the partition must have been created and a
|
|
filesystem built on it. The <a href=/fdisk/>Partition
|
|
Manager</a> module can be used to do this, or you can use
|
|
the Linux <tt>fdisk</tt> and <tt>mkfs</tt> commands. <p>
|
|
|
|
The <tt>Network Filesystem (nfs)</tt>, <tt>Windows Networking
|
|
Filesystem (smbfs)</tt>, <tt>Automounter Filesystem (auto)</tt>
|
|
and <tt>Virtual Memory (swap)</tt> mount types use a different
|
|
form for the mount source. See the section about that filesystem
|
|
type below for more details. <p>
|
|
|
|
Once you have chosen the mount source, you can also set various
|
|
filesystem-specific options. Some options however are common
|
|
to almost all Linux filesystems. They are : <br>
|
|
<table border>
|
|
<tr> <td><b>Read-only</b></td>
|
|
<td>If yes, then nobody can write, create, delete or change
|
|
anything on this filesystem</td> </tr>
|
|
<tr> <td><b>Allow SUID files</b></td>
|
|
<td>If no, then setuid programs on this filesystem will not
|
|
be run as their owner. Useful when mounting remote filesystems
|
|
that you don't trust</td> </tr>
|
|
</table><p>
|
|
|
|
The filesystem-specific options are :
|
|
<ul>
|
|
<li><b>Linux Native Filesystem (ext2fs)</b><br>
|
|
This is the latest filesystem type for local hard
|
|
disks on Linux. <br>
|
|
The following additional options are available :
|
|
<table border>
|
|
</table><p>
|
|
|
|
<li><b>Network Filesystem (nfs)</b><br>
|
|
NFS is the standard Unix way of sharing files between
|
|
systems. For NFS, the mount source is not a local disk
|
|
but instead a hostname and remote directory. The hostname
|
|
is the name (or IP address) of the system you want to
|
|
mount from. The remote directory is a directory on the
|
|
remote system that is exported to your system. <br>
|
|
|
|
NFS filesystems have the following additional options :
|
|
<table border>
|
|
<tr> <td><b>NFS version</b></td>
|
|
<td>The version of NFS (1-3) to use</td> </tr>
|
|
</table><p>
|
|
|
|
<li><b>Virtual Memory (swap)</b><br>
|
|
The mount source for virtual memory can be a local IDE
|
|
disk, SCSI disk or normal file. If you enter a filename
|
|
that does not exist, Webmin will ask for the size of
|
|
the swap file to create and then add it as swap.
|
|
Unless your Linux
|
|
kernel has been configured to allow it, a swap cannot be
|
|
on an NFS mounted filesystem. <br>
|
|
There are no options for virtual memory mounts. <p>
|
|
|
|
<li><b>Windows Networking Filesystem (smbfs)</b><br>
|
|
Windows networking refers to the file sharing protocol
|
|
used by Samba, Windows 95 and NT (also known as SMB
|
|
or LANManager). If a Windows fileserver is sharing a
|
|
directory, you can mount it under Linux and access the
|
|
contents as normal files. <p>
|
|
|
|
The mount source for a Windows networking filesystem
|
|
is a share name like <tt>\\ntbox\somedir</tt>. The first
|
|
part is the NetBIOS name of the server, and the second
|
|
the name of a share on the server. Ideally a server's
|
|
NetBIOS name should be the same as its TCP/IP hostname,
|
|
but if not you can use the mount options to specify
|
|
the correct hostname or IP address to connect to.<br>
|
|
The following options are available :
|
|
<table border>
|
|
<tr> <td><b>Username</b></td>
|
|
<td>The username to login to the fileserver with. Not
|
|
needed for public shares</td> </tr>
|
|
<tr> <td><b>Password</b></td>
|
|
<td>The password used with the username. If you do not
|
|
have a valid username and password on the server then the
|
|
mount will fail. Not needed for public shares</td> </tr>
|
|
</table><p>
|
|
|
|
<li><b>MS-DOS Filesystem (fat)</b><br>
|
|
Floppy or hard disks formatted under Windows 3.1 and
|
|
versions of MS-DOS before 7.0 use this filesystem type.
|
|
Files in this filesystem are limited to the 8.3 filename
|
|
standard used by DOS. If you try to create a file with
|
|
a longer name, it will be truncated to the 8.3 format.
|
|
Because DOS has no concept of file ownership or real
|
|
file permissions, all files in the mounted directory
|
|
will have the same owner and access mode. The ownership
|
|
or rights of individual files cannot be changed. <br>
|
|
The following options are available :
|
|
<table border>
|
|
</table><p>
|
|
|
|
<li><b>Windows 95 Filesystem (vfat)</b><br>
|
|
This filesystem is found on disks formatted by Windows 95
|
|
and possibly NT. Like the MS-DOS filesystem above it has
|
|
no concept of file ownership or permissions. However, it
|
|
can support long filenames. <br>
|
|
Available options are :
|
|
<table border>
|
|
</table><p>
|
|
|
|
<li><b>ISO9660 Filesystem (iso9660)</b><br>
|
|
This is the standard format for CD-ROMs. The basic format
|
|
only supports 8.3 filenames like <tt>fat</tt>, but there
|
|
is an extended format called Rock Ridge that allows
|
|
files to have long names and Unix permissions.<br>
|
|
The options for this filesystem are :
|
|
<table border>
|
|
</table><p>
|
|
|
|
<li><b>OS/2 Filesystem (hpfs)</b><br>
|
|
Hard disks formatted by OS/2 use this filesystem format.
|
|
Long filenames are supported, but Unix permissions and
|
|
file ownership are not.<br>
|
|
Available options are :
|
|
<table border>
|
|
</table><p>
|
|
|
|
<li><b>Linux on MS-DOS Filesystem (umsdos)</b><br>
|
|
This filesystem is used only for installing Linux
|
|
on a system has only an MS-DOS filesystem, and cannot
|
|
be re-partitioned. It works by using the directory
|
|
\linux on the DOS filesystem as the root for the
|
|
Linux filesystem. When mounted under Linux, long
|
|
filenames, file ownership and permissions are supported.
|
|
This filesystem is not supported by default in
|
|
RedHat Linux, and should only be used if you have no
|
|
other option as performance is poor. <br>
|
|
The valid options for <tt>umsdos</tt> are :
|
|
<table border>
|
|
</table><p>
|
|
|
|
</ul><p>
|
|
|
|
<li><b>Solaris 2.5+</b><br>
|
|
For disk-based Solaris filesystems, the mount source can
|
|
be one of :
|
|
<ul>
|
|
<li><b>SCSI Disk</b><br>
|
|
Under Solaris, every SCSI disk is identified
|
|
by 4 numbers:
|
|
<ul>
|
|
<li><b>Controller</b> - The SCSI controller the
|
|
disk is connected to. Always 0 for the built-in
|
|
controller on Sparc boxes.<br>
|
|
<li><b>Target</b> - The SCSI unit number. For
|
|
internal hard drives this is 0 or 1. For
|
|
external drives it is typically settable by
|
|
a selector on the drive box.<br>
|
|
<li><b>Unit</b> - Almost always 0.<br>
|
|
<li><b>Partition</b> - The number of the partition
|
|
to mount.<br>
|
|
</ul><p>
|
|
<li><b>MetaDisk Device</b><br>
|
|
If you have striped, mirrored or RAIDed devices
|
|
created using Sun's Metadevice software, choose
|
|
this option and enter the Metadevice number. <p>
|
|
<li><b>Other Device</b><br>
|
|
This choice requires you to enter the full path
|
|
to the device file to mount. <p>
|
|
</ul><p>
|
|
Before a filesystem on a local SCSI disk can be mounted,
|
|
the partition must be setup and a filesystem built on it.
|
|
The <a href=/format/>Partition Manager</a> module can be
|
|
used to do this, or you can use the <tt>format</tt> and
|
|
<tt>newfs</tt> Unix commands. <p>
|
|
|
|
Under Solaris, CDROMs and floppy disks are mounted automatically
|
|
by the volume manager. Unless this has been disabled, floppies
|
|
and CDROMs never need to be manually mounted. Devices mounted
|
|
by the volume manager are not displayed in the list of mounted
|
|
filesystems on the main page. This may also apply to removable
|
|
SCSI devices (such a Jaz or Syquest drives), depending on
|
|
how volume management is set up on your system. <p>
|
|
|
|
Once the filesystem mount source has been chosen, you can also
|
|
set a number of filesystem-specific options :
|
|
<ul>
|
|
<li><b>Solaris Unix Filesystem (ufs)</b><br>
|
|
This is the standard filesystem type used by Solaris
|
|
for local disks. <br>
|
|
The available options are :
|
|
<table border>
|
|
<tr> <td><b>Read-only</b></td>
|
|
<td>If yes, then nobody can write, create, delete or
|
|
chmod anything on this filesystem</td> </tr>
|
|
</table><p>
|
|
|
|
<li><b>Network Filesystem (nfs)</b><br>
|
|
NFS is the standard Unix way of sharing files between
|
|
systems. For NFS, the mount source is not a local disk
|
|
but instead a hostname and remote directory. The hostname
|
|
is the name (or IP address) of the system you want to
|
|
mount from. The remote directory is a directory on the
|
|
remote system that is exported to your system. <br>
|
|
|
|
NFS filesystems have the following additional options :
|
|
<table border>
|
|
</table><p>
|
|
|
|
<li><b>Virtual Memory (swap)</b><br>
|
|
The mount source for virtual memory can be a SCSI disk,
|
|
MetaDisk device or normal file. If you enter a filename
|
|
that does not exist, Webmin will ask you for the size of
|
|
the swap file to create. Once the file is created, it
|
|
will be mounted as swap. <br>
|
|
There are no options for Virtual Memory mounts. <p>
|
|
|
|
<li><b>Caching Filesystem (cachefs)</b><br>
|
|
This filesystem uses space on a local disk to cache
|
|
files from another filesystem, typically NFS. This
|
|
means that commonly accessed files from an NFS server
|
|
are kept locally, resulting in a significant speedup.
|
|
When you create a new Caching Filesystem mount, Webmin
|
|
assumes that the back filesystem is of type NFS. <p>
|
|
|
|
The mount source for <tt>cachefs</tt> filesystems is the
|
|
NFS server and directory to cache. ???
|
|
When you mount a Caching filesystem, two mounts are
|
|
really made - the back mount and the <tt>cachefs</tt>
|
|
mount on the actual directory. Webmin does not show back
|
|
mounts on the list of mounted filesystems. <p>
|
|
|
|
<tt>cachefs</tt> uses a cache directory to store
|
|
cached files, specified in the mount options. You can
|
|
either use the <tt>cfsadmin</tt> Unix command to create
|
|
a cache directory with the parameters you want, or let
|
|
Webmin set it up automatically. In the latter case, the
|
|
cache will be limit to 10% of the size of the filesystem
|
|
it is on. <br>
|
|
Valid options for this filesystem are:
|
|
<table border>
|
|
</table><p>
|
|
|
|
<li><b>Ram Disk Filesystem (tmpfs)</b><br>
|
|
Files stored in a filesystem of this type exist only
|
|
in RAM, and are lost when unmounted or the system is
|
|
rebooted. The <tt>/tmp</tt> directory in Solaris uses
|
|
this filesystem type. Because it is stored only in
|
|
memory, there is no mount source section of the
|
|
filesystem form. <br>
|
|
The only option is :
|
|
<table border>
|
|
</table><p>
|
|
|
|
<li><b>Automounter Filesystem (autofs)</b><br>
|
|
The Automounter does automatic mounting and unmounting
|
|
of NFS directories on demand. A subdirectory under an
|
|
automounter directory will come into existance and
|
|
mount a file server when the user first refers to it,
|
|
such as by cd'ing into the subdirectory. After some idle
|
|
time, the subdirectory will be unmounted an disappear. <p>
|
|
|
|
The mount source for filesystems of this type has 3
|
|
different options :
|
|
<ul>
|
|
<li><b>All NFS Servers (-net)</b><br>
|
|
When the user cd's into a subdirectory, it is
|
|
taken as the hostname of an NFS server. If
|
|
this server exists, all the available exports
|
|
from the server will be mounted under the
|
|
new subdirectory. <br>
|
|
Solaris by default has the <tt>/net</tt>
|
|
directory mounted with this source, so a user
|
|
can do something like<br>
|
|
<tt>cd /net/bar.foo.com/usr/local/bin</tt><br>
|
|
<tt>ls -l</tt><p>
|
|
<li><b>XFN Server (-xfn)</b><br>
|
|
No idea??? <p>
|
|
<li><b>Automounter map</b><br>
|
|
For this option, the name of an NIS map or
|
|
local file containing an automounter map
|
|
must be given. The configuration of which
|
|
servers and directories to mount is specified
|
|
in this map. For more information, see the
|
|
<tt>automount</tt> man page. <p>
|
|
</ul><p>
|
|
The options for automounter filesystems are the same
|
|
as those for NFS. These options apply to the automatically
|
|
mounted subdirectories inside the automount directory. <p>
|
|
|
|
<li><b>MS-DOS Filesystem (pcfs)</b><br>
|
|
Disks formatted under MS-DOS use this filesystem. Files
|
|
in are limited to 8.3 filenames, and have no Unix
|
|
ownership or permissions. Typically, you will never
|
|
need to use Webmin to mount <tt>pcfs</tt> filesystem
|
|
floppy, as they are handled automatically by the volume
|
|
management system. <br>
|
|
The options available for MS-DOS filesystems are :
|
|
<table border>
|
|
</table><p>
|
|
|
|
<li><b>CDROM Filesystem (hsfs)</b><br>
|
|
|
|
|
|
</ul><p>
|
|
</ul><p>
|
|
|
|
<hr>
|
|
<h3>Editing an Existing Filesystem</h3>
|
|
To edit an existing mount, click on the mount point from the list on
|
|
the main page. This will display the form used for creating a new
|
|
mount with the current mount point, source and options filled in. You can
|
|
now change any of these on the form, in the same way as you would create
|
|
a new mount (described above). <p>
|
|
|
|
An existing mount will be either permanently saved, currently mounted or
|
|
both. If you change the mount to be not saved or mounted, then it will be
|
|
deleted from the mount list. Note that some filesystem types will not
|
|
have both these options. <p>
|
|
|
|
Under Unix a directory cannot be unmounted if it is currently in use,
|
|
either by a process having a file in the directory open or by a user having
|
|
some subdirectory as his current directory.
|
|
Similarly, a swap file cannot be unmounted if the amount of free memory
|
|
is less than the size of the swap file. When you change the directory,
|
|
source or options of an existing mount, Webmin will unmount and remount
|
|
it to apply the changes. This will fail if the directory or swap file
|
|
is in use, and an error displayed. <p>
|
|
|
|
<hr>
|
|
<a href="/"><img alt="<-" align=middle border=0 src=/images/left.gif></a>
|
|
<a href="">Return to module</a><p>
|
|
|
|
|