/[smecontribs]/rpms/smeserver-affa/contribs8/smeserver-affa.spec
ViewVC logotype

Annotation of /rpms/smeserver-affa/contribs8/smeserver-affa.spec

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.2 - (hide annotations) (download)
Sun Jun 2 03:40:13 2013 UTC (11 years, 5 months ago) by unnilennium
Branch: MAIN
CVS Tags: smeserver-affa-2_0_0-rc4_el5_sme
Changes since 1.1: +153 -54 lines
* Sun Jan 25 2009 Michael Weinberger 2.0.0-rc4
  Bugfix: --send-status was broken
  Added disk usages to Success Message

1 unnilennium 1.2 Summary: Makes the SME server a dedicated backup server
2 unnilennium 1.1 %define name smeserver-affa
3     Name: %{name}
4 unnilennium 1.2 %define version 2.0.0
5     %define release rc4
6 unnilennium 1.1 Version: %{version}
7     Release: %{release}%{?dist}
8 unnilennium 1.2 Vendor: Michael Weinberger <Michael.Weinberger@neddix.de>
9     License: GNU General Public License
10 unnilennium 1.1 Group: Applications/Archiving
11     Source: %{name}-%{version}.tar.gz
12     BuildRoot: /var/tmp/%{name}-%{version}-%{release}-buildroot
13     BuildArch: noarch
14     AutoReq: no
15 unnilennium 1.2 Requires: smeserver-release >= 7.3
16     Requires: rsync >= 3.0.4
17 unnilennium 1.1 Requires: perl-Filesys-DiskFree
18 unnilennium 1.2 Requires: perl-Compress-Bzip2
19 unnilennium 1.1 BuildRequires: e-smith-devtools
20    
21     %description
22 unnilennium 1.2 http://wiki.contribs.org/Affa
23     http://wiki.contribs.org/Backup_of_ESXi_Virtual_Machines_using_Affa
24    
25     %prep
26     %setup -q -n %{name}-%{version}
27    
28     %build
29    
30     %install
31     rm -rf $RPM_BUILD_ROOT
32     rm -f %{name}-%{version}-filelist
33     (cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT)
34    
35     perl createlinks $RPM_BUILD_ROOT
36    
37     # Set version String
38     cp -a $RPM_BUILD_ROOT/sbin/e-smith/affa $RPM_BUILD_ROOT/sbin/e-smith/affa.tmp
39     VERSIONSTRING=%{version}-`echo %{release}|sed -e 's/\..*$//'`
40     sed -e "s/my \$VERSION.*;/my \$VERSION='$VERSIONSTRING';/" < $RPM_BUILD_ROOT/sbin/e-smith/affa.tmp > $RPM_BUILD_ROOT/sbin/e-smith/affa
41     rm -f $RPM_BUILD_ROOT/sbin/e-smith/affa.tmp
42    
43     rm -f %{name}-%{version}-filelist
44    
45     find $RPM_BUILD_ROOT -depth -type f -print |\
46     sed -e "s@^$RPM_BUILD_ROOT@@g" \
47     -e "s@^/sbin/e-smith/@%attr(0750,root,root) &@"\
48     -e "s@^/usr/lib/perl5/@%attr(0644,root,root) &@"\
49     -e "s@^/etc/profile.d/@%attr(0555,root,root) &@"\
50     -e "s@^/etc/e-smith/templates/@%attr(0644,root,root) &@"\
51     -e "s@^/usr/lib/affa/COPYING@%attr(0444,root,root) &@"\
52     -e "s@^/usr/lib/affa/@%attr(0750,root,root) &@"\
53     >> %{name}-%{version}-filelist
54    
55     find $RPM_BUILD_ROOT -depth -type l -print |\
56     sed "s@^$RPM_BUILD_ROOT@@g" >> %{name}-%{version}-filelist
57    
58     %clean
59     rm -rf $RPM_BUILD_ROOT
60     exit 0
61    
62    
63     %files -f %{name}-%{version}-filelist
64     %defattr(-,root,root)
65 unnilennium 1.1
66     %changelog
67 unnilennium 1.2 * Sun Jan 25 2009 Michael Weinberger 2.0.0-rc4
68     Bugfix: --send-status was broken
69     Added disk usages to Success Message
70    
71     * Fri Jan 23 2009 Michael Weinberger 2.0.0-rc3
72     Bugfix: --mailtest: mail from remote watchdog was not sent
73    
74     * Sun Jan 10 2009 Michael Weinberger 2.0.0-rc2
75     - Workaround to catch Dropbear rsync errors (ESXi Mode)
76    
77     * Sun Jan 04 2009 Michael Weinberger 2.0.0-rc1
78     - no changes
79    
80     * Fri Jan 02 2009 Michael Weinberger 2.0.0-beta21
81     - show last execution time in --show-schedule
82    
83     * Thu Jan 01 2009 Michael Weinberger 2.0.0-beta20
84     - Fixed calculation of compression rate in chunkfile()
85     - Changed format of --list-archives output: added Exec Time and Bytes received
86     - Changed format of --status: added Exec Time, removed Disk usage
87     - Output formatted table in --disk-usage
88     - added --debug CLI switch
89    
90    
91     * Tue Dec 30 2008 Michael Weinberger 2.0.0-beta19
92     - Retry feature added, new props RetryAfter,RetryAttempts and RetryNotification
93     - Dependency rsync >= 3.0.4 added to spec file
94     - Append job status on testmail (because spam filter on receiver site)
95     - log total execution time
96    
97     * Fri Dec 26 2008 Michael Weinberger 2.0.0-beta18
98     - bugfix check-connections: in ssh check in rsyncd mode
99     - Bug 4888 fixed: escape single quotes in source dir names
100     - Bug 4882 fixed: LVM mapped devices
101    
102     * Fri Dec 19 2008 Michael Weinberger 2.0.0-beta17
103     - dont chunk ESXi vmdk files in linkdest archive that will be deleted afterwards
104     - show disk usage at time at job run in --status
105     - new option --disk-usage shows current disk usage of all Root Dirs
106     - Bug 4852 fixed
107     - Modifications to allow backup of specific files (Bug 4853)
108    
109     * Thu Dec 11 2008 Michael Weinberger 2.0.0-beta16
110     - shorten command line of rsync command when syncing ESXi VM. Dropbear has limits
111    
112     * Wed Dec 10 2008 Michael Weinberger 2.0.0-beta15
113     - chunk feature now working for all job types
114     - new property chunkFiles
115     - new options --chunk-archive and --unchunk-archive
116    
117     * Mon Dec 08 2008 Michael Weinberger 2.0.0-beta14
118     - --delete-job: Delete logfile
119     - samba template for Affa archives
120     - Bugfix: snapshot was removed to early. Wrong vmx file copied
121     - disabled chunk feature for now. Needs more testing
122    
123     * Sun Dec 07 2008 Michael Weinberger 2.0.0-beta12
124     - using perl Compress::Bzip2
125    
126     * Sat Dec 06 2008 Michael Weinberger 2.0.0-beta11
127     - replaced gzip by bzip2 as gzip inserts timestamps
128    
129     * Wed Dec 04 2008 Michael Weinberger 2.0.0-beta10
130     - bugfixes
131    
132     * Wed Dec 04 2008 Michael Weinberger 2.0.0-beta09
133     - chunk and compress vmdk files
134    
135     * Thu Nov 27 2008 Michael Weinberger 2.0.0-beta08
136     - allow special characters in VM name and pathes
137    
138     * Tue Nov 11 2008 Michael Weinberger 2.0.0-beta07
139     - New Dropbear Version 0.51 did not work stable. Stay with original 0.49 and th exit status bug
140     - Modified Affa to not to check exit status of ssh and rsync command
141    
142     * Sat Nov 08 2008 Michael Weinberger 2.0.0-beta06
143     - FIXED: rsync did not work for VM with blanks in name
144     - SSH exit codes now checked as Dropbear 0.51 is used on ESX3i host
145    
146     * Tue Nov 04 2008 Michael Weinberger 2.0.0-beta05
147     - log msg and exit if VI Pert Tool Kit installed
148     - Fixed: in job sample scripts create affa db if not exists
149    
150     * Tue Nov 04 2008 Michael Weinberger 2.0.0-beta04
151     - Allow setups with dailyKeep=0, weeklyKeep=0, monthlyKeep=0 or yearlyKeep=0
152     - Fixed: Yearly archives not listed in --status and --list-archives
153    
154     * Mon Nov 03 2008 Michael Weinberger 2.0.0-beta03
155     - cleaner logging of VI API errors
156     - backing up ESXi server config and root home dir
157     - Checking VI API connect in --check-connections
158    
159     * Sun Nov 02 2008 Michael Weinberger 2.0.0-beta02
160     - Fixed: Log file excerpt was not appened to Email.
161     - Fixed: checkConnection() did not work for ESXi
162     - Fixed: ssh find command did not use the HostKeyAlias option
163     - Catch die from VI Toolkit
164     - Close VI API session while rsyncing
165    
166     * Fri Oct 31 2008 Michael Weinberger 2.0.0-beta01
167     - ESXi support added
168    
169 unnilennium 1.1 * Tue May 27 2008 Michael Weinberger 1.0.0-3
170     Re-added type 'desktop' to pre-backup event for SME6 compatibility
171     * Tue Apr 22 2008 Michael Weinberger 1.0.0-2
172     Bug fix #4210, command "affa --show-schedule" executes postJobCommand
173     * Fri Apr 04 2008 Michael Weinberger 1.0.0-1
174     Final release
175     man page updated
176     * Fri Apr 04 2008 Michael Weinberger 0.10.0-2
177     added --all option to --rise
178     * Mon Mar 10 2008 Michael Weinberger 0.10.0-1
179     Increased release number
180     Added 10 sec timeout in Net::DNS::Resolver->search
181     * Mon Mar 10 2008 Michael Weinberger 0.9.0-11
182     Specfile fix
183     * Mon Mar 10 2008 Michael Weinberger 0.9.0-10
184     Delete locally created watchdog file after remotecopy
185     Bugfix 4035
186     Added default AutoUnmount property to sample script
187     Fix man page
188     Do not delete md5sum in --create-backup-file when verify is skipped by user
189     Set lock in --create-backup-file
190     * Sun Mar 09 2008 Michael Weinberger 0.9.0-9
191     trap signals in --create-backup-file
192     * Sat Mar 08 2008 Michael Weinberger 0.9.0-8
193     Permissions in /usr/lib/affa
194     * Sat Mar 08 2008 Michael Weinberger 0.9.0-7
195     md5sum in --create-backup-file
196     * Fri Mar 07 2008 Michael Weinberger 0.9.0-6
197     Added option --create-backup-file
198     Using line number as error code in affaErrorExit()
199     Fixed /etc/profile.d/affa.sh
200    
201     * Mon Mar 03 2008 Michael Weinberger 0.9.0-5
202     - delete new style Dovecot's index files dovecot.index*
203     - delete dovecot index files on remote server in --full-restore
204    
205     * Fri Feb 29 2008 Michael Weinberger 0.9.0-4
206     set localhost as default remoteHostName in /etc/e-smith/templates//etc/cron.d/affa/00jobs
207    
208     * Wed Feb 27 2008 Michael Weinberger 0.9.0-3
209     removed %post from spec file
210    
211     * Sat Feb 02 2008 Michael Weinberger 0.9.0-2
212     Bugfix: Report db was not deleted in deleteJob()
213     don't use -q on ssh commands with Debug=yes
214    
215     * Fri Feb 1 2008 Shad L. Lords <slords@mail.com> 0.9.0-1
216     - Fix specfile for building in new buildsystem
217    
218     * Fri Jan 18 2008 Michael Weinberger
219     Version 0.9.0
220     Bugfix: run cronSetup() after job delete
221     Throw error if nothing was backed up (empty archive)
222     Added rsyncd support for backing up Windows/Cygwin
223     Added option and property remoteOS. Which remoteOS=cgywin the
224     send key and revoke key functions use the right path to the
225     authorized_keys2 file and login as user Administrator
226    
227     * Sat Dec 29 2007 Michael Weinberger
228     Version 0.8.1
229     Automount Bugfix [Bug 3165]: Only exit with error on mount failure
230     when in backup run. Otherwise log the error and continue.
231    
232     * Thu Dec 20 2007 Michael Weinberger
233     Version 0.8.0
234     added bash completion script
235     added option --kill JOB
236     improved INT and TERM signal handling
237     replaced all scp commands by rsync
238     added poperty BandwidthLimit (unit KBytes/sec)
239     each job write its own known hosts entry using ssh option HostKeyAliasOption
240     affa --send-key w/o arguments sends the keys for all jobs
241     removed Property StrictHostKeyChecking
242     UPDATE FROM VERSIONS<8: run the command 'affa --send-key' to generate
243     the known hosts entries for all jobs
244    
245     * Wed Dec 12 2007 Michael Weinberger
246     Version 0.7.0
247     Modified logging: Job run logs to /var/log/affa/JOBNAME.log, all other
248     to /var/log/affa/affa.log
249     Bugfix: Check error status of --send-key and --revoke-key
250     New: Options --show-schedule
251     Modified: Option --list-archives now accepts multiple args or none
252     Fix: install watchdog on source server before every run not only scheduled,
253     to avoid watchdog triggered if a non-scheduled run take to long time.
254    
255     * Wed Nov 28 2007 Michael Weinberger
256     Version 0.6.8
257     Bugfix: Automount was done too late. Daily backup never ran.
258    
259     * Wed Nov 21 2007 Michael Weinberger
260     Version 0.6.7
261     Bugfix: Size and No. of files were not shown in --status
262     Improved deleting of directories
263     added --check-connections option
264     Increased width of job column in --stats table
265    
266     * Sun Nov 11 2007 Michael Weinberger
267     Version 0.6.6
268     Property rsync--modify-window added
269     Modified recursive deleting directories
270    
271     * Wed Nov 07 2007 Michael Weinberger
272     Version 0.6.5
273     ssh options added to scp commands
274     added post-backup event
275    
276     * Wed Aug 08 2007 Michael Weinberger
277     Version 0.6.4
278     delete dovcot index files after a --rise
279    
280     * Thu Jul 05 2007 Michael Weinberger
281     Version 0.6.3
282     Bugfix: with RPMCheck=yes the affa-rpmlist was not found in the
283     archive. Wrong path to schedule.0 instead of scheduled.running.
284     Side effect of changes in version 0.5.0. [Bug 3128]
285    
286     * Tue Jul 03 2007 Michael Weinberger
287     Version 0.6.2
288     Bugfix: Filesys::DiskFree requires $ENV{LANG}="en_US" [Bug 3119]
289     Bug reported to bug-Filesys-DiskFree [at] rt.cpan.org
290    
291     * Mon Jun 25 2007 Michael Weinberger
292     Version 0.6.1
293     Fix 3080 was not applied.
294    
295     * Mon Jun 18 2007 Michael Weinberger
296     Version 0.6.0
297     - Replaced Filesys::DiskSpace by Filesys::DiskFree as the latter
298     supports CIFS file system
299     - using Filesys::DiskFree->mount and ->device instead of scanning /proc/mounts
300     - mkdir RootDir only on job run to avoid making it in an unmounted mountpoint
301    
302     * Mon Jun 18 2007 Michael Weinberger
303     Version 0.5.2
304     - Sending ssh key failed. When grep returned an error
305     the mv command was not executed. Using ';' instead of '&&'
306     for chaining commands. [Bug 3080]
307     - /root/.ssh/authorized_keys2: No such file or directory warning.
308     Run a touch to guarantee, that the file exists. [Bug 3080]
309     - same issue with --revoke-key
310    
311     * Thu Jun 14 2007 Michael Weinberger
312     Version 0.5.1
313     - Bugfix automount: getStatus() unmounts the device while a job is running
314     - Status table: Last=never, if there are no archives at all
315    
316     * Tue Jun 12 2007 Michael Weinberger
317     Version 0.5.0
318     - New property AutomountOptions
319     - status table: grouped disabled jobs. Show Last='-' for disabled jobs
320     instead of 'failed'
321     - unlink lockfile in getLock()
322     - Changes to improve robustness in case of network outage:
323     - writing to a temporary archive scheduled.running and linkdest
324     against the latest existing archive (usually scheduled.0). Then
325     shift archives and rename scheduled.running to scheduled.0
326     - scheduledKeep=1 is now allowed
327     - also check connection in daily,weekly etc., not only in scheduled run
328     - don't run daily, weekly, monthly or yearly, when scheduled.0 doesn't exist.
329     - new option --revoke-key
330     - added optional option --revoke-key to --delete-job
331     - avoid multiple adding public key to authorized_keys2 on source server
332    
333     * Wed Jun 06 2007 Michael Weinberger
334     Version 0.4.7
335     - use StrictHostKeyChecking=no in sendKeys()
336    
337     * Tue Jun 05 2007 Michael Weinberger
338     Version 0.4.6
339     - mailtest: Send also a testmail from the remotehost, when property Watchdog=yes
340     - removed useless code in mailTestWatchdogRemote()
341    
342     * Mon Jun 04 2007 Michael Weinberger
343     Version 0.4.5
344     write job config file to the archive dir
345    
346     * Thu May 31 2007 Michael Weinberger
347     Version 0.4.4
348     - added property StrictHostKeyChecking (ssh option)
349     - string comparison instead of numric for $job{'doneYearly'} ne $thisYear etc.
350    
351     * Wed May 30 2007 Michael Weinberger
352     Version 0.4.3
353     - Minor bugfixes:
354     calculation of RootDirFilesystemUsage in .AFFA-REPORT
355     improved error handling with rsync status and df in DiskspaceWarn()
356    
357     * Thu May 29 2007 Michael Weinberger
358     - Version 0.4.2
359     Infinite loop in execPostJobCommand() if command could not be executed:
360     Don't call execPostJobCommand() in affaErrorExit() if err==115
361     - RPMCheck property was ignored
362     - added Property chattyOnSuccess
363     - modified jobconfig-sample.pl to preserve 'doneDaily','doneWeekly',
364     'doneMonthly','doneYearly' and 'chattyOnSuccess'
365     - write error codes of affaErrorExit() to log
366    
367     * Thu May 24 2007 Michael Weinberger
368     - Version 0.4.1
369     - fixed bug in disk usage calculation
370    
371     * Tue May 22 2007 Michael Weinberger
372     - Version 0.4.0
373     - added option --rename-job
374     - changed syntax of --send-keys
375     - added option --move-archive
376    
377     * Sun May 20 2007 Michael Weinberger
378     - Version 0.3.3
379     - rebuild cronjobs after rise/undorise
380     - ignore job of own backup, when creating cronjobs (job appears after a rise run)
381    
382     * Sun May 20 2007 Michael Weinberger
383     - Version 0.3.2
384     - man: added sshPort propperty
385     - chdir /tmp to avoid cwd warnings when the cwd disappears while
386     running rise or undo rise
387     - bugfix: undorise() did not found own backup archive. Was searching for a wrong name
388    
389     * Wed May 16 2007 Michael Weinberger
390     - Version 0.3.1 minor bugfixes
391     - checkCrossFS() did not work (used in --rise)
392     - jobconfig-sample.pl: deleting record before setting props
393     - Perl errors with --status before a job run
394    
395     * Thu May 10 2007 Michael Weinberger
396     - Version 0.3.0
397     - man page completed
398     - mark archives with indices > keep setting with '*' in --list-acrchive output
399     - Option --delete-job
400     - Option --cleanup
401     - added --job=JOB alternative to --send-keys
402    
403     * Wed May 09 2007 Michael Weinberger
404     - Version 0.2.0
405     - added --mailtest option
406    
407     * Tue May 08 2007 Michael Weinberger
408     - Version 0.1.5
409     - improved --status output
410     - removed options --report and --send-report
411     - added option --show-archives
412     - added --csv for status and show-archives output in CSV format
413     - added property 'sshPort'
414    
415     * Mon May 07 2007 Michael Weinberger
416     - Version 0.1.4
417     - don't install the remote watchdog, when remotehost is eq localhost
418     - improved check for remoteHostName eq localhost using DNS
419     - ssh -o PasswordAuthentication=no in checkConnection()
420     - added --full-restore
421     - missing check for HOSTNAME argument in --send-keys added
422     improved error check
423     - prevent run of --rise of localhost from own backup
424    
425     * Mon Apr 30 2007 Michael Weinberger
426     - Version 0.1.3
427     modified 'use constant* syntax in watchdog script for compatibility
428     with perl 5.6 on SME6
429    
430     * Fri Apr 27 2007 Michael Weinberger
431     - Version 0.1.2
432     Bugfix: Preserve of ethernet driver setting with --rise did not work.
433     Also preserve NIC bonding.
434    
435     * Mon Apr 23 2007 Michael Weinberger
436     - Version 0.1.1
437     scheduledKeep must be>=2 for --link-dest
438     set scheduledKeep to 2 if <2
439     - get lastrun date from affa-report rather than from report file
440     - added auto mount function
441     - added AutomountDevice and AutomountPoint to jobconfig-sample.pl
442    
443     * Wed Apr 18 2007 Michael Weinberger
444     - Version 0.0.8
445     dont die if report db does not exist
446    
447     * Wed Apr 18 2007 Michael Weinberger
448     - Version 0.0.7
449     run checkConnection() only for scheduled backups
450     added Size and Disk usage information to --status
451    
452     * Tue Apr 17 2007 Michael Weinberger
453     - Version 0.0.7
454     print Servername in --status output
455    
456     * Thu Apr 12 2007 Michael Weinberger
457     - Version 0.0.5
458     fixed calculation of lastrun-now
459    
460     * Thu Apr 12 2007 Michael Weinberger
461     - Version 0.0.4
462     - added --send-status plus templates
463     - fixed format error of times in affa --status
464     - show 'failed', if lastrun is older 1 day in affa --status
465     - fixed typo. default status=disabled (was disable)
466    
467     * Fri Apr 06 2007 Michael Weinberger
468     - Version 0.0.3
469     - watchdog reminder was not deleted on soure
470     - wrong version mismatch list in rpm compare
471    
472     * Thu Apr 05 2007 Michael Weinberger
473     - added 'rsync--inplace' property
474    
475     * Mon Apr 02 2007 Michael Weinberger
476     - initial release
477    

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed