summaryrefslogtreecommitdiff
path: root/Documentation/ftape.txt
blob: 7d8bb3384031cb477a5b048dc3e3c4c07a1ef95a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
Intro
=====

This file describes some issues involved when using the "ftape"
floppy tape device driver that comes with the Linux kernel.

ftape has a home page at

http://ftape.dot-heine.de/

which contains further information about ftape. Please cross check
this WWW address against the address given (if any) in the MAINTAINERS
file located in the top level directory of the Linux kernel source
tree.

NOTE: This is an unmaintained set of drivers, and it is not guaranteed to work.
If you are interested in taking over maintenance, contact Claus-Justus Heine
<ch@dot-heine.de>, the former maintainer.

Contents
========

A minus 1: Ftape documentation

A. Changes
   1. Goal
   2. I/O Block Size
   3. Write Access when not at EOD (End Of Data) or BOT (Begin Of Tape)
   4. Formatting
   5. Interchanging cartridges with other operating systems

B. Debugging Output
   1. Introduction
   2. Tuning the debugging output

C. Boot and load time configuration
   1. Setting boot time parameters
   2. Module load time parameters
   3. Ftape boot- and load time options
   4. Example kernel parameter setting
   5. Example module parameter setting

D. Support and contacts

*******************************************************************************

A minus 1. Ftape documentation
==============================

Unluckily, the ftape-HOWTO is out of date. This really needs to be
changed. Up to date documentation as well as recent development
versions of ftape and useful links to related topics can be found at
the ftape home page at

http://ftape.dot-heine.de/

*******************************************************************************

A. Changes
==========

1. Goal
   ~~~~
   The goal of all that incompatibilities was to give ftape an interface
   that resembles the interface provided by SCSI tape drives as close
   as possible. Thus any Unix backup program that is known to work
   with SCSI tape drives should also work.

   The concept of a fixed block size for read/write transfers is
   rather unrelated to this SCSI tape compatibility at the file system
   interface level. It developed out of a feature of zftape, a
   block wise user transparent on-the-fly compression. That compression
   support will not be dropped in future releases for compatibility
   reasons with previous releases of zftape.

2. I/O Block Size
   ~~~~~~~~~~~~~~
   The block size defaults to 10k which is the default block size of
   GNU tar.

   The block size can be tuned either during kernel configuration or
   at runtime with the MTIOCTOP ioctl using the MTSETBLK operation
   (i.e. do "mt -f /dev/qft0" setblk #BLKSZ). A block size of 0
   switches to variable block size mode i.e. "mt setblk 0" switches
   off the block size restriction. However, this disables zftape's
   built in on-the-fly compression which doesn't work with variable
   block size mode.

   The BLKSZ parameter must be given as a byte count and must be a
   multiple of 32k or 0, i.e. use "mt setblk 32768" to switch to a
   block size of 32k.

   The typical symptom of a block size mismatch is an "invalid
   argument" error message.

3. Write Access when not at EOD (End Of Data) or BOT (Begin Of Tape)
   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   zftape (the file system interface of ftape-3.x) denies write access
   to the tape cartridge when it isn't positioned either at BOT or
   EOD.

4. Formatting
   ~~~~~~~~~~
   ftape DOES support formatting of floppy tape cartridges. You need the
   `ftformat' program that is shipped with the modules version of ftape.
   Please get the latest version of ftape from

   ftp://sunsite.unc.edu/pub/Linux/kernel/tapes

   or from the ftape home page at

   http://ftape.dot-heine.de/

   `ftformat' is contained in the `./contrib/' subdirectory of that
   separate ftape package.

5. Interchanging cartridges with other operating systems
   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

   The internal emulation of Unix tape device file marks has changed
   completely. ftape now uses the volume table segment as specified
   by the QIC-40/80/3010/3020/113 standards to emulate file marks. As
   a consequence there is limited support to interchange cartridges
   with other operating systems.

   To be more precise: ftape will detect volumes written by other OS's
   programs and other OS's programs will detect volumes written by
   ftape.

   However, it isn't possible to extract the data dumped to the tape
   by some MSDOS program with ftape. This exceeds the scope of a
   kernel device driver. If you need such functionality, then go ahead
   and write a user space utility that is able to do that. ftape already
   provides all kernel level support necessary to do that.

*******************************************************************************

B. Debugging Output
   ================

1. Introduction
   ~~~~~~~~~~~~
   The ftape driver can be very noisy in that is can print lots of
   debugging messages to the kernel log files and the system console.
   While this is useful for debugging it might be annoying during
   normal use and enlarges the size of the driver by several kilobytes.

   To reduce the size of the driver you can trim the maximal amount of
   debugging information available during kernel configuration. Please
   refer to the kernel configuration script and its on-line help
   functionality.

   The amount of debugging output maps to the "tracing" boot time
   option and the "ft_tracing" modules option as follows:

   0              bugs
   1              + errors (with call-stack dump)
   2              + warnings
   3              + information
   4              + more information
   5              + program flow
   6              + fdc/dma info
   7              + data flow
   8              + everything else

2. Tuning the debugging output
   ~~~~~~~~~~~~~~~~~~~~~~~~~~~
   To reduce the amount of debugging output printed to the system
   console you can

   i)  trim the debugging output at run-time with

       mt -f /dev/nqft0 setdensity #DBGLVL

       where "#DBGLVL" is a number between 0 and 9

   ii) trim the debugging output at module load time with

       modprobe ftape ft_tracing=#DBGLVL

       Of course, this applies only if you have configured ftape to be
       compiled as a module.

   iii) trim the debugging output during system boot time. Add the
       following to the kernel command line:

       ftape=#DBGLVL,tracing

       Please refer also to the next section if you don't know how to
       set boot time parameters.

