]> git.sur5r.net Git - bacula/bacula/blob - bacula/kernstodo
Update Makefiles for Irix and kernstodo
[bacula/bacula] / bacula / kernstodo
1                  Kern's ToDo List
2                   11 August 2002
3
4 Irix conversion notes:
5 - no uuencode
6 - no hostname
7 To do:    
8 - Document passwords.
9 - Document running multiple Jobs
10 - Document that two Verifys at same time on same client do not work.
11 - Document how to recycle a tape in 7 days even if the backup takes a long time.
12 - Document default config file locations.
13 - Document better includes (does it cross file systems ?).
14 - Document specifically how to add new File daemon to config files.
15 - Document forcing a new tape to be used.
16 - Document "Error in message.c:500 Mail program terminated in error.
17
18 From Chuck:
19 --bindir is wrong and does not reflect prefix= in the *_sqlite_* scripts
20   (src/cats)
21 --top level configure options are not passed to the depkgs, particularly
22   prefix=
23 --Also, it might be better to split the depkgs location from the --with-sqlite
24   location. 
25 --should be able to specify e.g. --with-sqlite=/opt/local and have it find
26   lib, bin, sbin for itself
27   I tried this and it didn't find sqlite.h
28 --sd.conf password does not match dir.conf storage password
29 =======
30
31 - Fix catalog filename truncation in sql_get and sql_create. Use
32   only a single filename split routine.
33 - Add command to reset VolFiles to a larger value (don't allow
34   a smaller number or print big warning).
35 - Make SD disallow writing on Volume with fewer files than in
36   the catalog.
37 - Make Restore report an error if FD or SD term codes are not OK.
38 - Convert all %x substitution variables, which are hard to remember
39   and read to %(variable-name)s.  Idea from TMDA.
40 - Report volume write rate.
41 - Report compression % and other compression statistics if turned on.
42 - Add JobLevel in FD status (but make sure it is defined).
43 - Pass "Catalog Files = no" to storage daemon to eliminate
44   network traffic.
45 - Make Pool resource handle Counter resources.
46 - Remove NextId for SQLite. Optimize.
47 - Fix gethostbyname() to use gethostbyname_r()
48 - Implement ./configure --with-client-only
49 - Strip trailing / from Include
50 - Move all SQL statements into a single location.
51 - Cleanup db_update_media and db_update_pool
52 - Add UA rc and history files.
53 - put termcap (used by console) in ./configure and
54   allow -with-termcap-dir.
55 - Remove JobMediaId it is not used.
56 - Enhance time and size scanning routines.
57 - Fix Autoprune for Volumes to respect need for full save.
58 - DateWritten may be wrong.
59 - Fix Win32 config file definition name on /install
60 - When we are at EOM, we must ask each job to write JobMedia
61   record (update_volume_info).
62 - No READLINE_SRC if found in alternate directory.
63 - Add Client FS/OS id (Linux, Win95/98, ...).
64 - Put Windows files in Windows stream?
65 - Ensure that everyone uses btime routines.
66
67   
68 Projects:
69 - Add Base job.
70 - Make Storage daemon multi-buffer to tape (i.e. writer thread).
71 - Implement Label templates
72 - Define definitive tape format.
73 - GUI for interactive restore.
74 - Interactive backup.
75 - Write bscan program (skeleton exists).
76 - Write a regression script
77 - Add ssl to daemon communications
78 - New daemon communications protocol.
79 - SD can buffer to disk.
80
81 1.  Implement Base jobs.
82     Big savings in tape usage. Will require more resources.
83     i.e. DIR must send FD a list of files/attribs, and the FD must
84     search the list and compare it for each file to be saved.
85
86 2.  Make Storage daemon multi-buffer to tape (i.e. writer thread).
87     Hopefully much faster backups. Each Job will have a pool of
88     buffers that it hands off to the tape writer thread. 
89
90 3.  Implement Label templates
91     Better automated label creation, using design that is
92     already documented in the manual.
93
94 4.  Define definitive tape format.
95     A lot of design thought needed here.
96     
97 5.  GUI for interactive restore.
98     Probably will do in Gtk, but would be nice in Browser.
99
100 6.  Interactive backup.
101     Really part of 5.
102
103 7.  Write bscan program (skeleton exists).
104     Allows recovery from tape.
105
106 8.  Write a regression script
107     Needed to ensure long term stability.
108
109 9.  Add ssl to daemon communications
110     Needed for secure operations.
111
112 10. Multiple simultaneous Jobs.
113     I don't think this will take much.
114
115 11. New daemon communication protocol. 
116     Use serial for all daemon communications, allow transfer
117     of any data type with type checking and optional name
118     checking.
119
120 12. SD can use intermediate file storage to buffer data
121     while waiting for tape to catch up.  This requires that
122     item 2 be implemented (or simultaneously implemented).
123
124 I haven't put these in any particular order.
125
126 Small projects:
127 - Rework Storage daemon with new rwl_lock routines.
128 - Compare tape to Client files (attributes, or attributes and data) 
129 - Restore options (overwrite, overwrite if older,
130    overwrite if newer, never overwrite, ...)
131 - Restore to a particular time -- e.g. before date, after date. 
132 - On command write out a bootstrap file (at end of job).
133 - Make all database Ids 64 bit.
134 - Pass JCR to database routines permitting better error printing.
135 - Make bls accept bootstrap record.
136 - Write an applet for Linux.
137 - Make SD reject writing on tape where Catalog and tape # files
138   don't agree (possibly OK if tape > catalog).
139 - Implement new daemon communications protocol.
140 - Add DIR config directive to spool attributes.
141 - Pass DIR config variable to SD for no attributes.
142 - Create JobMedia record for all running Jobs when Media changes.
143 - Send Volumes needed during restore to Console (just after
144   create_volume_list) -- also in restore command?
145 - Add estimate to Console commands
146 - Find solution to blank filename (i.e. path only) problem.
147
148 Dump:
149   mysqldump -f  --opt bacula >bacula
150
151
152 To be done:
153 - Remove PoolId from Job table, it exists in Media.
154 - Allow console commands to detach or run in background.
155 - Fix status delay on storage daemon during rewind.
156 - Add VerNo to each Session label record. 
157 - Add Job to Session records.
158 - Add VOLUME_CAT_INFO to the EOS tape record (as
159   well as to the EOD record).
160 - Add SD message variables to control operator wait time
161   - Maximum Operator Wait
162   - Minimum Message Interval
163   - Maximum Message Interval
164 - Add EOM handling variables
165   - Write EOD records
166   - Require EOD records
167 - Send Operator message when cannot read tape label.
168 - Think about how to handle I/O error on MTEOM.
169 - If Storage daemon aborts a job, ensure that this
170   is printed in the error message.
171 - Verify level=Volume (scan only), level=Data (compare of data to file).
172   Verify level=Catalog, level=InitCatalog
173 - Dump of Catalog
174 - Cold start full restore (restore catalog then
175   user selects what to restore).  Write summary file containing only
176   Job, Media, and Catalog information. Store on another machine.
177 - Dump/Restore database
178 - File system type
179 - Events file
180 - Add keyword search to show command in Console.
181 - Fix Win2000 error with no messages during startup.
182 - Events : tape has more than xxx bytes.
183 - In Storage daemon, status should include job cancelled.
184 - Write general list maintenance subroutines.
185 - Implement immortal format with EDOs. 
186 - Restrict characters permitted in a Resource name.
187 - Provide definitive identification of  type in backup.
188 - Complete  code in Bacula Resources -- this will permit
189   reading a new config file at any time.
190 - Document new Console
191 - Handle ctl-c in Console
192 - Test restore of Windows backup
193 - Implement LabelTemplate (at least first cut).
194 - Implement script driven addition of File daemon to
195   config files.
196
197 - Bug: anonymous Volumes requires mount in some cases.
198 - see setgroup and user for Bacula p4-5 of stunnel.c
199 - Implement new serialize subroutines
200    send(socket, "string", &Vol, "uint32", &i, NULL)
201 - Add save type to Session label.
202 - Correct date on Session label.
203 - On I/O error, write EOF, then try to write again.
204 - Audit all UA commands to ensure that we always prompt where
205   possible.
206 - If ./btape is called without /dev, assume argument is
207   a Storage resource name.
208 - Put memory utilization in Status output of each daemon
209   if full status requested or if some level of debug on.
210 - Make database type selectable by .conf files i.e. at runtime
211 - gethostbyname failure in bnet_connect() continues
212   generating errors -- should stop.
213 - Don't create a volume that is already written. I.e. create only once.
214 - If error at end of tape, implement some way to kill waiting processes.
215 - Add HOST to Volume label.
216 - Set flag for uname -a.  Add to Volume label.
217 - Implement throttled work queue.
218 - Write bscan program that will syncronize the DB Media record with
219   the contents of the Volume -- for use after a crash.
220 - Check for EOT at ENOSPC or EIO or ENXIO (unix Pc)
221 - Allow multiple Storage specifications (or multiple names on
222   a single Storage specification) in the Job record. Thus a job 
223   can be backed up to a number of storage devices.
224 - Implement full MediaLabel code.
225 - Implement dump label to UA
226 - Copy volume using single drive.
227 - Copy volume with multiple driven (same or different block size).     
228 - Add block size (min, max) to Vol label.
229 - Concept of VolumeSet during restore which is a list
230   of Volume names needed.
231 - Restore files modified after date
232 - Restore file modified before date
233 - Emergency restore info:
234   - Backup Bacula
235   - Backup working directory
236   - Backup Catalog
237 - Restore options (do not overwrite)
238 - Restore -- do nothing but show what would happen
239 - SET LD_RUN_PATH=$HOME/mysql/lib/mysql
240 - Put Job statistics in End Session Label (files saved,
241   total bytes, start time, ...).     
242 - Put FileSet name in the SOS label.
243 - Implement Restore FileSet=
244 - Write a scanner for the UA (keyword, scan-routine, result, prompt).
245 - Create a protocol.h and protocol.c where all protocol messages
246   are concentrated.
247 - If SD cannot open a drive, make it periodically retry.
248 - Put Bacula version somewhere in Job stream, probably Start Session
249   Labels.
250 - Remove duplicate fields from jcr (e.g. jcr.level and
251   jcr.jr.Level, ...).
252 - Timout a job or terminate if link goes down, or reopen link and query.
253 - Define how we handle times to avoid problem with Unix dates (2049 ?).
254 - Fill all fields in Vol/Job Header -- ensure that everything
255   needed is written to tape. Think about restore to Catalog
256   from tape.  Client record needs improving.
257 - Find general solution for sscanf size problems (as well
258   as sprintf. Do at run time?
259
260 - Concept of precious tapes (cannot be reused).
261 - Allow FD to run from inetd ???
262 - Preprocessing command per file.
263 - Postprocessing command per file (when restoring).
264
265 - Restore should get Device and Pool information from
266   job record rather than from config.
267 - Autolabel should be specified by DR instead of SD.
268 - Ability to recreate the catalog from a tape.
269 - Find out how to get the system tape block limits, e.g.:
270   Apr 22 21:22:10 polymatou kernel: st1: Block limits 1 - 245760 bytes.  
271   Apr 22 21:22:10 polymatou kernel: st0: Block limits 2 - 16777214 bytes.
272 - Storage daemon    
273   - Add media capacity
274   - AutoScan (check checksum of tape)
275   - Format command = "format /dev/nst0"
276   - MaxRewindTime
277   - MinRewindTime
278   - MaxBufferSize
279   - Seek resolution (usually corresponds to buffer size)
280   - EODErrorCode=ENOSPC or code
281   - Partial Read error code
282   - Partial write error code
283   - Nonformatted read error
284   - Nonformatted write error
285   - WriteProtected error
286   - IOTimeout
287   - OpenRetries
288   - OpenTimeout
289   - IgnoreCloseErrors=yes
290   - Tape=yes
291   - NoRewind=yes
292 - Pool
293   - Maxwrites
294   - Recycle period
295 - Job
296   - MaxWarnings
297   - MaxErrors (job?)
298 =====
299 - Eliminate duplicate File records to shrink database.
300 - FD sends unsaved file list to Director at end of job. 
301 - Write a Storage daemon that uses pipes and
302   standard Unix programs to write to the tape.
303   See afbackup.
304 - Need something that monitors the JCR queue and
305   times out jobs by asking the deamons where they are.
306 - Add daemon JCR JobId=0 to have a daemon context
307 - Pool resource
308   - Auto label
309   - Auto media verify
310   - Client (list of clients to force client)
311   - Devices (list of devices to force device)
312   - enable/disable
313   - Groups
314   - Levels
315   - Type: Backup, ...
316   - Recycle from other pools: Yes, No
317   - Recycle to other pools: Yes, no
318   - FileSets
319   - MaxBytes?
320   - Optional MediaType to force media?
321   - Maintain Catalog
322   - Label Template
323   - Retention Period
324   ============
325   - Name
326   - NumVols
327   - NaxVols
328   - CurrentVol
329
330 =====
331   if(connect(sockfd, (struct sockaddr * ) (& addr), sizeof(addr)) .lt. 0){
332     close(sockfd);
333     return(-6);
334   }
335
336   linger.l_onoff = 1;
337   linger.l_linger = 60;
338   i = setsockopt(sockfd, SOL_SOCKET, SO_LINGER, (char *) &linger,
339                                                 sizeof (linger));
340
341   fl = fcntl(sockfd, F_GETFL);
342   fcntl(sockfd, F_SETFL, fl & (~ O_NONBLOCK) & (~ O_NDELAY));
343 ====
344 - Enhance Jmsg code to permit buffering and saving to disk.
345 - device driver = "xxxx" for drives.
346 - restart: paranoid: read label fsf to
347   eom read append block, and go
348   super-paranoid: read label, read all files
349   in between, read append block, and go
350   verify: backspace, read append block, and go
351   permissive: same as above but frees drive
352   if tape is not valid.
353 - Verify from Volume
354 - Ensure that /dev/null works
355 - File daemon should build list of files skipped, and then
356   at end of save retry and report any errors.
357 - Need report class for messages. Perhaps
358   report resource where report=group of messages
359 - Verify from Tape
360 - enhance scan_attrib and rename scan_jobtype, and
361   fill in code for "since" option 
362 - To buffer messages, we need associated jobid and Director name.
363 - Need to save contents of FileSet to tape?
364 - Director needs a time after which the report status is sent
365   anyway -- or better yet, a retry time for the job.
366   Don't reschedule a job if previous incarnation is still running.
367 - Figure out how to save the catalog (possibly a special FileSet).
368 - Figure out how to restore the catalog.
369 - Figure out how to put a Volume into the catalog (from the tape)
370 - Figure out how to do a restore from a Volume
371 - Some way to automatically backup everything is needed????
372 - Need a structure for pending actions:
373   - buffered messages
374   - termination status (part of buffered msgs?)
375 - Concept of grouping Storage devices and job can use
376   any of a number of devices
377 - Drive management
378   Read, Write, Clean, Delete
379 - Login to Bacula; Bacula users with different permissions:
380    owner, group, user
381 - Tape recycle destination
382 - Job Schedule Status
383   - Automatic
384   - Manual
385   - Running
386 - File daemon should pass Director the operating system info
387   to be stored in the Client Record (or verified that it has
388   not changed).
389 - Store info on each file system type (probably in the job header on tape.
390   This could be the output of df; or perhaps some sort of /etc/mtab record.
391
392 Longer term to do:
393 - Use media 1 time (so that we can do 6 days of incremental
394   backups before switching to another tape) (already)
395   specify # times (jobs)
396   specify bytes (already)
397   specify time (seconds, hours, days)
398 - Implement FSM (File System Modules).
399 - Identify unchanged or "system" files and save them to a
400   special tape thus removing them from the standard 
401   backup FileSet -- BASE backup.
402 - Turn virutally all sprintfs into snprintfs.
403 - Heartbeat between daemons.
404 - Audit M_ error codes to ensure they are correct and consistent.
405 - Add variable break characters to lex analyzer.
406   Either a bit mask or a string of chars so that
407   the caller can change the break characters.
408 - Make a single T_BREAK to replace T_COMMA, etc.
409 - Ensure that File daemon and Storage daemon can
410   continue a save if the Director goes down (this
411   is NOT currently the case). Must detect socket error,
412   buffer messages for later. 
413
414
415 Done: (see kernsdone for more)
416 --the console script is broken as installed and has to be hand-massaged with
417   paths, config files etc.
418 - Termination status in FD for Verify = C -- incorrect.
419 - Implement alter_sqlite_tables
420 - Fix scheduler -- see "Hourly cycle". It doesn't do both each
421   hour, rather it alternates between 0:05 and 0:35.
422 - Create Counter DB records.
423 - Fix db_get_job_volume_names() to return array of strings (now works
424   with pool memory.
425 - Eliminate MySQL shared libraries from smtp and daemons not using MySQL.
426 - Compare tape File attributes to Catalog.
427   (File attributes are size, dates, MD5, but not
428    data).
429 - Report bad status from smtp or mail program.
430 - Ensure that Start/End File/Block are correct.
431 - If MySQL database is not running, job terminates with
432   wierd type and wierd error code.
433 - Probably create a jcr with JobId=0 as a master
434   catchall if jcr not found or if operation involves
435   global operation.
436 - The daemons should know when one is already
437   running and refuse to run a second copy.
438 - Figure out how to do a "full" restore from catalog
439 - Make SD send attribute stream to DR but first
440   buffering to file, then sending only when the
441   files are written to tape.
442 - Restore file xx or files xx, yy to their most recent values.
443 - Get correct block/file information in Catalog, pay attention to change of media.
444 - Write better dump of Messages resource.
445 - Authentication between SD and FD