summaryrefslogtreecommitdiff
path: root/lib/backupclient
Commit message (Collapse)AuthorAge
* Allow configuration of the server port that the client will connect to Chris Wilson2008-03-28
| | | | | | | | | | | | | (bbackupd and bbackupquery). Redesign ConfigurationVerify to use classes instead of structs. Use port 22011 instead of 2201 during tests, to reduce the chances of conflicting with a running bbstored or other process. Ignore autogen_* in svn:ignore everywhere instead of individual per-file ignores.
* Improve logging with macros that consistently output strerror(errno) andChris Wilson2008-03-28
| | | | | | | | | | | | | | | errno, replacing almost all use of strerror() in the main code. Log a more detailed error message before throwing an exception for some more system call failures. Make FileStream store its filename on all platforms, not just Windows. Wrap some long lines at less than 80 characters to improve readability. Fix some minor violations of coding standard (white space) and a typo in a comment.
* Use new logging framework for tracing diffs.Chris Wilson2007-12-06
| | | | | Log each block found and each false match at DEBUG level.
* Really fix unlink() during restore, fixes [1919].Chris Wilson2007-11-04
|
* unlink returns 0 on success, not on error.Chris Wilson2007-11-04
|
* Ignore time differences less than 1 second when comparing attributes,Chris Wilson2007-11-04
| | | | | as not all filesystems can store times that accurately (e.g. OSX).
* Allow configuration of the time to delete redundant store locations.Chris Wilson2007-10-08
|
* Convert most printf() and fprintf() calls to use logging frameworkChris Wilson2007-08-02
| | | | | instead. (refs #3)
* Replace almost all calls to syslog() with logging framework. (refs #3)Chris Wilson2007-07-31
|
* Fix restoring to top-level directories (e.g. c:\test) (refs #3,Chris Wilson2007-07-26
| | | | | merges [1661])
* Experimental fix for restore problem reported by Mikael Syska:Chris Wilson2007-07-26
| | | | | | | | | | | | query > restore Admin "c:\admin\" Failed to read file information: The parameter is incorrect. (87) Failed to get file information for 'c:' Failed to check existence for c:: Common OSFileError (Error accessing a file. Check permissions.) ERROR: Unknown restore result. (refs #3, merges [1659])
* Remove assertion that we are at the end of the stream when decodingChris Wilson2007-04-29
| | | | | finishes. This is not true when decoding raw files on disk. (refs #3)
* Remove unwanted blank line. (refs #3)Chris Wilson2007-04-29
|
* Make directories user-writable while restoring them, so that restoringChris Wilson2007-04-29
| | | | | | read-only directories as a non-root user doesn't crash. Restore the correct permissions after restoring the directory's contents. (refs #3)
* Make directories user-writable while restoring them, so that restoringChris Wilson2007-04-29
| | | | | | read-only directories as a non-root user doesn't crash. Restore the correct permissions after restoring the directory's contents. (refs #3)
* Fix bbackupd choosing an invalid (too large) block size for large filesChris Wilson2007-04-28
| | | | | | | (over 2GB) which will cause compare to fail: when rBlockSizeOut == BACKUP_FILE_MAX_BLOCK_SIZE we would have proceeded around the loop one more time and doubled the block size again. (refs #2, refs #3)
* Fix getting files with uncertain size (over 2GB) from the store. FailureChris Wilson2007-04-28
| | | | | | to drain the stream will leave the EOF byte in it, which breaks further communications with the store over the same connection. (refs #2, refs #3)
* Use ReadLoggingStream to log progress of file uploads. (refs #3)Chris Wilson2007-04-28
|
* Use logging framework to reduce noise for those who don't want itChris Wilson2007-03-24
| | | | | (refs #3, merges [1439] [1440] [1443])
* Fix compile warningChris Wilson2007-02-09
|
* Log failure to delete files and directories (refs #3)Chris Wilson2007-02-09
|
* Catch exceptions while writing files, attributes, resume info and checkingChris Wilson2007-02-09
| | | | | file existence (refs #3)
* Don't throw an exception if we fail to delete a file in the way of restore,Chris Wilson2007-02-09
| | | | | just log the error and return an error code (refs #3)
* Spelling fix (refs #3)Chris Wilson2007-02-09
|
* Make BackupClientRestoreDir return a result code compatible withChris Wilson2007-02-09
| | | | | BackupClientRestore (refs #3)
* Check whether the restore target parent directory exists before tryingChris Wilson2007-02-09
| | | | | to create the target directory or save restore info in the parent (refs #3)
* Catch errors during restore (refs #3)Chris Wilson2007-02-09
|
* Fix spelling (refs #3)Chris Wilson2007-01-13
|
* Added a new config option, LogAllFileAccess, which will log access to every Chris Wilson2007-01-11
| | | | | | file and scanning every directory. The current implementation is taken straight from the Boxi branch. To be extended shortly. (refs #3)
* Moved KeepAlive timer to BackupClientContext object.Chris Wilson2006-12-03
| | | | | | | | Made timeout initialisation non-static, and a property of the context object. (perhaps should be in rParams, I know). (refs #3, refs #9)
* Replace old-style setitimers for KeepAliveTime and MaximumDiffingTime Chris Wilson2006-11-28
| | | | | with new Timer objects. (refs #3, refs #9)
* Add ExtendedLogFile option to bbackupd config (refs #9)Chris Wilson2006-11-14
|
* Add new return codes from BackupClientRestore for use on Win32. (refs #3)Chris Wilson2006-10-16
|
* Delete existing entries to allow reuse of a BackupStoreDirectory object.Chris Wilson2006-10-16
| | | | | (refs #3)
* Remove #ifdefs around geteuid(), re-enable use of fake version under Win32Chris Wilson2006-10-16
| | | | | | | | as requested by Ben. Restore serialised AttrModificationTime under Win32 by passing to emu_utimes(). (refs #3)
* * lib/backupclient/BackupStoreObjectDump.cppChris Wilson2006-08-31
| | | | | Fix format strings on Win32 (refs #3)
* * lib/backupclient/BackupStoreObjectDump.cppChris Wilson2006-08-31
| | | | | - Revert to trunk
* * lib/backupclient/BackupStoreFile.cppChris Wilson2006-08-31
| | | | | | Close file before trying to apply attributes to it. Otherwise, when we close it the timestamp will be updated on Win32 (refs #3)
* * lib/backupclient/BackupStoreFile.cppChris Wilson2006-08-31
| | | | | - Revert to trunk
* * lib/backupclient/BackupClientFileAttributes.cppChris Wilson2006-08-31
| | | | | | Don't call geteuid() on Win32, since it's emulated, always returns 0, and I want to remove it entirely (refs #3)
* * lib/backupclient/BackupClientFileAttributes.cppChris Wilson2006-08-31
| | | | | - Revert to trunk
* * mergeChris Wilson2006-07-27
| | | | | | | - This is my current patch queue. I think that all of these are safe to apply. This is just under half of the pending changes in chris/general (the easy half).
* This is part 1 of a patch from James O'Gorman.Martin Ebourne2006-03-04
| | | | | configure now detects perl executable location and updates all scripts to use the correct path; also adds PERL_EXECUTABLE define to BoxConfig.h. makebuildenv.pl adds PERL define to all makefiles.
* On XFS the file permissions appear to apply also to the extended attribute ↵Martin Ebourne2006-02-17
| | | | | | | data. ie. If a file is not readable then nor is the extended attribute data - even if there isn't any this is still an error. This is not an ideal fix for this problem. Really we should notify a read-error as we do for file read permission problems and continue, but the BackupClientFileAttributes code is called from multiple locations and it is not clear that it could always report the error in such a way, nor even continue. This alternative is better than aborting the whole run. In the case where a file isn't readable this will be found and reported elsewhere anyway.
* Merge chris/win32/vc2005-compile-fixes @ r455, add infrastructure/msvc to ↵Ben Summers2006-02-13
| | | | distribution
* Get rid of the non-test compiler warnings seen on Darwin with gcc4Ben Summers2006-02-01
|
* Merge chris/bb-save-state, resolving conflictsBen Summers2006-01-30
|
* * infrastructure/makeparcels.plChris Wilson2006-01-28
| | | | | | | | | | | | | | | | | | | | | | | - Use the target platform's name, rather than the build platform, in the generated package file names (useful for cross-compiling) * lib/win32/emu.cpp - Don't log a warning when statting a file that doesn't exist, as bbackupquery does this to verify that the target does not exist before restoring * lib/backupclient/BackupClientFileAttributes.cpp - Fixed a missing endian conversion that was causing file timestamps to appear to be invalid, generating warnings about every file on the server, on Win32 * parcels.txt - Include a couple of DLL files in the package on MinGW, which are needed to run the compiled binaries * bin/bbackupquery/BackupQueries.cpp - Fixed usage text for the "get" command
* * configure.acChris Wilson2006-01-28
| | | | | | | | | | | | | | | | | | | * bin/bbstored/backupprotocol.txt * bin/bbstored/BackupCommands.cpp * bin/bbackupd/BackupClientContext.cpp * bin/bbackupd/BackupClientContext.h * bin/bbackupd/BackupClientDirectoryRecord.cpp * bin/bbackupd/BackupDaemon.cpp * lib/backupclient/BackupStoreFileDiff.cpp * lib/backupclient/BackupDaemonConfigVerify.cpp * lib/backupclient/BackupStoreFile.h * test/backupstore/testbackupstore.cpp * test/backupstorepatch/testbackupstorepatch.cpp - Applied changes from chris/diff-timeout-and-ssl-keepalive * test/backupdiff/testbackupdiff.cpp - Fixed test to match new prototype for EncodeFileDiff
* Fixes for xattr on LinuxMartin Ebourne2006-01-06
| | | | | | | | | | | | | | | | - A very unlikely failure where getxattr returns an error code the first time but succeeds the second time could cause buffer overrun and corruption. Affecting the tests only: - On Linux (and presumably Irix) normal users can only modify attributes in the 'user.' namespace. - Some filesystems can have strict limits on value size (eg. 1024 bytes on ext3 depending on block size) - ENOATTR is defined in xattr/xattr.h. This file is an optional install and is not needed for the rest of box to use extended attributes. Provide it ourselves if not present.