Backup Costs with/without Compression

mholzbauer's picture

Here is a short calculation of Informix Backup costs with and without compression.
Informix backup can be compressed in different ways:
- ontape to disk (with ONCONFIG Parameters BACKUP_FILTER and RESTORE_FILTER)
- onbar to tape (with ONCONFIG Parameters BACKUP_FILTER and RESTORE_FILTER)
- onbar to tape (with TSM compression)

The compression size depends on the compression tool/algorithm and the data
(CHARs versus VARCHARS, BYTE, TEXT, BLOBs and so on).
Compression time (Backup Time) depends only on the compression tool/algorithm,
the number of CPUs the tool can use and the CPU frequency.

For the example calculation we assume, that the resulting (compressed) backup size
is between 25% and 45% and the monthly storage costs for the backup is about
0.15 USD per GByte per month (or 1.80 USD per GByte per year).
We also assume, that we need one full backup per instance per day (to shorten the
recovery time) and about 10 GByte logfiles to backup.
 
You can test your backup time and compression size with following commands:

$ time (ontape -s -L 0 -F -t STDIO | wc -c)        
 1443889152
(; ontape -s -L 0 -F -t STDIO | wc -c; )
14.25s user 1.43s system 79% cpu 19.604 total
$ time (ontape -s -L 0 -F -t STDIO | gzip -1c | wc -c)
 266601916
(; ontape -s -L 0 -F -t STDIO | gzip -1c | wc -c; )
48.81s user 1.83s system 109% cpu 46.056 total
$ echo "scale=2; 266601916/(1443889152/100)" | bc
18.46

In this example the resulting backup size is 18.45% with compression, but backup time doubles.
So, lets try another compression tool (with parallel compression):

$ time (ontape -s -L 0 -F -t STDIO | pigz -1c -b 1024 | wc -c)
 266990723
(; ontape -s -L 0 -F -t STDIO | pigz -1c -b 1024 | wc -c; )
66.02s user 7.07s system 281% cpu 25.931 total

Backup size is about the same as above, but compression time is reduced.
This is what we want (and need).

 
Example A):
1 Instance (90 GByte Data per full Backup + 10 GB Logical Logfiles per day) 
Backup Volume:  
DAYS BACKUP 
STORED
SIZE
UNCOMPRESSED 
SIZE 45%
COMPRESSED   
SIZE 25%
COMPRESSED
1 Day100 GB45 GB25 GB
30 Days3 TB1.35 TB0.75 TB
90 Days9 TB4.05 TB2.25 TB
 
Yearly backup costs: 
DAYS BACKUP 
STORED
COST
UNCOMPRESSED 
COST 45%
COMPRESSED        
COST 25%
COMPRESSED
1 Day180 USD81 (  -99) USD45 (  -135) USD
30 Days5400 USD2430 (-2970) USD1350 ( -4050) USD
90 Days16200 USD7290 (-8910) USD4050 (-12150) USD
 
 
Example B):
100 Instances (90 GByte Data per full Backup + 10 GB Logical Logfiles per Day)
or
10 Instances (990 GB Data per full Backup + 10 GB Logical Logfiles per Day)
Backup Volume:  
DAYS BACKUP 
STORED
SIZE
UNCOMPRESSED 
SIZE 45%
COMPRESSED  
SIZE 25%
COMPRESSED
1 Day10 TB4.5 TB2.5 TB
30 Days300 TB135 TB75 TB
90 Days900 TB405 TB225 TB
 
Yearly backup costs:
DAYS BACKUP 
STORED
COST
UNCOMPRESSED  
COST 45%
COMPRESSED             
COST 25%
COMPRESSED
1 Day18000 USD8100 (  -9900) USD4500 (  -13500) USD
30 Days540000 USD243000 (-297000) USD135000 ( -405000) USD
90 Days1620000 USD729000 (-891000) USD405000 (-1215000) USD
 
 
 
Have fun !