Hello,

I'm at loss to create a working consolidate job. I read the documentation and 
many forum posts here, but somehow it doesn't seem to work. The consolidate job 
runs successful but does nothing (the consolidate pool on the disk is not 
touched, although the messages say it's consolidating).

To speed up testing, the configuration is adapted. For testing, I backup  
/var/log/ on the bareos-director itself, so every time a AI job is started, 
there are new files. I always start the job itself in bareos-webui under 
"actions".

What happens:
1) first always incremental job successfully is upgraded to full. Writes to 
pool disk_ai_consolidate: OK
2) subsequent always incremental jobs write to disk_ai pool: OK
3) running ai_consolidate finishes successfully, but does nothing: NOT OK

my config (adapted for testing, the client pavlov should consolidate ):

### JOBDEF always incremental ###
JobDefs {
  Name = "default_ai"
  Type = Backup
  Level = Incremental
  Client = pavlov-fd
  Storage = pavlov-file
  Messages = Standard
  Priority = 10
  Write Bootstrap = "|/usr/local/bin/bareos-messages.sh \"[Bootstrap] %d: %j 
(jobid %i)\" %i \"it@XXXXXXX\" %c-%n" 

  #always incremental config
  Pool = disk_ai
  Incremental Backup Pool = disk_ai
  Full Backup Pool = disk_ai_consolidate
  Accurate = yes
  Always Incremental = yes
  Always Incremental Job Retention = 20 seconds #7 days
  Always Incremental Keep Number = 2 #7
  Always Incremental Max Full Age = 5 minutes # 14 days
}

### JOB always incremental for one client ###
Job {
  Name = "pavlov_sys_ai"
  JobDefs = "default_ai"
  Client = "pavlov-fd"
  FileSet = linux_system
  Schedule = manual
}

### JOB consolidate ###
Job {
  Name = ai_consolidate
  Type = Consolidate
  Accurate = yes
  Max Full Consolidations = 1
  Client = pavlov-fd                    #value which should be ignored by 
Consolidate job       
  FileSet = "none"                      #value which should be ignored by 
Consolidate job
  Pool = disk_ai_consolidate            #value which should be ignored by 
Consolidate job
  Incremental Backup Pool = disk_ai_consolidate # I had this also disabled, 
doesn't matter
  Full Backup Pool = disk_ai_consolidate # I had this also disabled, doesn't 
matter
#  JobDefs = DefaultJob
#  Level = Incremental
  Schedule = "ai_consolidate"
  Storage = pavlov-file
  Messages = Standard
  Priority = 10
  Write Bootstrap = "|/usr/local/bin/bareos-messages.sh \"[Bootstrap] %d: %j 
(jobid %i)\" %i \"[email protected]\" %c-%n" 
}

### POOL always_incremental ###
Pool {
  Name = disk_ai
  Pool Type = Backup
  Recycle = yes                       # Bareos can automatically recycle Volumes
  AutoPrune = yes                     # Prune expired volumes
  Volume Retention = 4 weeks
  Maximum Volume Bytes = 30G          # Limit Volume size to something 
reasonable
  Maximum Volumes = 200               # Limit number of Volumes in Pool
  Label Format = "ai_inc-"              # Volumes will be labeled 
"Full-<volume-id>"
  Volume Use Duration = 23h
  Storage = pavlov-file
  Next Pool = disk_ai_consolidate
}


### POOL consolidate ###
Pool {
  Name = disk_ai_consolidate
  Pool Type = Backup
  Recycle = yes                       # Bareos can automatically recycle Volumes
  AutoPrune = yes                     # Prune expired volumes
  Volume Retention = 4 weeks
  Maximum Volume Bytes = 30G          # Limit Volume size to something 
reasonable
  Maximum Volumes = 200               # Limit number of Volumes in Pool
  Label Format = "ai_consolidate-"              # Volumes will be labeled 
"Full-<volume-id>"
  Volume Use Duration = 23h
  Storage = pavlov-file
  Next Pool = tape_automated #not working neither ....
}


### messages when running always incremental job ###

Connecting to Director localhost:9101
1000 OK: pavlov-dir Version: 16.2.4 (01 July 2016)
Enter a period to cancel a command.
list joblog jobid=172
Automatically selected Catalog: MyCatalog
Using Catalog "MyCatalog"
 2017-10-26 10:24:48 pavlov-dir JobId 172: Start Backup JobId 172, 
Job=pavlov_sys_ai.2017-10-26_10.24.46_17
 2017-10-26 10:24:48 pavlov-dir JobId 172: Using Device "FileStorage" to write.
 2017-10-26 10:24:49 pavlov-dir JobId 172: Sending Accurate information.
 2017-10-26 10:24:49 pavlov-sd JobId 172: Volume "ai_inc-0016" previously 
written, moving to end of data.
 2017-10-26 10:24:49 pavlov-sd JobId 172: Ready to append to end of Volume 
