]> git.sur5r.net Git - bacula/docs/blob - docs/manual-fr/faq.tex
'Spool Data = Yes' sets 'Spool Attributes = Yes'
[bacula/docs] / docs / manual-fr / faq.tex
1 %%
2 %%
3
4 \section*{Bacula Frequently Asked Questions}
5 \label{_ChapterStart48}
6 \index[general]{Questions!Bacula Frequently Asked }
7 \index[general]{Bacula Frequently Asked Questions }
8 \addcontentsline{toc}{section}{Bacula Frequently Asked Questions}
9
10 These are questions that have been submitted over time by the
11 Bacula users.
12
13 Please also see
14 \ilink{the bugs section}{_ChapterStart4} of this document for a list
15 of known bugs and solutions.
16
17 \begin{description}
18 \label{what}
19 \subsection*{What is Bacula?}
20 \item [What is {\bf Bacula}? ]
21    \index[general]{What is Bacula? }
22    {\bf Bacula} is a network backup and restore program. 
23
24 \subsection*{Does Bacula support Windows?}
25 \item [Does Bacula support Windows?]
26    \index[general]{Does Bacula support Windows? }
27    Yes, Bacula compiles and runs on Windows machines  (Win98, WinMe, WinXP,
28    WinNT, and Win2000).  We provide a binary version of the Client (bacula-fd),
29    but have  not tested the Director nor the Storage daemon. Note, Win95  is no
30    longer supported because it doesn't have the  GetFileAttributesExA API call.
31  
32
33 \label{lang}
34 \subsection*{What language is Bacula written in?}
35 \item [What language is Bacula written in?]
36    \index[general]{What language is Bacula written in? }
37    It is written in C++, but it is mostly C  code using only a limited set of
38    the C++ extensions  over C.  Thus Bacula is completely  compiled using the
39    C++ compiler. There are several modules, including the Win32 interface, that
40    are written using the  object oriented C++ features. Over time, we are slowly
41    adding a larger  subset of C++.  
42
43 \label{run}
44 \subsection*{On what machines does Bacula run?}
45 \item [On what machines does Bacula run? ]
46    \index[general]{On what machines does Bacula run? }
47    {\bf Bacula} builds and executes on RedHat Linux (versions  RH7.1-RHEL 3.0,
48    SuSE, Gentoo, Debian, Mandriva, ...), FreeBSD,  Solaris, Alpha, SGI (client),
49    NetBSD, OpenBSD, Mac OS X (client),  and Win32 (client).  
50
51    Bacula has been my only backup tool for over  four years backing up 5
52    machines nightly (3 Linux boxes  running RedHat, a WinXP machine, and a WinNT
53    machine).
54  
55
56 \label{stable}
57 \subsection*{Is Bacula Stable?}
58 \item [Is Bacula Stable? ]
59    \index[general]{Is Bacula Stable? }
60    Yes, it is remarkably stable, but remember, there are  still a lot of
61    unimplemented or partially implemented features.  With a program of this size
62    (100,000+ lines of C++ code  not including the SQL programs) there are bound
63    to be bugs.  The current test environment (a twisted pair local network and a
64    HP DLT  backup tape) is not exactly ideal, so additional testing on other 
65 sites is
66    necessary. The File daemon has never crashed -- running  months at a time
67 with
68    no intervention. The Storage daemon is  remarkably stable with most of the
69    problems arising during labeling  or switching tapes. Storage daemon crashes
70    are rare.  The Director, given the multitude of functions it fulfills is 
71 also
72    relatively stable. In a production environment, it rarely if ever crashes. Of
73    the three daemons, the Director is the most  prone to having problems. Still,
74 it
75    frequently runs several months with  no problems.
76
77    There are a number of reasons for this stability.  
78
79    \begin{enumerate}
80    \item The program was largely written by one person to date
81       (Kern).\\
82    \item  The program is constantly checking the chain of allocated
83       memory buffers to ensure that no overruns have occurred.  \\
84    \item All  memory leaks (orphaned buffers) are reported each time the
85       program  terminates.\\
86    \item Any signal (segmentation fault, ...) generates a 
87       traceback that is emailed to the developer. This permits quick  resolution
88 of
89       bugs even if they only show up rarely in a  production system.\\
90    \item There is a reasonably comprehensive set of regression tests
91       that avoids re-creating the most common errors in new versions of
92       Bacula.
93    \end{enumerate}
94
95 \label{AuthorizationErrors}
96 \subsection*{I'm Getting Authorization Errors. What is Going On? }
97 \item [I'm Getting Authorization Errors. What is Going On? ]
98 \index[general]{Authorization Errors}
99 \index[general]{Concurrent Jobs}
100    For security reasons, Bacula requires that both  the File daemon and the
101    Storage daemon know the name  of the Director as well as its password. As a
102    consequence,  if you change the Director's name or password, you must  make
103    the corresponding change in the Storage daemon's and  in the File daemon's
104    configuration files.  
105
106    During the authorization process, the Storage daemon and File daemon
107    also require that the Director authenticates itself, so both ends
108    require the other to have the correct name and password.
109
110    If you have edited the conf files and modified any name or any password,
111    and you are getting authentication errors, then your best bet is to go
112    back to the original conf files generated by the Bacula installation
113    process.  Make only the absolutely necessary modifications to these
114    files -- e.g.  add the correct email address.  Then follow the
115    instructions in the \ilink{ Running Bacula}{_ChapterStart1} chapter of
116    this manual.  You will run a backup to disk and a restore.  Only when
117    that works, should you begin customization of the conf files.
118
119    Another reason that you can get authentication errors is if you are
120    running Multiple Concurrent Jobs in the Director, but you have not set
121    them in the File daemon or the Storage daemon.  Once you reach their
122    limit, they will reject the connection producing authentication (or
123    connection) errors.
124
125    If you are having problems connecting to a Windows machine that
126    previously worked, you might try restarting the Bacula service since
127    Windows frequently encounters networking connection problems.
128
129    Some users report that authentication fails if there is not a proper
130    reverse DNS lookup entry for the machine.  This seems to be a
131    requirement of gethostbyname(), which is what Bacula uses to translate
132    names into IP addresses.  If you cannot add a reverse DNS entry, or you
133    don't know how to do so, you can avoid the problem by specifying an IP
134    address rather than a machine name in the appropriate Bacula conf file.
135
136    Here is a picture that indicates what names/passwords in which
137    files/Resources must match up:
138
139    \includegraphics{./Conf-Diagram.eps}  
140
141    In the left column, you will find the Director, Storage, and  Client
142    resources, with their names and passwords -- these  are all in {\bf
143    bacula-dir.conf}. The right column is where the corresponding values
144    should be found in the  Console, Storage daemon (SD), and File daemon (FD)
145    configuration  files.  
146
147    Another thing to check is to ensure that the Bacula component you are
148    trying to access has {\bf Maximum Concurrent Jobs} set large enough to
149    handle each of the Jobs and the Console that want to connect
150    simultaneously.  Once the maximum connections has been reached, each
151    Bacula component will reject all new connections.
152
153    Finally, make sure you have no {\bf hosts.allow} or {\bf hosts.deny}
154    file that is not permitting access to the site trying to connect.
155
156 \label{AccessProblems}
157 \subsection*{Bacula Runs Fine but Cannot Access a Client on a Different Machine.
158    Why? }
159 \item [Bacula Runs Fine but Cannot Access a Client on a Different Machine.
160    Why? ]
161 \index[general]{Cannot Access a Client}
162    There are several reasons why Bacula could not contact a client  on a
163    different machine. They are:  
164
165 \begin{itemize}
166 \item It is a Windows Client, and the client died because of an  improper
167    configuration file. Check that the Bacula icon is in  the system tray and the
168    the menu items work. If the client has  died, the icon will disappear only
169    when you move the mouse over  the icon.  
170 \item The Client address or port is incorrect or not resolved by  DNS. See if
171    you can ping the client machine using the same  address as in the Client
172    record.  
173 \item You have a firewall, and it is blocking traffic on port  9102 between
174    the Director's machine and the Client's  machine (or on port 9103 between the
175    Client and the Storage daemon  machines).  
176 \item Your password or names are not correct in both the Director and  the
177    Client machine. Try configuring everything identical to  how you run the
178    client on the same machine as the Director, but  just change the Address. If
179    that works, make the other changes  one step at a time until it works.  
180 \item You may also be having problems betwen your File daemon and your
181    Storage daemon. The name you use in the Storage resource of your
182    Director's conf file must be known (resolvable) by the File daemon, 
183    because it is passed symbolically to the File daemon, which then
184    resolves it to get an IP address used to contact the Storage daemon.
185 \item You may have a {\bf hosts.allow} or {\bf hosts.deny} file that is
186    not permitting access.
187 \end{itemize}
188
189 \label{startover}
190 \subsection*{My Catalog is Full of Test Runs, How Can I Start Over?}
191 \item [My Catalog is Full of Test Runs, How Can I Start Over? ]
192   \index[general]{My Catalog is Full of Test Runs, How Can I Start Over? }
193   If you are using MySQL do the following:
194
195 \footnotesize
196 \begin{verbatim}
197    cd <bacula-source>/src/cats
198    ./drop_mysql_tables
199    ./make_mysql_tables
200  
201 \end{verbatim}
202 \normalsize
203
204 If you are using SQLite, do the following:
205
206 \footnotesize
207 \begin{verbatim}
208    Delete bacula.db from your working directory.
209    cd <bacula-source>/src/cats
210    ./drop_sqlite_tables
211    ./make_sqlite_tables
212  
213 \end{verbatim}
214 \normalsize
215
216 Then write an EOF on each tape you used with {\bf Bacula} using: 
217
218 \footnotesize
219 \begin{verbatim}
220 mt -f /dev/st0 rewind
221 mt -f /dev/st0 weof
222 \end{verbatim}
223 \normalsize
224
225 where you need to adjust the device name for your system.  
226
227 \label{restorehang}
228 \subsection*{I Run a Restore Job and Bacula Hangs. What do I do?}
229 \item [I Run a Restore Job and Bacula Hangs. What do I do?]
230    \index[general]{I Run a Restore Job and Bacula Hangs. What do I do? }
231    On Bacula version 1.25 and prior, it expects you to  have the correct tape
232    mounted prior to a restore. On  Bacula version 1.26 and higher, it will ask
233    you for the  tape, and if the wrong one is mounted, it will inform you.  
234
235    If you have previously done an {\bf unmount} command, all  Storage daemon
236    sessions (jobs) will be completely blocked  from using the drive unmounted,
237 so
238    be sure to do a {\bf mount}  after your unmount. If in doubt, do a second
239    {\bf mount}, it  won't cause any harm.  
240
241 \label{windowstart}
242 \subsection*{I Cannot Get My Windows Client to Start Automatically? }
243 \item [I Cannot Get My Windows Client to Start Automatically? ]
244    \index[general]{I Cannot Get My Windows Client to Start Automatically? }
245    You are probably having one of two problems: either the  Client is dying due
246    to an incorrect configuration file, or  you didn't do the Installation
247    commands necessary to install  it as a Windows Service.  
248
249    For the first problem, see the next FAQ question. For the  second problem,
250    please review the 
251    \ilink{ Windows Installation instructions}{_ChapterStart7} in this
252    manual.  
253
254 \label{windowsdie}
255 \subsection*{My Windows Client Immediately Dies When I Start It}
256 \item [My Windows Client Immediately Dies When I Start It ]
257 \index[general]{My Windows Client Immediately Dies When I Start It }
258 The most common problem is either that the configuration  file is not where it
259 expects it to be, or that there is an  error in the configuration file.  You
260 must have the configuration file in  {\bf
261 c:\textbackslash{}bacula\textbackslash{}bin\textbackslash{}bacula-fd.conf}.  
262
263 To {\bf see} what is going on when the File daemon starts  on Windows, do the
264 following:  
265
266 \footnotesize
267 \begin{verbatim}
268     Start a DOS shell Window.
269     cd c:\bacula\bin
270     bacula-fd -d100 -c c:\bacula\bin\bacula-fd.conf
271     
272 \end{verbatim}
273 \normalsize
274
275 This will cause the FD to write a file {\bf bacula.trace}  in the current
276 directory, which you can examine and thereby determine  the problem.  
277
278 \label{scroll}
279 \item [When I Start the Console, the Error Messages Fly By. How can I see
280    them? ]
281    \index[general]{When I Start the Console, the Error Messages Fly By. How can
282 I see them? }
283    Either use a shell window with a scroll bar, or use the gnome-console.  In
284 any
285    case, you probably should be logging all output to a file, and  then you can
286    simply view the file using an editor or the {\bf less}  program. To log all
287    output, I have the following in my Director's  Message resource definition:  
288
289 \footnotesize
290 \begin{verbatim}
291     append = "/home/kern/bacula/bin/log" = all, !skipped
292     
293 \end{verbatim}
294 \normalsize
295
296 Obviously you will want to change the filename to be appropriate  for your
297 system.  
298
299 \label{nobackup}
300 \subsection*{My backups are not working on my Windows 
301    Client. What should I do?}
302
303 \item [I didn't realize that the backups were not working on my Windows 
304    Client. What should I do? ]
305 \index[general]{I didn't realize that the backups were not working on my Windows
306 Client. What should I do? }
307 You should be sending yourself an email message for each job. This will  avoid
308 the possibility of not knowing about a failed backup. To do so  put something
309 like:  
310
311 \footnotesize
312 \begin{verbatim}
313   Mail = yourname@yourdomain = all, !skipped
314   
315 \end{verbatim}
316 \normalsize
317
318 in your Director's message resource. You should then receive one  email for
319 each Job that ran. When you are comfortable with what  is going on (it took me
320 9 months), you might change that to:  
321
322 \footnotesize
323 \begin{verbatim}
324    MailOnError = yourname@yourdomain = all, !skipped
325    
326 \end{verbatim}
327 \normalsize
328
329 then you only get email messages when a Job errors as is the case  for your
330 Windows machine.  
331
332 You should also be logging the Director's messages, please see the  previous
333 FAQ for how to do so.  
334
335 \label{sched}
336 \subsection*{All my Jobs are scheduled for the same time. Will this cause
337    problems?}
338 \item [All my Jobs are scheduled for the same time. Will this cause
339    problems? ]
340 \index[general]{Schedule problems}
341    No, not at all. Bacula will schedule all the Jobs at the same time,  but will
342    run them one after another unless you have increased the number  of
343    simultaneous jobs in the configuration files for the Director,  the File
344    daemon, and the Storage daemon. The appropriate configuration  record is {\bf
345    Maximum Concurrent Jobs = nn}. At the current time,  we recommend that you
346    leave this set to {\bf 1} for the Director.  
347
348 \label{disk}
349 \subsection*{Can Bacula Backup My System To Files instead of Tape?}
350 \item [Can Bacula Backup My System To Files instead of Tape? ]
351    \index[general]{Can Bacula Backup My System To Files instead of Tape? }
352    Yes, in principle, Bacula can backup to any storage  medium as long as you
353    have correctly defined that medium in the  Storage daemon's Device resource.
354    For an example of how to backup  to files, please see the  
355    \ilink{Pruning Example}{PruningExample} in the  Recycling
356    chapter of this manual. Also, there is a whole chapter  devoted to 
357    \ilink{Basic Volume Management}{_ChapterStart39}.  This chapter was
358    originally written to explain how to write to disk, but was expanded
359    to include volume management. It is, however, still quite a good
360    chapter to read.
361
362 \label{bigfiles}
363 \subsection*{Can Bacula Backup and Restore Files Greater than 2 Gigabytes?}
364 \item [Can Bacula Backup and Restore Files Greater than 2 Gigabytes in
365    Size?  ]
366 \index[general]{Large file support}
367 If your operating system permits it, and you are running Bacula  version 1.26
368 or later, the answer is yes. To the best of our  knowledge all client system
369 supported by Bacula can handle  files larger than 2 Gigabytes.  
370
371 \label{cancel}
372 \subsection*{I want to stop a job. Is
373    there  a better way than {\bf ./bacula stop} to stop it?}
374 \item [I Started A Job then Decided I Really Did Not Want to Run It. Is
375    there  a better way than {\bf ./bacula stop} to stop it?]
376 \index[general]{Cancelling jobs} 
377    Yes,
378    you normally should use the Console command {\bf cancel} to cancel a Job
379    that is either scheduled or running.  If the Job is scheduled, it will
380    be marked for cancellation and will be canceled when it is scheduled to
381    start.  If it is running, it will normally terminate after a few
382    minutes.  If the Job is waiting on a tape mount, you may need to do a
383    {\bf mount} command before it will be canceled.
384
385 \label{trademark}
386 \subsection*{Why have You Trademarked the Name
387    Bacula\raisebox{.6ex}{{\footnotesize \textsuperscript{\textregistered}}}?}
388 \item [Why have You Trademarked the Name
389    Bacula\raisebox{.6ex}{{\footnotesize \textsuperscript{\textregistered}}}?]
390 \index[general]{Bacula Trademark}
391 We have trademarked the name Bacula to ensure that all media  written by any
392 program named Bacula will always be compatible. Anyone  may use the name
393 Bacula, even in a derivative product as long as it  remains totally compatible
394 in all respects with the program defined  here.
395
396 \label{docversion}
397 \subsection*{Why is Your Online Document for Version 1.37 but the Released Version is 1.36?}
398 \item [Why is Your Online Document for Version 1.37 of Bacula when the
399    Currently  Release Version is 1.36?]
400 \index[general]{Multiple manuals}
401 As Bacula is being developed, the document is also being enhanced, more  often
402 than not it has clarifications of existing features that  can be very useful
403 to our users, so we publish the very latest  document. Fortunately it is rare
404 that there are confusions with  new features.  
405
406 If you want to read a document that pertains only to a specific  version,
407 please use the one distributed in the source code.  
408
409 \label{sure}
410 \subsection*{Does Bacula really save and restore all files?}
411 \item [How Can I Be Sure that Bacula Really Saves and Restores All Files? ]
412    \index[general]{How Can I Be Sure that Bacula Really Saves and Restores
413    All Files?  } It is really quite simple, but took me a while to figure
414    out how to "prove" it.  First make a Bacula Rescue disk, see the
415    \ilink{Disaster Recovery Using Bacula}{_ChapterStart38} of this manual.
416    Second, you run a full backup of all your files on all partitions.
417    Third, you run an Verify InitCatalog Job on the same FileSet, which
418    effectively makes a record of all the files on your system.  Fourth, you
419    run a Verify Catalog job and assure yourself that nothing has changed
420    (well, between an InitCatalog and Catalog one doesn't expect anything).
421    Then do the unthinkable, write zeros on your MBR (master boot record)
422    wiping out your hard disk.  Now, restore your whole system using your
423    Bacula Rescue disk and the Full backup you made, and finally re-run the
424    Verify Catalog job.  You will see that with the exception of the
425    directory modification and access dates and the files changed during the
426    boot, your system is identical to what it was before you wiped your hard
427    disk.
428    Alternatively you could do the wiping and restoring to another computer
429    of the same type.
430
431 \label{upgrade}
432 \subsection*{I want an Incremental but Bacula runs it as a Full backup. Why?}
433 \item [I did a Full backup last week, but now in running an Incremental,
434    Bacula  says it did not find a FULL backup, so it did a FULL backup. Why?]
435    \index[general]{I did a Full backup last week, but now in running an
436    Incremental, Bacula says it did not find a FULL backup, so it did a
437    FULL backup.  Why?  } Before doing an Incremental or a Differential
438    backup, Bacula checks to see if there was a prior Full backup of the
439    same Job that terminated successfully.  If so, it uses the date that
440    full backup started as the time for comparing if files have changed.  If
441    Bacula does not find a successful full backup, it proceeds to do one.
442    Perhaps you canceled the full backup, or it terminated in error.  In
443    such cases, the full backup will not be successful.  You can check by
444    entering {\bf list jobs} and look to see if there is a prior Job with
445    the same Name that has Level F and JobStatus T (normal termination).
446
447    Another reason why Bacula may not find a suitable Full backup is that
448    every time you change the FileSet, Bacula will require a new Full
449    backup.  This is necessary to ensure that all files are properly backed
450    up in the case where you have added more files to the FileSet.
451    Beginning with version 1.31, the FileSets are also dated when they are
452    created, and this date is displayed with the name when you are listing
453    or selecting a FileSet.  For more on backup levels see below.
454
455 \label{filenamelengths}
456 \subsection*{Do you really handle unlimited path lengths?}
457 \item [How Can You Claim to Handle Unlimited Path and Filename Lengths
458    when  All Other Programs Have Fixed Limits?]
459    \index[general]{How Can You Claim to Handle Unlimited Path and Filename
460    Lengths when All Other Programs Have Fixed Limits?  } Most of those
461    other programs have been around for a long time, in fact since the
462    beginning of Unix, which means that they were designed for rather small
463    fixed length path and filename lengths.  Over the years, these
464    restrictions have been relaxed allowing longer names.  Bacula on the
465    other hand was designed in 2000, and so from the start, Path and
466    Filenames have been kept in buffers that start at 256 bytes in length,
467    but can grow as needed to handle any length.  Most of the work is
468    carried out by lower level routines making the coding rather easy.
469
470    Note that due to limitations Win32 path and filenames cannot exceed
471    260 characters. By using Win32 Unicode functions, we will remove this
472    restriction in later versions of Bacula.
473
474 \label{unique}
475 \subsection*{What Is the Really Unique Feature of Bacula?}
476 \item [What Is the Really Unique Feature of Bacula?]
477    \index[general]{What Is the Really Unique Feature of Bacula?  } Well, it
478    is hard to come up with unique features when backup programs for Unix
479    machines have been around since the 1960s.  That said, I believe that
480    Bacula is the first and only program to use a standard SQL interface to
481    catalog its database.  Although this adds a bit of complexity and
482    possibly overhead, it provides an amazingly rich set of features that
483    are easy to program and enhance.  The current code has barely scratched
484    the surface in this regard (version 1.31).
485
486    The second feature, which gives a lot of power and flexibility to Bacula
487    is the Bootstrap record definition.
488
489    The third unique feature, which is currently (1.30) unimplemented, and
490    thus can be called vaporware :-), is Base level saves.  When
491    implemented, this will enormously reduce tape usage.
492
493 \label{sequence}
494 \subsection*{How can I force one job to run after another?}
495 \item [If I Run Multiple Simultaneous Jobs, How Can I Force One
496    Particular  Job to Run After Another Job? ]
497 \index[general]{If I Run Multiple Simultaneous Jobs, How Can I Force One
498 Particular Job to Run After Another Job? }
499 Yes, you can set Priorities on your jobs so that they  run in the order you
500 specify. Please see:  
501 \ilink{the Priority record}{Priority} in the  Job resource.
502
503 \label{nomail}
504 \subsection*{I Am Not Getting Email Notification, What Can I Do? }
505 \item [I Am Not Getting Email Notification, What Can I Do? ]
506
507 \index[general]{I Am Not Getting Email Notification, What Can I Do? }
508 The most common problem is that you have not specified a fully  qualified
509 email address and your bsmtp server is rejecting the mail.  The next most
510 common problem is that your bsmtp server doesn't like  the syntax on the From
511 part of the message. For more details on this  and other problems, please see
512 the 
513 \ilink{ Getting Email Notification to Work}{email} section of the
514 Tips chapter  of this manual. The section 
515 \ilink{ Getting Notified of Job Completion}{notification} of the Tips
516 chapter may also  be useful. For more information on the {\bf bsmtp} mail
517 program,  please see 
518 \ilink{bsmtp in the Volume Utility Tools chapter}{bsmtp} of this
519 manual.
520
521 \label{periods}
522 \subsection*{My retention periods don't work}
523 \item [I Change Recycling, Retention Periods, or File Sizes in my Pool
524    Resource  and they Still Don't Work.]
525 \index[general]{Recycling}
526 \index[general]{Retention Periods}
527 \index[general]{Pool changes}
528   The different variables associated with a Pool are defined in the  Pool
529   Resource, but are actually read by Bacula from the Catalog database.  On
530   Bacula versions prior to 1.30, after changing your Pool Resource,  you must
531   manually update the corresponding values in the Catalog by  using the {\bf
532   update pool} command in the Console program. In Bacula  version 1.30, Bacula
533   does this for you automatically every time it  starts.  
534   
535   When Bacula creates a Media record (Volume), it uses many default  values from
536   the Pool record. If you subsequently change the Pool  record, the new values
537   will be used as a default for the next Volume  that is created, but if you
538   want the new values to apply to existing  Volumes, you must manually update
539   the Volume Catalog entry using  the {\bf update volume} command in the Console
540   program. 
541
542 \label{CompressionNotWorking}
543 \subsection*{Why aren't my files compressed?}
544 \item [I Have Configured Compression On, But None of My Files Are
545    Compressed.  Why?]
546 \index[general]{Compression}
547    There are two kinds of compression. One is tape compression. This  is done by
548    the tape drive hardware, and you either enable or disable  it with system
549    tools such as {\bf mt}. This compression works  independently of Bacula.  
550    
551    Bacula also has compression code, which is normally used only when  backing
552 up
553    to file Volumes. There are two conditions for this  "software" to become
554    enabled.  
555
556 \begin{enumerate}
557 \item You must have the zip development libraries loaded on your  system when
558    building Bacula and Bacula must find this library,  normally {\bf
559    /usr/lib/libz.a}. On RedHat systems, this library  is provided by the {\bf
560    zlib-devel} rpm.  
561
562  If the library is found by Bacula during the {\bf ./configure}  it will be
563  mentioned in the {\bf config.out} line by:  
564
565 \footnotesize
566 \begin{verbatim}
567              ZLIB support:  yes
568           
569 \end{verbatim}
570 \normalsize
571
572 \item You must add the {\bf compression=gzip} option on your  Include
573    statement in the Director's configuration file.  
574 \end{enumerate}
575
576 \label{NewTape}
577 \item [Bacula is Asking for a New Tape After 2 GB of Data but My Tape
578    holds 33 GB. Why?]
579 \index[general]{Tape capacity}
580 There are several reasons why Bacula will request a new tape.  
581
582 \begin{itemize}
583 \item There is an I/O error on the tape. Bacula prints an error message  and
584    requests a new tape. Bacula does not attempt to continue writing  after an
585 I/O
586    error.  
587 \item Bacula encounters and end of medium on the tape. This is not always 
588    distinguishable from an I/O error.  
589 \item You have specifically set some size limitation on the tape. For  example
590    the {\bf Maximum Volume Bytes} or {\bf Maximum Volume Files}  in the
591    Director's Pool resource, or {\bf Maximum Volume Size} in  the Storage
592   daemon's Device resource.  
593 \end{itemize}
594
595 \label{LevelChanging}
596 \subsection*{Incremental backups are not working}
597 \item [Bacula is Not Doing the Right Thing When I Request an Incremental
598    Backup. Why?]
599    \index[general]{Incremental backups}
600    As explained in one of the previous questions, Bacula will automatically 
601    upgrade an Incremental or Differential job to a Full backup if it cannot 
602 find
603    a prior Full backup or a suitable Full backup. For the gory details  on
604    how/when Bacula decides to upgrade levels please see the  
605    \ilink{Level record}{Level} in the Director's  configuration
606    chapter of this manual.  
607    
608    If after reading the above mentioned section, you believe that Bacula  is not
609    correctly handling the level (Differential/Incremental),  please send us the
610    following information for analysis:  
611
612 \begin{itemize}
613 \item Your Director's configuration file.  
614 \item The output from {\bf list jobs} covering the period where you  are
615    having the problem.  
616 \item The Job report output from the prior Full save (not critical).  
617 \item An {\bf llist jobid=nnn} where nnn is the JobId of the prior  Full save.
618  
619 \item The Job report output from the save that is doing the  wrong thing (not
620    critical).  
621 \item An {\bf llist jobid=nnn} where nnn is the JobId of the job  that was not
622    correct.  
623 \item An explanation of what job went wrong and why you think it did.  
624    \end{itemize}
625
626 The above information can allow us to analyze what happened, without it, 
627 there is not much we can do.  
628
629 \label{WaitForever}
630 \subsection*{I am waiting forever for a backup of an offsite machine}
631 \item [I am Backing Up an Offsite Machine with an Unreliable Connection.
632    The  Director Waits Forever for the Client to Contact the SD. What Can  I
633 Do?]
634    \index[general]{I am Backing Up an Offsite Machine with an Unreliable
635 Connection.
636    The Director Waits Forever for the Client to Contact the SD. What Can I Do?}
637    Bacula was written  on the assumption that it will have a good TCP/IP
638    connection  between all the daemons. As a consequence, the current  Bacula
639    doesn't deal with faulty connections very well. This situation  is slowly
640 being
641    corrected over time.  
642    
643    There are several things you can do to improve the situation.  
644
645 \begin{itemize}
646 \item Upgrade to version 1.32 and use the new SDConnectTimeout record.  For
647    example, set:  
648
649 \footnotesize
650 \begin{verbatim}
651           SD Connect Timeout = 5 min
652           
653 \end{verbatim}
654 \normalsize
655
656 in the FileDaemon resource.  
657 \item Run these kinds of jobs after all other jobs.  
658    \end{itemize}
659
660 \label{sshHanging}
661 \subsection*{SSH hangs forever after starting Bacula}
662 \item [When I ssh into a machine and start Bacula then attempt to exit, 
663    ssh hangs forever.]
664    \index[general]{When I ssh into a machine and start Bacula then attempt to
665 exit,
666    ssh hangs forever. }
667    This happens because Bacula leaves stdin, stdout, and stderr open  for debug
668    purposes. To avoid it, the simplest thing to do is to  redirect the output of
669    those files to {\bf /dev/null} or another  file in your startup script (the
670    RedHat autostart scripts do this  automatically). For example, you start the
671    Director with:  
672    
673 \footnotesize
674 \begin{verbatim}
675     bacula-dir -c bacula-dir.conf ... 0>\&1 2>\&1 >/dev/null
676     
677 \end{verbatim}
678 \normalsize
679
680 and likewise for the other daemons.  
681
682 \label{RetentionPeriods}
683 \subsection*{I'm confused by retention periods}
684 \item [I'm confused by the different Retention periods: File Retention, 
685    Job Retention, Volume Retention. Why are there so many?]
686    \index[general]{I'm confused by the different Retention periods: File
687 Retention,
688    Job Retention, Volume Retention. Why are there so many? }
689    Yes, this certainly can be confusing. The basic reason for so many  is to
690    allow flexibility. The File records take quite a lot of space  in the
691 catalog,
692    so they are typically records you want to remove  rather quickly. The Job
693    records, take very little space, and they  can be useful even without the
694 File
695    records to see what Jobs actually  ran and when. One must understand that if
696    the File records are removed  from the catalog, you cannot use the {\bf
697    restore} command to restore  an individual file since Bacula no longer knows
698    where it is. However,  as long as the Volume Retention period has not
699 expired,
700    the data will  still be on the tape, and can be recovered from the tape.  
701    
702    For example, I keep a 30 day retention period for my Files to  keep my
703 catalog
704    from getting too big, but I keep my tapes for a  minimum of one year, just in
705    case.  
706
707 \label{MaxVolumeSize}
708 \subsection*{MaxVolumeSize is ignored}
709 \item [Why Does Bacula Ignore the MaxVolumeSize Set in my Pool?]
710    \index[general]{Why Does Bacula Ignore the MaxVolumeSize Set in my Pool? }
711    The MaxVolumeSize that Bacula uses comes from the Media record,  so most
712    likely you changed your Pool, which is used as the default  for creating
713 Media
714    records, {\bf after} you created your Volume. Check  what is in the Media
715    record by doing: 
716
717 \footnotesize
718 \begin{verbatim}
719 llist Volume=xxx
720 \end{verbatim}
721 \normalsize
722
723 If it doesn't have the right value, you can use: 
724
725 \footnotesize
726 \begin{verbatim}
727 update Volume=xxx
728 \end{verbatim}
729 \normalsize
730
731 to change it.  
732
733 \label{ConnectionRefused}
734 \subsection*{I get a Connection refused when connecting to my Client}
735 \item [In connecting to my Client, I get "ERR:Connection Refused.  Packet
736    Size too big from File daemon:192.168.1.4:9102" Why?]
737    \index[general]{In connecting to my Client, I get "ERR:Connection
738 Refused.
739    Packet Size too big from File daemon:192.168.1.4:9102" Why? }
740    This is typically a communications error resulting  from one of the
741 following:
742  
743
744 \begin{itemize}
745 \item Old versions of Bacula, usually a Win32 client, where two  threads were
746    using the same I/O packet. Fixed in more recent  versions. Please upgrade.  
747 \item Some other program such as an HP Printer using the same  port (9102 in
748    this case).  
749 \end{itemize}
750
751 If it is neither of the above, please submit a bug report at  
752 \elink{bugs.bacula.org}{http://bugs.bacula.org}.  
753
754 Another solution might be to run the daemon with the debug  option by:  
755
756 \footnotesize
757 \begin{verbatim}
758     Start a DOS shell Window.
759     cd c:\bacula\bin
760     bacula-fd -d100 -c c:\bacula\bin\bacula-fd.conf
761     
762 \end{verbatim}
763 \normalsize
764
765 This will cause the FD to write a file {\bf bacula.trace}  in the current
766 directory, which you can examine to determine  the problem.  
767
768 \subsection*{Long running jobs die with Pipe Error}
769 \item [During long running jobs my File daemon dies with Pipe Error, or
770        some other communications error. Why?]
771    \index[general]{Communications Errors}
772    \index[general]{Pipe Errors}
773    There are a number of reasons why a connection might break.
774    Most often, it is a router between your two computers that times out
775    inactive lines (not respecting the keepalive feature that Bacula uses).
776    In that case, you can use the {\bf Heartbeat Interval} directive in
777    both the Storage daemon and the File daemon. 
778
779    In at least one case, the problem has been a bad driver for a Win32
780    NVidia NForce 3 ethernet card with driver (4.4.2 17/05/2004). 
781    In this case, a good driver is (4.8.2.0 06/04/2005).  Moral of
782    the story, make sure you have the latest ethernet drivers
783    loaded, or use the following workaround as suggested by Thomas
784    Simmons for Win32 machines:
785      
786    Browse to:
787    Start \gt{} Control Panel \gt{} Network Connections
788
789    Right click the connection for the nvidia adapter and select properties. 
790    Under the General tab, click "Configure...". Under the Advanced tab set 
791    "Checksum Offload" to disabled and click OK to save the change.  
792
793    Lack of communications, or communications that get interrupted can
794    also be caused by Linux firewalls where you have a rule that throttles
795    connections or traffic.  For example, if you have:
796
797 \footnotesize
798 \begin{verbatim}
799 iptables -t filter -A INPUT -m limit --limit 3/second --limit-burst 3 -j DROP
800 \end{verbatim}
801 \normalsize
802
803    you will want to add the following rules {\bf before} the above rule:
804 \footnotesize
805 \begin{verbatim}
806 iptables -t filter -A INPUT --dport 9101 -j ACCEPT
807 iptables -t filter -A INPUT --dport 9102 -j ACCEPT
808 iptables -t filter -A INPUT --dport 9103 -j ACCEPT
809 \end{verbatim}
810 \normalsize
811    This will ensure that any Bacula traffic will not get terminated because
812    of high usage rates.
813    
814 \subsection*{How to I tell the Job which Volume to use?}
815 \item[I can't figure out how to tell the job which volume to use]
816    \index[general]{What tape to mount}
817   This is an interesting statement. I now see that a number of people new to
818   Bacula have the same problem as you, probably from using programs like tar.
819
820   In fact, you do not tell Bacula what tapes to use.  It is the inverse.  Bacula
821   tells you want tapes it wants.  You put tapes at its disposition and it
822   chooses.  
823
824   Now, if you *really* want to be tricky and try to tell Bacula what to do, it
825   will be reasonable if for example you mount a valid tape that it can use on a
826   drive, it will most likely go ahead and use it.  It also has a documented
827   algorithm for choosing tapes -- but you are asking for problems ...
828
829   So, the trick is to invert your concept of things and put Bacula in charge of
830   handling the tapes.  Once you do that, you will be fine.  If you want to
831   anticipate what it is going to do, you can generally figure it out correctly
832   and  get what you want.  
833
834   If you start with the idea that you are going to force or tell Bacula to use
835   particular tapes or you insist on trying to run in that kind of mode, you will
836   probably not be too happy.
837
838   I don't want to worry about what tape has what data. That is what Bacula is
839   designed for.
840
841   If you have an application where you *really* need to remove a tape each day
842   and  insert a new one, it can be done the directives exist to accomplish that.
843   In such a case, one little "trick" to knowing what tape Bacula will want at
844   2am  while you are asleep is to run a tiny job at 4pm while you are still at
845   work  that backs up say one directory, or even one file. You will quickly find
846   out  what tape it wants, and you can mount it before you go home ... 
847
848 \end{description}