Tanti Technology

My photo
Bangalore, karnataka, India
Multi-platform UNIX systems consultant and administrator in mutualized and virtualized environments I have 4.5+ years experience in AIX system Administration field. This site will be helpful for system administrator in their day to day activities.Your comments on posts are welcome.This blog is all about IBM AIX Unix flavour. This blog will be used by System admins who will be using AIX in their work life. It can also be used for those newbies who want to get certifications in AIX Administration. This blog will be updated frequently to help the system admins and other new learners. DISCLAIMER: Please note that blog owner takes no responsibility of any kind for any type of data loss or damage by trying any of the command/method mentioned in this blog. You may use the commands/method/scripts on your own responsibility. If you find something useful, a comment would be appreciated to let other viewers also know that the solution/method work(ed) for you.

Friday, 22 November 2013

AIX Backup concepts

System Backup
Back up the file systems,
Directories, andFiles
  • Backup concepts
Before you start backing up your data, you need to understand the types of data, policies, and media that
you can use.
Need of backup:In big environment data is very very important.So to recover from data loss ,it is must to choose a good backup strategy.
Backup policies:
No single backup policy can meet the needs of all users. A policy that works well for a system with one
user, for example, could be inadequate for a system that serves one hundred users. Likewise, a policy
developed for a system on which many files are changed daily would be inefficient for a system on
which data changes infrequently.
Whatever the appropriate backup strategy for your site, it is very important that one exist and that
backups be done frequently and regularly. It is difficult to recover from data loss if a good backup
strategy has not been implemented.
Only you can determine the best backup policy for your system, but the following general guidelines
might be helpful:
If you back up your file systems, you can restore files or file systems in the event of a hard disk crash. There are different methods for backing up information.
Backing up file systems, directories, and files represents a significant investment of time and effort. At the
same time, all computer files are potentially easy to change or erase, either intentionally or by accident.a backup by name, file name archive, or regular backup. This is a copy of a file system, directory, or file that is
kept for file transfer or in case the original data is unintentionally changed or destroyed. This method of
backup is done when the flag is specified and is used to make a backup copy of individual files and
directories. It is a method commonly used by individual users to back up their accounts.
Another frequently used method is called backup by i-nodefile system archive, or archive backup.
Backup command: creates the image/ copy of the files to be backedup on the archival medium.
# backup [–i] or [-p] or [-v] or [-q] or [-u] flags can be used to take backup.
-u flag creates an entry in /etc/dumpdates that is having all the backup history information.
To backup current directory, command used is:
# backup -0 –f -f
For eg:
# backup -0 –f /home/user01/vg00_backup –i /home/usr01/vglv
Flag 0 means weekly backup
1 means daily
To restore this backup command used is:
# restore –qf
Or
# restore –xvf
Generally, /dev/rmt0 is the default destination medium where data is backed up.

Savevg command: this command finds and backup all the files that belongs to a particular Volume group (VG).basically savevg command is used to backup a non-rootvg data.
Command used to create backup is:
# savevg – restore –xvf ief /dev/rmt0
Where vgname is the name of the volume group to be backed up.
Similarly, to backup a non root vg, command use is:
# savevg –f -i
For eg:
#savevg –f /home/user01/vg00_backup –i vg00
After running this command, admin can remove vg00 from the system. Command to restore vg00 back from vg00_backup is:
# restvg –qf
For eg:
# restvg –qf /home/user01/vg00_backup hdisk10
So restvg command is basically used to restore non root vg data.
MKSYSB Command: The mksysb command creates a bootable image of all mounted file systems on the rootvg volume group.You can use this backup command to restore a system to its original state.The tape format includes a BOS boot image, a BOS install image, and a dummy table of contents (TOC) followed by the System Backup (root volume group)
image. The root volume group image is in backup-file format, starting with the data files and then any optional map files.
User-defined paging spaces, unmounted file systems, and raw devices are not backed up
# mksysb –ief /dev/rmt0
if you want to take mksysb in a directory named abc then
#mksysb -ivX /lpar1/abc -this command will take a System Backup of system lapr1 in abc directory.
1.smit fast path for mksysb is.#smit mksysb


fig- Backup Up the System configuration window

  1. The COMMAND STATUS screen is now displayed. Figure 10-3 is a screen capture of what information is being displayed during the backup process




Fig- Command status output from a running back up
3. The system has now created a bootable System Backup, as shown in












Command status output from a successful backup

No comments:

Post a Comment