1 |
diff -ruN e-smith-backup-2.4.0.old/root/etc/e-smith/events/actions/workstation-backup-dar e-smith-backup-2.4.0/root/etc/e-smith/events/actions/workstation-backup-dar |
2 |
--- e-smith-backup-2.4.0.old/root/etc/e-smith/events/actions/workstation-backup-dar 2013-11-30 21:03:09.000000000 -0800 |
3 |
+++ e-smith-backup-2.4.0/root/etc/e-smith/events/actions/workstation-backup-dar 2013-11-30 22:21:33.000000000 -0800 |
4 |
@@ -94,8 +94,6 @@ |
5 |
$report .= "DAILY BACKUP TO WORKSTATION REPORT \n"; |
6 |
$report .= "================================== \n"; |
7 |
$report .= "Backup of ".$id." started at " .$tim . "\n"; |
8 |
-$report .= "Backup of mysql databases has been done\n"; |
9 |
-$report .= "Mounting backup shared directory <//$smbhost/$smbshare>\n"; |
10 |
|
11 |
# ping the SMB Host to see if it is awake |
12 |
|
13 |
@@ -139,16 +137,6 @@ |
14 |
$setnum %= $setsmax; |
15 |
} |
16 |
|
17 |
-$report .= sprintf("Using set number %d of %d\n", $setnum + 1, $setsmax); |
18 |
-if ($incnum == 0) |
19 |
-{ |
20 |
- $report .= "Attempt full backup \n"; |
21 |
-} |
22 |
-else |
23 |
-{ |
24 |
- $report .= sprintf("Attempt incremental backup number %d of %d\n", $incnum, $daysinset - 1); |
25 |
-} |
26 |
- |
27 |
# if no set directory, make it |
28 |
my $setname = "set" . $setnum; |
29 |
my $setdirname = $mntdir . "/$id/" . $setname; |
30 |
@@ -160,12 +148,10 @@ |
31 |
|
32 |
&removeTree ("$tmpdir/$id"); |
33 |
&createTree ("$tmpdir/$id"); |
34 |
- $report .= "Backup temp directory $tmpdir/$id is mounted and is writable \n"; |
35 |
-} |
36 |
-else |
37 |
-{ |
38 |
- $report .= "Backup directory $setdirname is mounted \n"; |
39 |
+ $report .= "Working directory //$smbhost/$smbshare/tmp_dir/$id\n"; |
40 |
} |
41 |
+$report .= "Destination //$smbhost/$smbshare/$id/$setname\n"; |
42 |
+ |
43 |
|
44 |
if ( $incnum == 0 ) |
45 |
{ |
46 |
@@ -208,7 +194,7 @@ |
47 |
ldie("Not a permitted day for full backup. Aborting...\nNext full backup in $delay days.\n"); |
48 |
} |
49 |
|
50 |
-$report .= "Backup to $bkname in $id/$setname\n"; |
51 |
+$report .= "Basename $bkname\n"; |
52 |
|
53 |
# calculate real timeout if we timeout incrementals only. |
54 |
# timeout of 88500 is a security for aborting backup within 24h |
55 |
@@ -217,7 +203,7 @@ |
56 |
{ |
57 |
$timeout = 88500; |
58 |
} |
59 |
-$report .= "Starting the backup with a timeout of $timeout seconds\n"; |
60 |
+$report .= "Starting the backup with a timeout of ". int ($timeout/(60*60)). " hours\n"; |
61 |
|
62 |
# expanding backup configuration file template |
63 |
|
64 |
@@ -244,7 +230,6 @@ |
65 |
|
66 |
if ($deleteearly ne 'true') # Not DeleteEarly so move backup to $setdirname |
67 |
{ |
68 |
- $report .= "Moving backup files to target directory $setdirname \n"; |
69 |
if ($incnum == 0) |
70 |
{ |
71 |
&removeTree ($setdirname); |
72 |
@@ -259,8 +244,6 @@ |
73 |
} |
74 |
|
75 |
# update dar_manager catalog |
76 |
-$report .= "Updating catalog\n"; |
77 |
- |
78 |
my %backupfiles = (); |
79 |
my $mntbkdir; |
80 |
my $mounted; |
81 |
@@ -358,24 +341,22 @@ |
82 |
my $df = qx(/bin/df -Ph \"$mntdir\"); |
83 |
if ($df =~ /(\S+)\s+(\S+)\s+(\S+)\s+(\d*%)/) |
84 |
{ |
85 |
- $report .= "Disk usage $2, $4 full, $3 available\n"; |
86 |
+ $report .= "Destination disk usage $2, $4 full, $3 available\n"; |
87 |
} |
88 |
else |
89 |
{ |
90 |
- $report .= "Disk space not available\n"; |
91 |
+ $report .= "Destination disk space not available\n"; |
92 |
} |
93 |
|
94 |
# unmount shared folder |
95 |
system("/bin/umount", "-f", "$mntdir"); |
96 |
|
97 |
# time now to update backup configuration |
98 |
- |
99 |
-$report .= "Updating backup configuration data \n"; |
100 |
$backupwk->set_prop('SetNum', $setnum); |
101 |
$backupwk->set_prop('IncNum', $incnum); |
102 |
|
103 |
$tim = ctime(); |
104 |
-$report .= "Backup successfully terminated at : $tim \n"; |
105 |
+$report .= "Backup successfully terminated at $tim \n"; |
106 |
|
107 |
if ($mail eq 'yes') |
108 |
{ |