Backup Consistency

Whichever command we choose to perform our backups, it is important to remember that the backup will not be consistent if the files being backed up are being worked on while the backup is taking place. Therefore, we need some way of ensuring that the system is in a state that allows us to back it up consistently. The files could be changed if people are using the system while the backup is taking place, but if an application, such as a database, is running it too may be changing files as the backup is running.

The safest way of ensuring that a filesystem is not changing would be to unmount it. But it is not always practical to manage to include this in an automated backup procedure, and we can't just go unmounting the root filesystem whenever we want to. The next best thing is to ensure that all applications are shut down and all users are logged off before the backup starts. We can also prevent users from logging on while the backup is taking place by creating a file called /etc/nologin just before the backup starts.

Any text we put in this file will be displayed on the terminal of any user attempting to login, prior to the user being logged out again. Once the backup has been completed the applications can be started up again and the nologin file removed.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset