]> git.sur5r.net Git - bacula/docs/blobdiff - docs/manual/firewalls.tex
Apply Ludovic's patches
[bacula/docs] / docs / manual / firewalls.tex
index abe36a7005f972795376cabf5a06dacc19e8021b..c3120c408c5f7986f612b9adf2ef464b65839476 100644 (file)
@@ -28,12 +28,12 @@ FD      -> SD:9103
 \end{verbatim}
 \normalsize
 
-Where it should be obvious that DIR represents the Director, FD the File
+Where hopefully it is obvious that DIR represents the Director, FD the File
 daemon or client, and SD the Storage daemon. The numbers that follow those
 names are the standard ports used by Bacula, and the -\gt{} represents the
 left side making a connection to the right side (i.e. the right side is the
 "server" or is listening on the specified port), and the left side is the
-"client" who initiates the conversation. 
+"client" that initiates the conversation. 
 
 Note, port 9103 serves both the Director and the File daemon, each having its
 own independent connection. 
@@ -64,8 +64,16 @@ Thanks to Raymond Norton for this tip.
 \index[general]{Concrete Example }
 \addcontentsline{toc}{subsection}{Concrete Example}
 
-Jesse Guardiani's solution for his network for this problem, in his own words,
-is: 
+The following discussion was originally written by
+Jesse Guardiani because he has 'internal' and 'external' requiring the
+Director and the Client to use different IP addresses.  His original
+solution was to define two different Storage resources in the Director's
+conf file each pointing to the same Storage daemon but with different
+IP addresses.  In Bacula 1.38.x this no longer works, because Bacula makes
+a 1 to 1 association between a Storage daemon resource and a Device (such
+as an Autochanger).  As a consequence, I have modified his original
+text to a method that I believe will work, but is as of yet untested
+(KES - July 2006).
 
 My bacula server is on the 192.168.1.0/24 network at IP address 192.168.1.52.
 For the sake of discussion we will refer to this network as the 'internal'
@@ -181,42 +189,38 @@ server-sd. I have just *one* Device resource in my server-sd.conf file:
 
 \footnotesize
 \begin{verbatim}
+Autochanger {
+  Name = "autochanger1";\
+  Device = Drive0
+  Changer Device = /dev/ch0;
+  Changer Command = "/usr/local/sbin/chio-bacula %c %o %S %a";
+}
 Device {
-  Name = "autochanger1";
+  Name = Drive0
+  DriveIndex = 0
   Media Type = AIT-1;
   Archive Device = /dev/nrsa1;
-  Changer Device = /dev/ch0;
-  Changer Command = "/usr/local/sbin/chio-bacula %c %o %S %a";
   Label Media = yes;
   AutoChanger = yes;
   AutomaticMount = yes;               # when device opened, read it
   AlwaysOpen = yes;
-    Hardware End of Medium = No
-    Fast Forward Space File = No
-    BSF at EOM = yes
+  Hardware End of Medium = No
+  Fast Forward Space File = No
+  BSF at EOM = yes
 }
 \end{verbatim}
 \normalsize
 
 (note, please see 
 \ilink{the Tape Testing}{FreeBSDTapes} chapter of this manual
-for important FreeBSD information.) However, I have *two* Storage resources in
-my server-dir.conf file: 
+for important FreeBSD information.) However, unlike previously, there
+is only one Storage definition in my server-dir.conf file: 
 
 \footnotesize
 \begin{verbatim}
 Storage {
-  Name = "autochanger1-int"    # Storage device for backing up
-  Address = server.int.mydomain.tld
-  SDPort = 9103
-  Password = "mysecretpassword"
-  Device = "autochanger1"
-  Media Type = AIT-1
-  Autochanger = yes
-}
-Storage {
-  Name = "autochanger1-ext"    # Storage device for backing up
-  Address = firewall.mydomain.tld
+  Name = "autochanger1"    # Storage device for backing up
+  Address = Storage-server
   SDPort = 9103
   Password = "mysecretpassword"
   Device = "autochanger1"
@@ -226,13 +230,15 @@ Storage {
 \end{verbatim}
 \normalsize
 
-Note that BOTH of the above server-dir.conf Storage resources use the same
-'autochanger1' Device resource from server-sd.conf. 
+Note that the Storage resource uses neither of the two addresses to
+the Storage daemon -- neither server.int.mydomain.tld nor
+firewall.mydomain.tld, but instead uses the address Storage-server.
+
+What is key is that in the internal net, Storage-server is resolved
+to server.int.mydomain.tld, either with an entry in /etc/hosts, or by
+creating and appropriate DNS entry, and on the external net (the Client
+machine), Storage-server is resolved to firewall.mydomain.tld.
 
-My backup jobs run consecutively, one after the other, so only one of the
-above Storage resources is being used by Bacula file daemons at any given
-time. I don't know if this would cause problems at a site that runs more than
-one backup in parallel to a single tape device. 
 
 In addition to the above, I have two Client resources defined in
 server-dir.conf: 
@@ -289,10 +295,11 @@ Job {
 \normalsize
 
 It is important to notice that because the 'Private1-Backup' Job is intended
-to back up a machine on the internal network it uses the 'autochanger1-int'
-Storage resource. On the other hand, the 'Public1-Backup' Job is intended to
-back up a machine on the external network, so it uses the 'autochanger1-ext'
-Storage resource. 
+to back up a machine on the internal network so it resolves Storage-server
+to contact the Storage daemon via the internal net.
+On the other hand, the 'Public1-Backup' Job is intended to
+back up a machine on the external network, so it resolves Storage-server
+to contact the Storage daemon via the external net.
 
 I have left the Pool, Catalog, Messages, FileSet, Schedule, and Director
 resources out of the above server-dir.conf examples because they are not
@@ -314,8 +321,8 @@ using server-sd then my understanding of the order of events is this:
 \item server-dir connects to private1-fd at private1.int.mydomain.tld:9102  
 \item server-dir tells private1-fd to start sending the files defined in  the
    'Private1-Backup' Job's FileSet resource to the Storage resource 
-   'autochanger1-int', which we have defined in server-dir.conf as having the 
-address:port of server.int.mydomain.tld:9103.  
+   'autochanger1', which we have defined in server-dir.conf as having the 
+address:port of Storage-server, which is mapped by DNS to server.int.mydomain.tld.
 \item private1-fd connects to server.int.mydomain.tld:9103 and begins sending 
    files. 
    \end{enumerate}
@@ -333,8 +340,9 @@ this:
    public1.mydomain.tld:9102  
 \item server-dir tells public1-fd to start sending the files defined in  the
    'Public1-Backup' Job's FileSet resource to the Storage resource 
-   'autochanger1-ext', which we have defined in server-dir.conf as having the 
-address:port of firewall.mydomain.tld:9103.  
+   'autochanger1', which we have defined in server-dir.conf as having the 
+   same address:port as above of Storage-server, but which on this machine
+   is resolved to firewall.mydomain.tld:9103.  
 \item public1-fd connects to firewall.mydomain.tld:9103 and begins sending 
    files. 
    \end{enumerate}