Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
12689c9c
Commit
12689c9c
authored
Sep 24, 2003
by
Anton Altaparmakov
Browse files
Options
Browse Files
Download
Plain Diff
Merge cantab.net:/home/aia21/bklinux-2.5
into cantab.net:/home/aia21/ntfs-2.6
parents
350667d7
d9704d82
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
153 additions
and
97 deletions
+153
-97
Documentation/filesystems/ntfs.txt
Documentation/filesystems/ntfs.txt
+102
-77
fs/Kconfig
fs/Kconfig
+49
-18
fs/ntfs/layout.h
fs/ntfs/layout.h
+2
-2
No files found.
Documentation/filesystems/ntfs.txt
View file @
12689c9c
...
...
@@ -6,8 +6,9 @@ Table of contents
=================
- Overview
-
Supported mount options
-
Web site
- Features
- Supported mount options
- Known bugs and (mis-)features
- Using Software RAID with NTFS
- Limitiations when using the MD driver
...
...
@@ -17,13 +18,59 @@ Table of contents
Overview
========
To mount an NTFS 1.2/3.x (Windows NT4/2000/XP) volume, use the filesystem
type 'ntfs'. The driver currently works only in read-only mode, with no
fault-tolerance or journalling supported.
Linux-NTFS comes with a number of user-space programs known as ntfsprogs.
These include mkntfs, a full-featured ntfs file system format utility,
ntfsundelete used for recovering files that were unintentionally deleted
from an NTFS volume and ntfsresize which is used to resize an NTFS partition.
See the web site for more information.
To mount an NTFS 1.2/3.x (Windows NT4/2000/XP/2003) volume, use the file
system type 'ntfs'. The driver currently supports read-only mode (with no
fault-tolerance, encryption or journalling) and very limited, but safe, write
support.
For fault tolerance and raid support (i.e. volume and stripe sets), you can
use the kernel's Software RAID / MD driver. See section "Using Software RAID
with NTFS" for details.
Web site
========
There is plenty of additional information on the linux-ntfs web site
at http://linux-ntfs.sourceforge.net/
The web site has a lot of additional information, such as a comprehensive
FAQ, documentation on the NTFS on-disk format, informaiton on the Linux-NTFS
userspace utilities, etc.
For fault tolerance and raid support (i.e. volume and stripe sets), you can use
the kernel's Software RAID / MD driver. See section "Using Software RAID with
NTFS" for details.
Features
========
- This is a complete rewrite of the NTFS driver that used to be in the kernel.
This new driver implements NTFS read support and is functionally equivalent
to the old ntfs driver.
- The new driver has full support for sparse files on NTFS 3.x volumes which
the old driver isn't happy with.
- The new driver supports execution of binaries due to mmap() now being
supported.
- The new driver supports loopback mounting of files on NTFS which is used by
some Linux distributions to enable the user to run Linux from an NTFS
partition by creating a large file while in Windows and then loopback
mounting the file while in Linux and creating a Linux filesystem on it that
is used to install Linux on it.
- A comparison of the two drivers using:
time find . -type f -exec md5sum "{}" \;
run three times in sequence with each driver (after a reboot) on a 1.4GiB
NTFS partition, showed the new driver to be 20% faster in total time elapsed
(from 9:43 minutes on average down to 7:53). The time spent in user space
was unchanged but the time spent in the kernel was decreased by a factor of
2.5 (from 85 CPU seconds down to 33).
- The driver does not support short file names in general. For backwards
compatibility, we implement access to files using their short file names if
they exist. The driver will not create short file names however, and a rename
will discard any existing short file name.
Supported mount options
...
...
@@ -40,10 +87,10 @@ nls=name Character set to use when returning file names.
Unlike VFAT, NTFS suppresses names that contain
unconvertible characters. Note that most character
sets contain insufficient characters to represent all
possible Unicode characters that can exist on NTFS.
To
be sure you are not missing any files, you are advised
to use nls=utf8 which is capable of representing all
Unicode characters.
possible Unicode characters that can exist on NTFS.
To be sure you are not missing any files, you are
advised to use nls=utf8 which is capable of
representing all
Unicode characters.
utf8=<bool> Option no longer supported. Currently mapped to
nls=utf8 but please use nls=utf8 in the future and
...
...
@@ -92,8 +139,8 @@ case_sensitive=<BOOL> If case_sensitive is specified, treat all file names as
remove them on rename/delete of the corresponding long
file name.
Note that files remain accessible via their short file
name, if it exists.
If case_sensitive, you will need to
provide the correct case of the short file name.
name, if it exists.
If case_sensitive, you will need
to
provide the correct case of the short file name.
errors=opt What to do when critical file system errors are found.
Following values can be used for "opt":
...
...
@@ -102,13 +149,13 @@ errors=opt What to do when critical file system errors are found.
bad so it is no longer accessed, and then
continue.
recover: At present only supported is recovery of
the boot sector from the backup copy.
If a
read-only mount, the recovery is done in
memory only and not written to disk.
the boot sector from the backup copy.
If read-only mount, the recovery is done
in
memory only and not written to disk.
Note that the options are additive, i.e. specifying:
errors=continue,errors=recover
This means the driver will attempt to recover and if
that
fails it will clean-up as much as possible and
means the driver will attempt to recover and if that
fails it will clean-up as much as possible and
continue.
mft_zone_multiplier= Set the MFT zone multiplier for the volume (this
...
...
@@ -132,29 +179,6 @@ mft_zone_multiplier= Set the MFT zone multiplier for the volume (this
Note this option is irrelevant for read-only mounts.
Features
========
- This is a complete rewrite of the NTFS driver that used to be in the kernel.
This new driver implements NTFS read support and is functionally equivalent
to the old ntfs driver.
- The new driver has full support for sparse files on NTFS 3.x volumes which
the old driver isn't happy with.
- The new driver supports execution of binaries due to mmap() now being
supported.
- A comparison of the two drivers using:
time find . -type f -exec md5sum "{}" \;
run three times in sequence with each driver (after a reboot) on a 1.4GiB
NTFS partition, showed the new driver to be 20% faster in total time elapsed
(from 9:43 minutes on average down to 7:53). The time spent in user space
was unchanged but the time spent in the kernel was decreased by a factor of
2.5 (from 85 CPU seconds down to 33).
- The driver does not support short file names in general. For backwards
compatibility, we implement access to files using their short file names if
they exist. The driver will not create short file names however, and a rename
will discard any existing short file name.
Known bugs and (mis-)features
=============================
...
...
@@ -176,11 +200,11 @@ Using Software RAID with NTFS
For support of volume and stripe sets, use the kernel's Software RAID / MD
driver and set up your /etc/raidtab appropriately (see man 5 raidtab).
Linear volume sets, i.e. linear raid, as well as stripe sets, i.e. raid level
0,
have been tested and work fine (though see section "Limitiations when using the
MD driver with NTFS volumes" especially if you want to use linear raid). Even
though untested, there is no reason why mirrors, i.e. raid level 1, and stripes
with parity, i.e. raid level 5, should not work, too.
Linear volume sets, i.e. linear raid, as well as stripe sets, i.e. raid level
0, have been tested and work fine (though see section "Limitiations when using
the MD driver with NTFS volumes" especially if you want to use linear raid).
Even though untested, there is no reason why mirrors, i.e. raid level 1, and
stripes
with parity, i.e. raid level 5, should not work, too.
You have to use the "persistent-superblock 0" option for each raid-disk in the
NTFS volume/stripe you are configuring in /etc/raidtab as the persistent
...
...
@@ -207,15 +231,16 @@ For linear raid, just change the raid-level above to "raid-level linear", for
mirrors, change it to "raid-level 1", and for stripe sets with parity, change
it to "raid-level 5".
Note for stripe sets with parity you will also need to tell the MD driver which
parity algorithm to use by specifying the option "parity-algorithm which",
where you need to replace "which" with the name of the algorithm to use (see
man 5 raidtab for available algorithms) and you will have to try the different
available algorithms until you find one that works. Make sure you are working
read-only when playing with this as you may damage your data otherwise. If you
find which algorithm works please let us know (email the linux-ntfs developers
list linux-ntfs-dev@lists.sourceforge.net or drop in on IRC in channel #ntfs
on the irc.openprojects.net network) so we can update this documentation.
Note for stripe sets with parity you will also need to tell the MD driver
which parity algorithm to use by specifying the option "parity-algorithm
which", where you need to replace "which" with the name of the algorithm to
use (see man 5 raidtab for available algorithms) and you will have to try the
different available algorithms until you find one that works. Make sure you
are working read-only when playing with this as you may damage your data
otherwise. If you find which algorithm works please let us know (email the
linux-ntfs developers list linux-ntfs-dev@lists.sourceforge.net or drop in on
IRC in channel #ntfs on the irc.freenode.net network) so we can update this
documentation.
Once the raidtab is setup, run for example raid0run -a to start all devices or
raid0run /dev/md0 to start a particular md device, in this case /dev/md0.
...
...
fs/Kconfig
View file @
12689c9c
...
...
@@ -680,19 +680,33 @@ config UMSDOS_FS
module, so saying M could be dangerous. If unsure, say N.
config NTFS_FS
tristate "NTFS file system support
(read only)
"
tristate "NTFS file system support"
help
NTFS is the file system of Microsoft Windows NT/2000/XP. For more
information see <file:Documentation/filesystems/ntfs.txt>. Saying Y
here would allow you to read from NTFS partitions.
NTFS is the file system of Microsoft Windows NT, 2000, XP and 2003.
Saying Y or M here enables read support. There is partial, but
safe, write support available. For write support you must also
say Y to "NTFS write support" below.
There are also a number of user-space tools available, called
ntfsprogs. These include ntfsundelete and ntfsresize, that work
without NTFS support enabled in the kernel.
This is a rewrite from scratch of Linux NTFS support and replaced
the old NTFS code starting with Linux 2.5.11. A backport to
the Linux 2.4 kernel series is separately available as a patch
from the project web site.
For more information see <file:Documentation/filesystems/ntfs.txt>
and <http://linux-ntfs.sourceforge.net/>.
This file system is also available as a module ( = code which can be
inserted in and removed from the running kernel whenever you want).
The module will be called ntfs. If you want to compile it as a
module, say M here and read <file:Documentation/modules.txt>.
If you are not using Windows NT
/2000/XP in addition to Linux on your
computer it is safe to say N.
If you are not using Windows NT
, 2000, XP or 2003 in addition to
Linux on your
computer it is safe to say N.
config NTFS_DEBUG
bool "NTFS debugging support"
...
...
@@ -717,16 +731,33 @@ config NTFS_DEBUG
debugging messages while the misbehaviour was occurring.
config NTFS_RW
bool "NTFS write support
(DANGEROUS)
"
depends on NTFS_FS
&& EXPERIMENTAL
bool "NTFS write support"
depends on NTFS_FS
help
This enables the experimental write support in the NTFS driver.
This enables the partial, but safe, write support in the NTFS driver.
The only supported operation is overwriting existing files, without
changing the file length. No file or directory creation, deletion or
renaming is possible. Note only non-resident files can be written to
so you may find that some very small files (<500 bytes or so) cannot
be written to.
While we cannot guarantee that it will not damage any data, we have
so far not received a single report where the driver would have
damaged someones data so we assume it is perfectly safe to use.
Note: While write support is safe in this version (a rewrite from
scratch of the NTFS support), it should be noted that the old NTFS
write support, included in Linux 2.5.10 and before (since 1997),
is not safe.
WARNING: Do not use this option unless you are actively developing
NTFS as it is currently guaranteed to be broken and you
may lose all your data!
This is currently useful with TopologiLinux. TopologiLinux is run
on top of any DOS/Microsoft Windows system without partitioning your
hard disk. Unlike other Linux distributions TopologiLinux does not
need its own partition. For more information see
<http://topologi-linux.sourceforge.net/>
It is
strongly recommended and
perfectly safe to say N here.
It is perfectly safe to say N here.
endmenu
...
...
fs/ntfs/layout.h
View file @
12689c9c
...
...
@@ -42,8 +42,8 @@
#define const_cpu_to_le32(x) __constant_cpu_to_le32(x)
#define const_cpu_to_le64(x) __constant_cpu_to_le64(x)
/* The NTFS oem_id */
#define magicNTFS const_cpu_to_le64(0x202020205346544e
)
/* "NTFS " */
/* The NTFS oem_id
"NTFS "
*/
#define magicNTFS const_cpu_to_le64(0x202020205346544e
ULL)
/*
* Location of bootsector on partition:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment