Kern Sibbald wrote:
> Try pulling the latest SVN revision 5158.  It should be a lot closer.  
> Without 
> being able to compile it, I cannot be 100% sure I got them all.

Okay, I updated to 5159 and, after one small change (in the attached patch) I
was able to compile.

The TLS test succeeded for some reason, even though it was missing the
scripts/copy-tls-confs file (also attached) - apparently I forgot to include
that the TLS test patch I sent in.  After adding the script back in it worked
fine.

Other than that, the only test that failed was wierd-files2.  More
specifically, it looks like several files that started out as hardlinks to the
same file became seperate inodes:

osx-w:~/bacula/regress netops$ ls -i weird-files | grep normal | sort
1910268 another-hardlink-to-normalfile
1910268 hardlink-to-normalfile
1910268 normalfile
osx-w:~/bacula/regress netops$ ls -i weird-files2 | grep normal | sort
1910632 another-hardlink-to-normalfile
1910639 hardlink-to-normalfile
1910641 normalfile

Full output of test with debug enabled attached.

-- 
Frank Sweetser fs at wpi.edu  |  For every problem, there is a solution that
WPI Senior Network Engineer   |  is simple, elegant, and wrong. - HL Mencken
    GPG fingerprint = 6174 1257 129E 0D21 D8D4  E8A3 8E39 29E3 E2E8 8CEC
--- src/filed/restore.c (revision 5169)
+++ src/filed/restore.c (working copy)
@@ -552,7 +552,7 @@
             }
 
             if (extract_data(jcr, &rctx.forkbfd, sd->msg, sd->msglen, &rctx.fork_addr, rctx.fork_flags, 
-                             &rctx.rctxfork_cipher_ctx) < 0) {
+                             &rctx.fork_cipher_ctx) < 0) {
                extract = false;
                bclose(&rctx.forkbfd);
                continue;

osx-w:~/bacula/regress netops$ ./tests/weird-files2-test 
 
 
 === Starting weird-files2-test at 13:58:52 ===
 
Starting the Bacula Storage daemon
Starting the Bacula File daemon
Starting the Bacula Director daemon
Connecting to Director localhost:8101
1000 OK: localhost-dir Version: 2.1.27 (13 July 2007)
Enter a period to cancel a command.
@tee /dev/null
messages
You have no messages.
@tee tmp/log1.out
label storage=File volume=TestVolume001
Automatically selected Catalog: MyCatalog
Using Catalog "MyCatalog"
Automatically selected Pool: Default
Connecting to Storage daemon File at localhost:8103 ...
Sending label command for Volume "TestVolume001" Slot 0 ...
3000 OK label. VolBytes=217 DVD=0 Volume="TestVolume001" Device="FileStorage" 
(/Users/netops/bacula/regress/tmp)
Catalog record for Volume "TestVolume001", Slot 0  successfully created.
Requesting to mount FileStorage ...
3906 File device "FileStorage" (/Users/netops/bacula/regress/tmp) is always 
mounted.
run job=weird-files2 yes
Job queued. JobId=1
You have messages.
wait
messages
13-Jul 13:58 localhost-dir: No prior Full backup Job record found.
13-Jul 13:58 localhost-dir: No prior or suitable Full backup found in catalog. 
Doing FULL backup.
13-Jul 13:58 localhost-dir: Start Backup JobId 1, 
Job=weird-files2.2007-07-13_13.58.57
13-Jul 13:58 localhost-dir: Using Device "FileStorage"
13-Jul 13:58 localhost-sd: Wrote label to prelabeled Volume "TestVolume001" on 
device "FileStorage" (/Users/netops/bacula/regress/tmp)
13-Jul 13:58 localhost-sd: Spooling data ...
13-Jul 13:58 localhost-sd: Job write elapsed time = 00:00:01, Transfer rate = 
8.986 K bytes/second
13-Jul 13:58 localhost-sd: Committing spooled data to Volume "TestVolume001". 
Despooling 10,636 bytes ...
13-Jul 13:58 localhost-sd: Despooling elapsed time = 00:00:01, Transfer rate = 
10.63 K bytes/second
13-Jul 13:58 localhost-sd: Sending spooled attrs to the Director. Despooling 
14,813 bytes ...
13-Jul 13:58 localhost-dir: Bacula localhost-dir 2.1.27 (13Jul07): 13-Jul-2007 
13:58:59
  Build OS:               powerpc-apple-darwin8.10.0 darwin 8.10.0
  JobId:                  1
  Job:                    weird-files2.2007-07-13_13.58.57
  Backup Level:           Full (upgraded from Incremental)
  Client:                 "localhost-fd" 2.1.27 (13Jul07) 
powerpc-apple-darwin8.10.0,darwin,8.10.0
  FileSet:                "Full Set" 2007-07-13 13:58:57
  Pool:                   "Default" (From Job resource)
  Storage:                "File" (From Job resource)
  Scheduled time:         13-Jul-2007 13:58:56
  Start time:             13-Jul-2007 13:58:59
  End time:               13-Jul-2007 13:58:59
  Elapsed time:           0 secs
  Priority:               10
  FD Files Written:       50
  SD Files Written:       50
  FD Bytes Written:       1,311 (1.311 KB)
  SD Bytes Written:       8,986 (8.986 KB)
  Rate:                   0.0 KB/s
  Software Compression:   None
  VSS:                    no
  Encryption:             no
  Volume name(s):         TestVolume001
  Volume Session Id:      1
  Volume Session Time:    1184349532
  Last Volume Bytes:      10,841 (10.84 KB)
  Non-fatal FD errors:    0
  SD Errors:              0
  FD termination status:  OK
  SD termination status:  OK
  Termination:            Backup OK

13-Jul 13:58 localhost-dir: Begin pruning Jobs.
13-Jul 13:58 localhost-dir: No Jobs found to prune.
13-Jul 13:58 localhost-dir: Begin pruning Files.
13-Jul 13:58 localhost-dir: No Files found to prune.
13-Jul 13:58 localhost-dir: End auto prune.

@tee
quit
Connecting to Director localhost:8101
1000 OK: localhost-dir Version: 2.1.27 (13 July 2007)
Enter a period to cancel a command.
@tee /dev/null
messages
You have no messages.
@# 
@# now do a restore
@#
@tee tmp/log2.out
restore where= storage=File
Automatically selected Catalog: MyCatalog
Using Catalog "MyCatalog"

First you select one or more JobIds that contain files
to be restored. You will be presented several methods
of specifying the JobIds. Then you will be allowed to
select which files from those JobIds are to be restored.

To select the JobIds, you have the following choices:
     1: List last 20 Jobs run
     2: List Jobs where a given File is saved
     3: Enter list of comma separated JobIds to select
     4: Enter SQL list command
     5: Select the most recent backup for a client
     6: Select backup for a client before a specified time
     7: Enter a list of files to restore
     8: Enter a list of files to restore before a specified time
     9: Find the JobIds of the most recent backup for a client
    10: Find the JobIds for a backup for a client before a specified time
    11: Enter a list of directories to restore for found JobIds
    12: Cancel
Select item:  (1-12): 5
Automatically selected Client: localhost-fd
Automatically selected FileSet: Full Set
+-------+-------+----------+----------+---------------------+---------------+
| JobId | Level | JobFiles | JobBytes | StartTime           | VolumeName    |
+-------+-------+----------+----------+---------------------+---------------+
| 1     | F     | 50       | 1311     | 2007-07-13 13:58:59 | TestVolume001 |
+-------+-------+----------+----------+---------------------+---------------+
You have selected the following JobId: 1

Building directory tree for JobId 1 ...  +++++++++++++++++++++++
1 Job, 46 files inserted into the tree.

You are now entering file selection mode where you add (mark) and
remove (unmark) files to be restored. No files are initially added, unless
you used the "all" keyword on the command line.
Enter "done" to leave this mode.

cwd is: /
$ unmark *
50 files unmarked.
$ mark *
50 files marked.
$ done
Bootstrap records written to 
/Users/netops/bacula/regress/working/localhost-dir.restore.1.bsr

The job will require the following
   Volume(s)                 Storage(s)                SD Device(s)
===========================================================================
   
   TestVolume001             File                      FileStorage              


50 files selected to be restored.

Run Restore job
JobName:         RestoreFiles
Bootstrap:       
/Users/netops/bacula/regress/working/localhost-dir.restore.1.bsr
Where:           
Replace:         always
FileSet:         Full Set
Backup Client:   localhost-fd
Restore Client:  localhost-fd
Storage:         File
When:            2007-07-13 13:59:01
Catalog:         MyCatalog
Priority:        10
OK to run? (yes/mod/no): yes
Job queued. JobId=2
wait
You have messages.
messages
13-Jul 13:59 localhost-dir: Start Restore Job RestoreFiles.2007-07-13_13.59.02
13-Jul 13:59 localhost-dir: Using Device "FileStorage"
13-Jul 13:59 localhost-sd: Ready to read from volume "TestVolume001" on device 
"FileStorage" (/Users/netops/bacula/regress/tmp).
13-Jul 13:59 localhost-sd: Forward spacing Volume "TestVolume001" to file:block 
0:217.
13-Jul 13:59 localhost-sd: End of file 0 on device "FileStorage" 
(/Users/netops/bacula/regress/tmp), Volume "TestVolume001"
13-Jul 13:59 localhost-sd: End of Volume at file 0 on device "FileStorage" 
(/Users/netops/bacula/regress/tmp), Volume "TestVolume001"
13-Jul 13:59 localhost-sd: End of all volumes.
13-Jul 13:59 localhost-dir: Bacula localhost-dir 2.1.27 (13Jul07): 13-Jul-2007 
13:59:03
  Build OS:               powerpc-apple-darwin8.10.0 darwin 8.10.0
  JobId:                  2
  Job:                    RestoreFiles.2007-07-13_13.59.02
  Restore Client:         localhost-fd
  Start time:             13-Jul-2007 13:59:03
  End time:               13-Jul-2007 13:59:03
  Files Expected:         50
  Files Restored:         50
  Bytes Restored:         1,311
  Rate:                   0.0 KB/s
  FD Errors:              0
  FD termination status:  OK
  SD termination status:  OK
  Termination:            Restore OK

13-Jul 13:59 localhost-dir: Begin pruning Jobs.
13-Jul 13:59 localhost-dir: No Jobs found to prune.
13-Jul 13:59 localhost-dir: Begin pruning Files.
13-Jul 13:59 localhost-dir: No Files found to prune.
13-Jul 13:59 localhost-dir: End auto prune.

@tee
quit
Pool   Maxsize  Maxused  Inuse
NoPool      256        3      0
NAME        130        0      0
FNAME       468        7      0
MSG       65636       10      0
EMSG       1024        1      0

51c51
< drwxr-xr-x 45 501  501    1530      2007-07-13 13:58:52 weird-files2
---
> drwxr-xr-x 44 501  501    1496      2007-07-13 13:58:52 weird-files2
 
 
  !!!!! weird-files2-test failed!!! !!!!! 
  !!!!! Restored files differ          !!!!! 
        bstat=0 rstat=0 dstat=1
 
osx-w:~/bacula/regress netops$ 

#!/bin/sh

/bin/cp -f scripts/tls-bacula-dir.conf bin/bacula-dir.conf
/bin/cp -f scripts/tls-bacula-sd.conf bin/bacula-sd.conf
/bin/cp -f scripts/tls-bacula-fd.conf bin/bacula-fd.conf
/bin/cp -f scripts/test-console.conf bin/bconsole.conf
/bin/cp -f scripts/tls-CA.pem bin/tls-CA.pem
/bin/cp -f scripts/tls-cert.pem bin/tls-cert.pem
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Bacula-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bacula-devel

Reply via email to