]> git.sur5r.net Git - bacula/docs/blob - docs/manual/consoleconf.tex
kes Make sure valid argument passed to str_to_utime() where Arno
[bacula/docs] / docs / manual / consoleconf.tex
1 %%
2 %%
3
4 \section*{Console Configuration}
5 \label{_ChapterStart36}
6 \index[general]{Configuration!Console}
7 \index[general]{Console Configuration}
8 \addcontentsline{toc}{section}{Console Configuration}
9
10 \subsection*{General}
11 \index[general]{General}
12 \addcontentsline{toc}{subsection}{General}
13
14 The Console configuration file is the simplest of all the configuration files,
15 and in general, you should not need to change it except for the password. It
16 simply contains the information necessary to contact the Director or
17 Directors. 
18
19 For a general discussion of configuration file and resources including the
20 data types recognized by {\bf Bacula}, please see the 
21 \ilink{Configuration}{_ChapterStart16} chapter of this manual. 
22
23 The following Console Resource definition must be defined: 
24
25 \subsection*{The Director Resource}
26 \label{DirectorResource3}
27 \index[general]{Director Resource}
28 \index[general]{Resource!Director}
29 \addcontentsline{toc}{subsection}{Director Resource}
30
31 The Director resource defines the attributes of the Director running on the
32 network. You may have multiple Director resource specifications in a single
33 Console configuration file. If you have more than one, you will be prompted to
34 choose one when you start the {\bf Console} program. 
35
36 \begin{description}
37
38 \item [Director]
39    \index[console]{Director}
40    Start of the Director directives.
41
42 \item [Name = \lt{}name\gt{}]
43    \index[console]{Name}
44    The director name used to select  among different Directors, otherwise, this
45    name is not used. 
46
47 \item [DIRPort = \lt{}port-number\gt{}]
48    \index[dir]{DIRPort}
49    Specify the port to use to connect  to the Director. This value will most
50    likely already be set to the value  you specified on the {\bf
51    \verb:--:with-base-port} option of the  {\bf ./configure} command. This port must be
52    identical to the  {\bf DIRport} specified in the {\bf Director} resource of
53    the \ilink{Director's configuration}{_ChapterStart40} file.  The
54    default is 9101 so this directive is not normally specified. 
55
56 \item [Address = \lt{}address\gt{}]
57    \index[dir]{Address}
58    Where the address is a host name,  a fully qualified domain name, or a network
59    address used to connect  to the Director. 
60
61 \item [Password = \lt{}password\gt{}]
62    \index[dir]{Password}
63    Where the password is the  password needed for the Director to accept the
64 Console connection.  This password must be identical to the {\bf Password}
65 specified in  the {\bf Director} resource of the 
66 \ilink{Director's configuration}{_ChapterStart40} file. This 
67 directive is required. 
68 \end{description}
69
70 An actual example might be: 
71
72 \footnotesize
73 \begin{verbatim}
74 Director {
75   Name = HeadMan
76   address = rufus.cats.com
77   password = xyz1erploit
78 }
79 \end{verbatim}
80 \normalsize
81
82 \subsection*{The ConsoleFont Resource}
83 \index[general]{Resource!ConsoleFont}
84 \index[general]{ConsoleFont Resource}
85 \addcontentsline{toc}{subsection}{ConsoleFont Resource}
86
87 The ConsoleFont resource is available only in the GNOME version of the
88 console. It permits you to define the font that you want used to display in
89 the main listing window. 
90
91 \begin{description}
92
93 \item [ConsoleFont]
94    \index[console]{ConsoleFont}
95    Start of the ConsoleFont directives. 
96
97 \item [Name = \lt{}name\gt{}]
98    \index[console]{Name}
99    The name of the font. 
100
101 \item [Font = \lt{}Pango Font Name\gt{}]
102    \index[console]{Font}
103    The string value given here defines the desired font. It  is specified in the
104    Pango format. For example, the default specification is: 
105
106 \footnotesize
107 \begin{verbatim}
108 Font = "LucidaTypewriter 9"
109 \end{verbatim}
110 \normalsize
111
112 \end{description}
113
114 Thanks to Phil Stracchino for providing the code for this feature. 
115
116 An different example might be: 
117
118 \footnotesize
119 \begin{verbatim}
120 ConsoleFont {
121   Name = Default
122 Font = "Monospace 10"
123 }
124 \end{verbatim}
125 \normalsize
126
127 \subsection*{The Console Resource}
128 \label{ConsoleResource}
129 \index[general]{Console Resource}
130 \index[general]{Resource!Console}
131 \addcontentsline{toc}{subsection}{Console Resource}
132
133 As of Bacula version 1.33 and higher, there are three different kinds of
134 consoles, which the administrator or user can use to interact with the
135 Director. These three kinds of consoles comprise three different security
136 levels. 
137
138 \begin{itemize}
139 \item The first console type is an {\bf anonymous} or {\bf default}  console,
140    which has full privileges. There is no console  resource necessary for this
141    type since the password is  specified in the Director resource. This is the
142 kind of  console that was initially implemented in versions prior to  1.33 and
143 remains valid. Typically you would use it only  for administrators.  
144 \item The second type of console, and new to version 1.33 and  higher is a
145    "named" console defined within a  Console resource in both the Director's
146    configuration file  and in the Console's configuration file. Both the names 
147 and the passwords in these two entries must match much as  is the case for
148 Client programs. 
149
150 This second type of  console begins with absolutely no privileges except those
151 explicitly specified in the Director's Console resource.  Thus you can have
152 multiple Consoles with different names  and passwords, sort of like multiple
153 users, each with  different privileges. As a default, these consoles can do 
154 absolutely nothing -- no commands what so ever. You give  them privileges or
155 rather access to commands and resources  by specifying access control lists in
156 the Director's  Console resource. Note, if you are specifying such a  console,
157 you will want to put a null password in the  Director resource.  
158 \item The third type of console is similar to the above mentioned  one in that
159    it requires a Console resource definition in  both the Director and the
160    Console. In addition, if the  console name, provided on the {\bf Name =}
161 directive, is  the same as a Client name, the user of that console is 
162 permitted to use the {\bf SetIP} command to change the  Address directive in
163 the Director's client resource to the  IP address of the Console. This permits
164 portables or other  machines using DHCP (non-fixed IP addresses) to 
165 "notify" the Director of their current IP  address. 
166 \end{itemize}
167
168 The Console resource is optional and need not be specified. However, if it is
169 specified, you can use ACLs (Access Control Lists) in the Director's
170 configuration file to restrict the particular console (or user) to see only
171 information pertaining to his jobs or client machine. 
172
173 The following configuration files were supplied by Phil Stracchino. For
174 example, if we define the following in the user's bconsole.conf file (or
175 perhaps the wx-console.conf file): 
176
177 \footnotesize
178 \begin{verbatim}
179  Director {
180    Name = MyDirector
181    DIRport = 9101
182    Address = myserver
183    Password = "XXXXXXXXXXX"    # no, really.  this is not obfuscation.
184 }
185  
186  Console {
187    Name = restricted-user
188    Password = "UntrustedUser"
189 }
190 \end{verbatim}
191 \normalsize
192
193 Where the Password in the Director section is deliberately incorrect, and the
194 Console resource is given a name, in this case {\bf restricted-client}. Then
195 in the Director's bacula-dir.conf file (not directly accessible by the user),
196 we define: 
197
198 \footnotesize
199 \begin{verbatim}
200 Console {
201   Name = restricted-user
202   Password = "UntrustedUser"
203   JobACL = "Restricted Client Save"
204   ClientACL = restricted-client
205   StorageACL = main-storage
206   ScheduleACL = *all*
207   PoolACL = *all*
208   FileSetACL = "Restricted Client's FileSet"
209   CatalogACL = DefaultCatalog
210   CommandACL = run
211 }
212 \end{verbatim}
213 \normalsize
214
215 the user logging into the Director from his Console will get logged in as {\bf
216 restricted-client}, and he will only be able to see or access a Job with the
217 name {\bf Restricted Client Save} a Client with the name {\bf
218 restricted-client}, a Storage device {\bf main-storage}, any Schedule or Pool,
219 a FileSet named {\bf Restricted Client's File}, a Catalog named {\bf
220 DefaultCatalog}, and the only command he can use in the Console is the {\bf
221 run} command. In other words, this user is rather limited in what he can see
222 and do with Bacula. 
223
224 \subsection*{Console Commands}
225 \index[general]{Console Commands}
226 \index[general]{Commands!Console}
227 \addcontentsline{toc}{subsection}{Console Commands}
228
229 For more details on running the console and its commands, please see the 
230 \ilink{Bacula Console}{_ConsoleChapter} chapter of this manual. 
231
232 \subsection*{Sample Console Configuration File}
233 \label{SampleConfiguration2}
234 \index[general]{File!Sample Console Configuration}
235 \index[general]{Sample Console Configuration File}
236 \addcontentsline{toc}{subsection}{Sample Console Configuration File}
237
238 An example Console configuration file might be the following: 
239
240 \footnotesize
241 \begin{verbatim}
242 #
243 # Bacula Console Configuration File
244 #
245 Director {
246   Name = HeadMan
247   address = "my_machine.my_domain.com"
248   Password = Console_password
249 }
250 \end{verbatim}
251 \normalsize