"ai_inc-0016" size=1334618
 2017-10-26 10:24:50 pavlov-sd JobId 172: Elapsed time=00:00:01, Transfer 
rate=85.62 K Bytes/second
 2017-10-26 10:24:51 pavlov-dir JobId 172: Bareos pavlov-dir 16.2.4 (01Jul16):
  Build OS:               x86_64-pc-linux-gnu ubuntu Ubuntu 16.04 LTS
  JobId:                  172
  Job:                    pavlov_sys_ai.2017-10-26_10.24.46_17
  Backup Level:           Incremental, since=2017-10-26 10:24:42
  Client:                 "pavlov-fd" 16.2.4 (01Jul16) 
x86_64-pc-linux-gnu,ubuntu,Ubuntu 16.04 LTS,xUbuntu_16.04,x86_64
  FileSet:                "linux_system" 2017-10-19 16:11:21
  Pool:                   "disk_ai" (From Job IncPool override)
  Catalog:                "MyCatalog" (From Client resource)
  Storage:                "pavlov-file" (From Pool resource)
  Scheduled time:         26-Oct-2017 10:24:46
  Start time:             26-Oct-2017 10:24:49
  End time:               26-Oct-2017 10:24:50
  Elapsed time:           1 sec
  Priority:               10
  FD Files Written:       5
  SD Files Written:       5
  FD Bytes Written:       82,176 (82.17 KB)
  SD Bytes Written:       85,623 (85.62 KB)
  Rate:                   82.2 KB/s
  Software Compression:   92.2 % (lz4hc)
  VSS:                    no
  Encryption:             yes
  Accurate:               yes
  Volume name(s):         ai_inc-0016
  Volume Session Id:      2
  Volume Session Time:    1509005906
  Last Volume Bytes:      1,421,219 (1.421 MB)
  Non-fatal FD errors:    0
  SD Errors:              0
  FD termination status:  OK
  SD termination status:  OK
  Termination:            Backup OK

### messages when running consolidate job (pavlov should be consolidated) ###

Connecting to Director localhost:9101
1000 OK: pavlov-dir Version: 16.2.4 (01 July 2016)
Enter a period to cancel a command.
list joblog jobid=169
Automatically selected Catalog: MyCatalog
Using Catalog "MyCatalog"
 2017-10-26 10:18:40 pavlov-dir JobId 169: Start Consolidate JobId 169, 
Job=ai_consolidate.2017-10-26_10.18.38_04
 2017-10-26 10:18:40 pavlov-dir JobId 169: Looking at always incremental job 
pavlov_sys_ai
 2017-10-26 10:18:40 pavlov-dir JobId 169: pavlov_sys_ai: considering jobs 
older than 26-Oct-2017 10:18:20 for consolidation.
 2017-10-26 10:18:40 pavlov-dir JobId 169: before ConsolidateFull: jobids: 
132,133,135,137,138,139,140,141,142,145,156
 2017-10-26 10:18:40 pavlov-dir JobId 169: check full age: full is 25-Oct-2017 
16:24:08, allowed is 26-Oct-2017 10:13:40
 2017-10-26 10:18:40 pavlov-dir JobId 169: Full is older than 
AlwaysIncrementalMaxFullAge -> also consolidating Full jobid 132
 2017-10-26 10:18:40 pavlov-dir JobId 169: after ConsolidateFull: jobids: 
132,133,135,137,138,139,140,141,142,145,156
 2017-10-26 10:18:40 pavlov-dir JobId 169: pavlov_sys_ai: Start new 
consolidation
 2017-10-26 10:18:40 pavlov-dir JobId 169: Using Catalog "MyCatalog"
 2017-10-26 10:18:40 pavlov-dir JobId 169: Job queued. JobId=170
 2017-10-26 10:18:40 pavlov-dir JobId 169: Consolidating JobId 170 started.
 2017-10-26 10:18:40 pavlov-dir JobId 169: Looking at always incremental job 
edite_sys_ai
 2017-10-26 10:18:40 pavlov-dir JobId 169: edite_sys_ai: considering jobs older 
than 26-Oct-2017 10:18:20 for consolidation.
 2017-10-26 10:18:40 pavlov-dir JobId 169: edite_sys_ai: less than two jobs to 
consolidate found, doing nothing.
 2017-10-26 10:18:40 pavlov-dir JobId 169: BAREOS 16.2.4 (01Jul16): 26-Oct-2017 
10:18:40
  JobId:                  169
  Job:                    ai_consolidate.2017-10-26_10.18.38_04
  Scheduled time:         26-Oct-2017 10:18:38
  Start time:             26-Oct-2017 10:18:40
  End time:               26-Oct-2017 10:18:40
  Termination:            Consolidate OK

however, looking at the files on disk, the pool disk_ai_consolidate is 
untouched concerning date and size (disk_ai is untouched also after running the 
consolidate job)

kind regards,

-- 
You received this message because you are subscribed to the Google Groups 
"bareos-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to