*******************************************************************************

C. Boot and load time configuration
   ================================

1. Setting boot time parameters
   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 
   Assuming that you use lilo, the LI)nux LO)ader, boot time kernel
   parameters can be set by adding a line

   append some_kernel_boot_time_parameter

   to `/etc/lilo.conf' or at real boot time by typing in the options
   at the prompt provided by LILO. I can't give you advice on how to
   specify those parameters with other loaders as I don't use them.

   For ftape, each "some_kernel_boot_time_parameter" looks like
   "ftape=value,option". As an example, the debugging output can be
   increased with

   ftape=4,tracing

   NOTE: the value precedes the option name.

2. Module load time parameters
   ~~~~~~~~~~~~~~~~~~~~~~~~~~~
   Module parameters can be specified either directly when invoking
   the program 'modprobe' at the shell prompt:

   modprobe ftape ft_tracing=4

   or by editing the file `/etc/modprobe.conf' in which case they take
   effect each time when the module is loaded with `modprobe' (please
   refer to the respective manual pages). Thus, you should add a line

   options ftape ft_tracing=4

   to `/etc/modprobe.conf` if you intend to increase the debugging
   output of the driver.


3. Ftape boot- and load time options
   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

   i.   Controlling the amount of debugging output
        DBGLVL has to be replaced by a number between 0 and 8.

        module                 |  kernel command line
        -----------------------|----------------------
        ft_tracing=DBGLVL      |  ftape=DBGLVL,tracing

   ii.  Hardware setup
	BASE is the base address of your floppy disk controller,
        IRQ and DMA give its interrupt and DMA channel, respectively.
        BOOL is an integer, "0" means "no"; any other value means
	"yes". You don't need to specify anything if connecting your tape
        drive to the standard floppy disk controller. All of these
	values have reasonable defaults. The defaults can be modified
	during kernel configuration, i.e. while running "make config",
	"make menuconfig" or "make xconfig" in the top level directory
	of the Linux kernel source tree. Please refer also to the on
	line documentation provided during that kernel configuration
	process.

	ft_probe_fc10 is set to a non-zero value if you wish for ftape to
	probe for a Colorado FC-10 or FC-20 controller.

	ft_mach2 is set to a non-zero value if you wish for ftape to probe
	for a Mountain MACH-2 controller.

        module                 |  kernel command line
        -----------------------|----------------------
        ft_fdc_base=BASE       |  ftape=BASE,ioport
        ft_fdc_irq=IRQ         |  ftape=IRQ,irq
        ft_fdc_dma=DMA         |  ftape=DMA,dma
        ft_probe_fc10=BOOL     |  ftape=BOOL,fc10
        ft_mach2=BOOL          |  ftape=BOOL,mach2
        ft_fdc_threshold=THR   |  ftape=THR,threshold
        ft_fdc_rate_limit=RATE |  ftape=RATE,datarate

4. Example kernel parameter setting
   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 
   To configure ftape to probe for a Colorado FC-10/FC-20 controller
   and to increase the amount of debugging output a little bit, add
   the following line to `/etc/lilo.conf':

   append ftape=1,fc10 ftape=4,tracing

5. Example module parameter setting
   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   To do the same, but with ftape compiled as a loadable kernel
   module, add the following line to `/etc/modprobe.conf':

   options ftape ft_probe_fc10=1 ft_tracing=4

*******************************************************************************

D. Support and contacts
   ====================

   Ftape is distributed under the GNU General Public License. There is
   absolutely no warranty for this software. However, you can reach
   the current maintainer of the ftape package under the email address
   given in the MAINTAINERS file which is located in the top level
   directory of the Linux kernel source tree. There you'll find also
   the relevant mailing list to use as a discussion forum and the web
   page to query for the most recent documentation, related work and
   development versions of ftape.

   Changelog:
   ==========

~1996:		Original Document

10-24-2004:	General cleanup and updating, noting additional module options.
		James Nelson <james4765@gmail.com>