Class LinuxServerEnvironment
- All Implemented Interfaces:
BackupEnvironment
LinuxServerEnvironment controls the backup system on
an Server.
TODO: Save bandwidth by doing prelink -u --undo-output=(tmpfile) (do this to read the file instead of direct I/O). Can possibly use the distro data to know which ones are prelinked.
TODO: Use LVM snapshots when is a domU - also do MySQL lock to get steady-state snapshot
TODO: Should we use some tricky stuff to dump the databases straight out as we iterate? (Backups only) TODO: Or, just dump to disk and remove when completed? (Backups only)
TODO: Adhere to the d attribute? man chattr
- Author:
- AO Industries, Inc.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcleanup(FileReplication ffr) intprotected Map<String, FilesystemIteratorRule> protected Map<String, FilesystemIteratorRule> voidinit(FileReplication ffr) voidpreBackup(FileReplication ffr) Methods inherited from class com.aoindustries.aoserv.backup.PosixFileEnvironment
getDeviceIdentifier, getGid, getLength, getModifyTime, getPosixFile, getStat, getStatMode, getUid, readLinkMethods inherited from class com.aoindustries.aoserv.backup.FileEnvironment
getDirectoryList, getFile, getFilenameIterator, getInputStream, getNameOfFile, getRequiredFilenames, getServerPath, postBackup
-
Constructor Details
-
LinuxServerEnvironment
public LinuxServerEnvironment()
-
-
Method Details
-
getConnector
- Throws:
IOExceptionSQLException
-
getThisHost
- Throws:
IOExceptionSQLException
-
preBackup
- Specified by:
preBackupin interfaceBackupEnvironment- Overrides:
preBackupin classFileEnvironment- Throws:
IOExceptionSQLException
-
init
- Specified by:
initin interfaceBackupEnvironment- Overrides:
initin classFileEnvironment- Throws:
IOExceptionSQLException
-
cleanup
- Specified by:
cleanupin interfaceBackupEnvironment- Overrides:
cleanupin classPosixFileEnvironment- Throws:
IOExceptionSQLException
-
getFailoverBatchSize
- Specified by:
getFailoverBatchSizein interfaceBackupEnvironment- Overrides:
getFailoverBatchSizein classFileEnvironment- Throws:
IOExceptionSQLException
-
getFilesystemIteratorRules
protected Map<String,FilesystemIteratorRule> getFilesystemIteratorRules(FileReplication ffr) throws IOException, SQLException - Specified by:
getFilesystemIteratorRulesin classFileEnvironment- Throws:
IOExceptionSQLException
-
getFilesystemIteratorPrefixRules
protected Map<String,FilesystemIteratorRule> getFilesystemIteratorPrefixRules(FileReplication ffr) throws IOException, SQLException - Specified by:
getFilesystemIteratorPrefixRulesin classFileEnvironment- Throws:
IOExceptionSQLException
-
getDefaultSourceIpAddress
- Specified by:
getDefaultSourceIpAddressin interfaceBackupEnvironment- Overrides:
getDefaultSourceIpAddressin classFileEnvironment- Throws:
IOExceptionSQLException
-
getReplicatedMysqlServers
public List<Server.Name> getReplicatedMysqlServers(FileReplication ffr) throws IOException, SQLException - Specified by:
getReplicatedMysqlServersin interfaceBackupEnvironment- Overrides:
getReplicatedMysqlServersin classFileEnvironment- Throws:
IOExceptionSQLException
-
getReplicatedMysqlMinorVersions
public List<String> getReplicatedMysqlMinorVersions(FileReplication ffr) throws IOException, SQLException - Specified by:
getReplicatedMysqlMinorVersionsin interfaceBackupEnvironment- Overrides:
getReplicatedMysqlMinorVersionsin classFileEnvironment- Throws:
IOExceptionSQLException
-
getFastRandom
Uses the fast random source from
AoservDaemon.getFastRandom().- Specified by:
getFastRandomin interfaceBackupEnvironment- Overrides:
getFastRandomin classFileEnvironment
-
getLogger
-
