@@ -69,9 +69,16 @@ are larger than half the device or larger than the available space.
69
69
70
70
### REQUIREMENTS
71
71
72
- There are four requirements for fstransform to have a chance to succeed:
72
+ There are five requirements for fstransform to have a chance to succeed:
73
73
74
- 1 . the device must have a little free space, typically at least 5%
74
+ 1 . the device must be unmountable, i.e. ` umount DEVICE ` must work.
75
+ In particular, if some running programs are using the device,
76
+ you must first close or kill them.
77
+
78
+ Transforming the current root directory does not work. For that, you should
79
+ boot from a different installation (for example a live CD, DVD or USB).
80
+
81
+ 2 . the device must have a little free space, typically at least 5%
75
82
76
83
WARNING: transforming an almost full device to 'xfs' file-system
77
84
can be tricky:
@@ -82,7 +89,7 @@ There are four requirements for fstransform to have a chance to succeed:
82
89
before resuming fstransform.
83
90
A future fstransform version may automate this operation.
84
91
85
- 2 . the filesystem on the device must support SPARSE FILES, i.e. files with holes
92
+ 3 . the filesystem on the device must support SPARSE FILES, i.e. files with holes
86
93
(see for example http://en.wikipedia.org/wiki/Sparse_file for an explanation of what they are)
87
94
and at least one of the two system calls "ioctl(FS_IOC_FIEMAP)" or "ioctl(FIBMAP)"
88
95
(see the file Documentation/filesystems/fiemap.txt in any recent Linux kernel
@@ -91,37 +98,45 @@ There are four requirements for fstransform to have a chance to succeed:
91
98
ioctl(FIBMAP) is limited by design to 2G-1 blocks, which typically translates to 8TB - 4kB.
92
99
To transform file systems equal or larger than 8TB, ioctl(FIEMAP) is required.
93
100
94
- 3 . the initial and final filesystems must be supported by the Linux kernel
101
+ 4 . the initial and final filesystems must be supported by the Linux kernel
95
102
(i.e. it must be able to mount them)
96
103
and by the tools 'mkfs' and 'fsck'
97
104
(i.e. it must be possible to create them and check them for errors)
98
105
99
- 4 . the following programs must be available:
106
+ 5 . the following programs must be available:
100
107
the two custom-made programs 'fsmove' and 'fsremap' (distributed with the script)
101
108
and several common Linux tools:
102
109
which, expr, id, blockdev, losetup, mount, umount,
103
110
mkdir, rmdir, rm, mkfifo, dd, sync, fsck, mkfs
104
111
105
112
106
- ### KNOWN LIMITS
107
-
108
- * If the device contains a HUGE number of files with multiple hard links,
109
- fstransform will be very slow and consume a LOT of memory.
110
- Devices with more than one million files with multiple hard links
111
- can cause fstransform to crash with "out of memory" errors.
113
+ ### KNOWN LIMITATIONS
112
114
115
+ 1 ) As stated above, at a certain step during the conversion, fstransform needs
116
+ to unmount the device being transformed.
117
+ For this reason, running fstransform on the device currently mounted as /
118
+ (i.e. the root directory) fails.
119
+ For the same reason, running fstransform on the device currently mounted
120
+ as /usr, /home or /var or similar heavily-used directories is difficult,
121
+ because quite often there are programs using those, which prevents
122
+ them from being unmounted.
123
+
124
+ 2 ) If the device contains a HUGE number of files with multiple hard links,
125
+ fstransform will be very slow and consume a LOT of memory.
126
+ Devices with more than one million files with multiple hard links
127
+ can cause fstransform to crash with "out of memory" errors.
113
128
114
- 2 ) JFS file systems equal or larger than 8TB cannot be converted due to
129
+ 3 ) JFS file systems equal or larger than 8TB cannot be converted due to
115
130
missing support for ioctl(FIEMAP) in the kernel:
116
131
the fallback ioctl(FIBMAP) is limited by design to < 8TB (assuming 4k blocks)
117
132
118
- 3 ) REISERFS file systems using format "3.5" (the default) and equal or larger than 2TB
133
+ 4 ) REISERFS file systems using format "3.5" (the default) and equal or larger than 2TB
119
134
cannot be converted due to their maximum file size = 2TB - 4k:
120
135
fstransform needs to create a sparse file as large as the device itself.
121
136
122
137
REISERFS file systems using format "3.6" are immune to this problem.
123
138
124
- 4 ) for the same reason, a device cannot be converted _ to_ REISERFS format "3.5"
139
+ 5 ) for the same reason, a device cannot be converted _ to_ REISERFS format "3.5"
125
140
if it contains files larger than 2TB - 4k.
126
141
127
142
@@ -215,6 +230,9 @@ To pass the same option to 'fstransform', you must execute something like
215
230
by running 'fsremap --resume-job=<MMM > {device}'.
216
231
Also, 'fsremap' will show at its startup the exact command line
217
232
needed to resume its execution.
233
+
234
+ The loop file created by fstransform must NEVER be as argument to
235
+ 'fsremap --resume-job=<MMM > {...}'. You would IRREVERSIBLY LOSE YOUR DATA!
218
236
219
237
REAL-WORLD TESTS
220
238
0 commit comments