Incremental Backup question

Hi,
I have a hot backup taken every wednesday and archive log backups taken every day. (using RMAN and netbackup). Oracle is 10.2.0.3 and OS is RHEL4.
Do I still need or (will it be helpful to have ) incremental backups? What is its purpose? Will the recovery be faster if I have incremental backups? Please comment.
Thank you,

i guess this is a good best practice found in Expert Oracle Database by Sam Alapati
"If you expect few changes in data, you are better off using incremental backups, since they
won’t consume a lot of space. Incremental backups, as part of your backup strategy, will reduce the
time required to apply redo during recovery. However, if most of your database blocks change frequently,
your incremental backups will be quite large. In such a case, you are better off making a
complete image copy of the database at regular intervals."
Edited by: doro on Aug 19, 2011 1:57 PM

Similar Messages

  • BRU incremental Backup Questions/Help

    Hello Ladies and Gents,
    I'm in desperate need of some help. I purchased Bru Le 1.3.0 about 2 weeks ago and going to use it for the clients Backup Strategy for over 2TB of data.
    I used retrospect in the past but retro has been giving them major issues and has been unreliable; therefore the reason to switch to Bru.
    Configuration: Xserve/XRAID backing up to Two sets of Lacie Drives 2x 1.8TB striped together = one single 3.6TB drive. One 3.6TB is daily and the Second is a weekly Off-site.
    Let me preface this with the understanding that I'm not super savvy with Command-line....
    The Goal is to Create incremental daily backup!
    I started by creating a Full Backup compression level 1, now I'm trying to change that to an Incremental Backup - But when I try to select the base (which I thought would be the Full Backup I created) - I get an Error "Incorrect Base Definition" -- Which means I did this Wrong.
    How do I Correctly create a proper Base Definition for an Incremental Backup?
    Thanks
    david
    XServe - XRAID   Mac OS X (10.4.10)   Bru LE - 1.3.0
    G5   Mac OS X (10.4.10)  

    Have you run a backup of the datafiles already?
    Looking the documentation it says the following:
    When using these commands, there must already exist an image copy of every datafile specified in the command. If there are multiple copies of a datafile, the latest one is used. RMAN issues an error if image copies of every datafile in the database or tablespace do not exist.From what you're saying this looks like the case with your backups.
    I suggest running a backup of the current datafiles, then running a backup copy and querying RMAN to check the copy exists.
    RMAN> List backup;Documenation Link: http://download.oracle.com/docs/cd/B13789_01/server.101/b10734/rcmconc1.htm
    Edited by: Kerri_Robberts on Aug 12, 2011 3:58 PM

  • Incremental Hot backup question

    This question originated from a different post of mine, but is somewhat different so I'm starting it up as a separate topic.
    Each night we do an incremental hot backup around 4am. Yesterday I dropped a tablespace successfully and removed the original datafile along with it. Autobackup backed up the control file before and after the drop. Then when the incremental backups ran last night at 4am everything went just fine.
    So up to this point we're all good.
    However, in the flash recovery area where it writes the backups (backupsets, datafiles, etc) it still has a file for that tablespace... except that it did not appear to be updated like all the reset were. This is fine, but that file is taking up space on the box and the unix backup script that copies everything to a separate box still picks it up (that script copies everything.. and the author of the code doesn't want to hard code any names)
    Can I just remove this file without causing the backup to be upset? Or do I need to do something else to accomplish this goal? And if so, what (still a newbie so be specific)?
    Thanks in advance.

    The first thing you need to do is to provide a complementary crystal ball in order to be able to guess nasty little details, like the contents of that script.
    Even 'incremental hot backup' is an ambiguous term. One would expect a RMAN backup, but as you didn't use various RMAN commands to establish all of your files have been backed up, and you talk about 'backupsets' and seem to discuss a standalone datafile: The only thing I see is lots of fog, and the need to tear the information out of you.
    No business for volunteers.
    Sybrand Bakker
    Senior Oracle DBA
    Experts: those who did read documentation.

  • Question about using an incremental backup to update a standby

    We have a 2TB Oracle 10g database with a standby and the application that uses it is about to be updated.  We're using cumulative incremental backups with block change tracking to back it up with weekly level 0 backups.  The application upgrade will be making a lot of changes (several hundred GB) and we have stop the standby during the upgrade process as a quick way to get back (we don't have the space for a flashback recovery) in the event that there are issues with the upgrade.  We can just let the archivelogs back up and get them over to the standby and applied once they decide they like the upgrade but, it looks like it would be simpler and perhaps quicker to use an incremental backup to update the standby.  I probably won't but, If we do that, it looks like we can turn off archivelogs in the primary and not deal with them at all.  I've never tried this but, I do have some questions.
    Does it make sense to take this approach?
    If we were to turn off archivelogs in the primary, would that have any effect on block change tracking?  I don't see why it would but, had to ask.  Of course, we would turn archivelogs back on and take a level 1 backup after the upgrade.
    Thanks in advance for the education.

    Funny you should mention that rolling upgrade,  I'm actually planning to do that in another environment.  My testing says it works pretty well and I'll be able to move a 400GB database to new hardware and upgrade it to 11g with very little downtime.  However, in this case, the database is not being upgraded.  The application is.  It's just that, as part of that upgrade, there are a lot of updates and I'd just as soon not deal with the archivelogs for that. Here's what I was thinking about:
    Set logs shipping to defer in the primary.
    Stop log apply in the standby.
    Turn off archivelogs in the primary.
    Do the application update.
    If they like the results, turn archivelogs back on in the primary.
    Take an rman incremental backup from scn in the primary.
    Apply the incremental backup to the standby.
    Start log log apply in the standby.
    Start log shipping in the primary.
    The process for getting and using the incremental is described here:
    http://docs.oracle.com/cd/B19306_01/backup.102/b14191/rcmdupdb.htm#BGBCEBJG
    This isn't your regular incremental backup.
    So, am I the only crazy one?  Has anyone else tried this?

  • Question on Differential Incremental Backup script.

    Version:11g
    OS : AIX 5.3
    I only have theoretical knowledge of RMAN. I am planning to implement Differential Incremental Backup for my database. My strategy is
    a. Weekly level 0 backup at Sunday morning 2:00 am
    b. Daily Level 1 Differential Incremental Backups at 2:00 am from Monday to Saturday.
    c. Backup all archived log filesFirst script to perform level 0 backup -- This script will be run by a cron job every Sunday morning 2:00 am
    ==================================================================
    run {
    allocate channel ch1 device type disk;
    backup incremental level 0 format '/u07/rman_backup/FULL_%d_%u' database tag "weekly_full";
    backup format '/u07/rman_backup/RMAN_CTL%s:%t:%p.bkp' current controlfile;
    release channel ch1;
    allocate channel ch1 device type disk;
    backup (archivelog all  format='/u08/rman_backup/archbkp_dir/ARCH_%d_%T_%u_s%s_p%p' DELETE INPUT TAG "archivelogs");
    release channel ch1;
    }The below script is to perform level 1 Differential Incremental Backups for the next 6 days. This script will be run daily
    at 2:00 am monday to saturday by a cronjob. I'll create 6 scripts like below, the only difference being the TAG "Monday-level1","Tuesday-level1"...etc.
    =======================================================
    run {
    allocate channel ch1 device type disk;
    backup incremental level 1 format '/u07/rman_backup/RMAN_DBF_%s:%t:%p.bkp' database tag "Monday-level1";
    backup format '/u07/rman_backup/RMAN_CTL<%s:%t:%p>.bkp' current controlfile;
    release channel ch1;
    allocate channel ch1 device type disk;
    backup (archivelog all  format='/u08/rman_backup/archbkp_dir/ARCH_%d_%T_%u_s%s_p%p' delete input tag "archivelogs");
    release channel ch1;
    }Question 1.
    Is my level 1 script correct ?
    Question2.
    Will the above scripts for level 0 and level 1 automatically delete the
    obsolete level 0 and level 1 backup files when a new weekly cycle starts?
    Any more enhancements(or corrections) you gurus want to suggest?

    Above scripts seems to be correct.
    Why you don't test it on test environment?
    These codes don't delete obsolete backups of the database. Then just delete backed up archived redo log files due to DELETE INPUT command
    If you use retention policy to recovery window of 7 days, to delete obsolete backups you need to run CROSSCHECK command and then DELETE OBSOLETE to delete all obsolete backups
    My suggestions
    - Practice it on test environment
    - Read documentation before performing any tests
    - Try to understand each line of these scripts based on documentation

  • ACS 5.3 Database backup questions

                 I do an incermental backup every day at 02:00
    IncrementalBackup-Job
    Mon Sep 17 02:00:00 EST 2012
    Mon Sep 17 02:00:02 EST 2012
    Completed
    But  I get the  
    System Alarm [Database Purging]
    Mon Sep 17 04:00:00
    Incremental Backup not configured
    why?
    see contents of repository below so it is there
    CHIACS71/chacs01# sh repository DataBase
    acsviewdbfull_CHIACS71_20120912_095516.tar.gpg
    acsviewdbfull_CHIACS71_20120913_020000.tar.gpg
    acsviewdbincr_1_CHIACS71_20120914_020000.tar.gpg
    acsviewdbincr_2_CHIACS71_20120915_020000.tar.gpg
    acsviewdbincr_3_CHIACS71_20120916_020000.tar.gpg
    acsviewdbincr_4_CHIACS71_20120917_020000.tar.gpg
    catalog.xml
    repolock.cfg
    CHIACS71/chacs01#
    second question can I use my secondary ACS for the DataBase repository?

    Hi,
    You should use an nfs server, sftp or ftp repository for backups only, something that is dedicated for storage. I would not recommending using anything that is used for production which needs internal storage to take on the task of managing another applications data.
    As far as the the first question, i am not talking about the purging, i am talking about the scheduled application backups:
    http://www.cisco.com/en/US/docs/net_mgmt/cisco_secure_access_control_system/5.3/user/guide/admin_operations.html#wp1076238
    Tarik Admani
    *Please rate helpful posts*

  • Time Machine won't do incremental backups after I restored my computer

    I am using a macbook (2010 version) and operating Lion.  I had a problem with my Macbook where it wouldn't log on, even in safe mode, so I restored it using Timemachine.  Now that everything is back up and running well I want to keep backing up.  But Time Machine now says that there is not eneough space on the backup disk as it wants to back up the whole computer alongside the exisitng back up.  In short it will no longer do incremental backups on top of what has already been backed up.  I don't want to wipe my backup disk for fear that something might go wrong again and I may want to go back to a version earlier than the one I restored.  Is there anyway of getting round this problem?  It seems like a fairly serious problem.
    I would appreciate any help.

    ms364 wrote:
    I am using a macbook (2010 version) and operating Lion.  I had a problem with my Macbook where it wouldn't log on, even in safe mode, so I restored it using Timemachine.
    When you erased the disk, it got a new UUID (Universally Unique IDentifier), which is treated like a different drive, and Time Machine will back it up in it's entirety.
    Did you do a full system restore, starting from the Recovery HD?  If so, that should have left a "trail" so Time Machine should have automatically "associated" the restored disk with the existing backups.
    If you did it "piecemeal," though, via the "Star Wars" display, it won't (that doesn't leave the trail for TM to figure out what happened).
    You might be able to get it to do the association manually.  See #B6 in Time Machine - Troubleshooting.
    But Linc is right;  you apparently need a larger TM drive.  See #1 in Time Machine - Frequently Asked Questions.

  • Is incremental backup possible for archivelog.

    Hi expert
    i want to plan weekly and daily backup with windows redundancy 14 days.
    full archivelog backup script
    run
    BACKUP AS COMPRESSED BACKUPSET
    INCREMENTAL LEVEL = 0
    DEVICE TYPE DISK
    TAG = 'WEEKLY_ARCHIVELOG'
    FORMAT '/oracle/ITB/db/apps_st/rman_backup/weekly_archivelog_%d_t%t_s%s_p%p'
    ARCHIVELOG FROM TIME 'SYSDATE-7';
    daily backup script
    run
    BACKUP AS COMPRESSED BACKUPSET
    INCREMENTAL LEVEL = 1
    DEVICE TYPE DISK
    TAG = 'DAILY_INCREMENTAL_ARCHIVELOG'
    FORMAT '/oracle/ITB/db/apps_st/rman_backup/daily_incremental_archivelog_%d_t%t_s%s_p%p'
    ARCHIVELOG FROM TIME 'SYSDATE-1';
    my question that if i will take backup then, will be any gap in sequnce
    and second question is that ---is there incremental backup possible for archivelog.
    os =aix6 and database 10g2

    afzal wrote:
    Dear Sir,
    ok question number 2 is clear that incremental backup is not possible but still confuse
    about sequence
    if i did take backup of 17 feb at 12 o'clock seq 1,2,3,4
    after that i did take backup 18th fab 1 pm then it will take from 6,7,8-------seq 5 is missing
    please please correct my archive log script for weekly and daily backup with windows redundancy 14 days
    again please correct my script
    thnaksWHy you think the archive log file number 5 will be missing? RMAN automatically archives current redo log files and backups it
    Why you don't test your backup script by your own and check results? Never trust anyone on your critical databases' backups, do it by your own!
    Kamran Agayev A.
    Oracle ACE
    My Oracle Video Tutorials - http://kamranagayev.wordpress.com/oracle-video-tutorials/

  • Restore Tablespace incremental backup is not work as after reimage oracle

    TheTablespace incremental backup Restore is not work as after reimage the oracle database or restore tablespace in standby machine(another machine) is not working .its working in the same machine without reimage .after reimage not working please clarify me ,
    I need the solution as soon as please reply as soon as .
    Commnads used:
    This is the step is followed but i am getting backup or control file not found error.Its works i the application server is not reimaged ;
    please give your valuable suggestion .
    Product Used:oracle 11g in linux environmnet
    1)Before taking backup get SCN number for restore.
    Command applied: Select current_scn from v$database;
    2)running Full backup of database
    Command applied:
    configure controlfile autobackup on;
    backup database plus archivelog;
    CROSSCHECK BACKUP;
    exit;
    3)Running level 0 incremental backup
    Before taking backup get SCN number for restore.
    Command applied:
    BACKUP AS COMPRESSED BACKUPSET INCREMENTAL LEVEL 0 TAG ='WEEKLY' TABLESPACE TEST;
    exit;
    3) Running level 1 incremental backup
    Before taking backup get SCN number for restore.
    Command applied:
    BACKUP AS COMPRESSED BACKUPSET INCREMENTAL LEVEL 1 TAG ='DAILY' TABLESPACE TEST;
    4)Before Restore(TSPITR) following procedure are applied under sysdba privilege
    Command applied:
    SQL 'exec dbms_backup_restore.manageauxinstance ('TSPITR',1)';
    5)TSPITR Restore command
    Command applied:
    run
    RECOVER TABLESPACE TEST UNTIL SCN 1791053 AUXILIARY DESTINATION '/opt/oracle/base/flash_recovery_area';
    SQL 'ALTER TABLESPACE TEST ONLINE';
    please calrfiy my following question:
    1. After reimage(reinstall oracle database with application ).The aboove scenario is not working
    2. After fullbackup what are the files needs to copy from (opt/oraclle/base/flash_recovery_area/dbname/) to repository because daily cleanup script will keep the data as sysdate -1 .
    For fullbacckup we are currently copying entire (flash_recovery_area/dbname) database folder to repoistory.
    3. after incremental backup what are the files needs to copy from (opt/oraclle/base/flash_recovery_area/dbname/..) to repository because daily cleanup script will keep the data as sysdate -1
    For incremenatl backup currently we are copying (flash_recovery_area/dbname/backupset/<currentdate> and flash_recovery_area/dbname/autobackup/<currentdate>) folder to repoistory.
    4.During restore we are copy entire things from repository to flash_recovery_area finaly apply the above mentioned restore command.
    Tabelspace incremenatl restore is possible after reimage application server(fresh database)/another server with same database(standby machine) ....?
    If we missing something in backup side please clarify me how to retore the tablespace incremental / level 0 tablespacae after reinstallion of server/another standby server.
    Any information please let me know .I need the solution as soon as please reply as soon as .

    Try the Recovery Manager (RMAN) instead. This forum is for feedback about the 11g XE Beta.

  • Production server Incremental Backup is restoring in Testing server

    Dear All,
    Currently our Production database is running in windows 2003 server , Oracle version is 10.2.0.4.0
    Now my question is daily incremental backup of production server will be restored in testing server (same configuration in production server
    and testing server ) how can i achieve this .....
    Regards,
    S.Arun

    Hi Oradba,
         Thanks for your response. I went through the link and we need this only for testing purpose and not for reporting.
    We need to take incremental backup and restore it in testing server. Is it possible to do this without RMAN.(Due to some Business reasons)
    Thanks & Regards,
    S.Arun

  • Incremental backup time query?

    Database size = 270GB
    Time taken for full level 0 backup = 50 minutes (Day 1)
    Time taken for cumulative level 1 backup = 70 minutes (Day 2)
    Time taken for differental level 1 backup = 55 minutes (Day 3)
    My question is how come the incremental backup is taking more time than the full backup time?
    Please advice.
    Sami Malik
    [email protected]

    Sami Malik wrote:
    Yes incremental backup is taken on the same time when there is heavy load on the system. For sure is this the reason? No, not for sure. We haven't seen enough info to say for sure, but given what we have been shown, it is a reasonable first guess. To know for sure, you need to do some actual performance analysis during both full and incremental backups and compare the two. STATSPACK is always a good place to start.
    I will try the incremental backup at night when there is nobody connected.
    Even though online backups <i>can</i> be taken anytime, it's always a good idea to schedule them during low-usage times.
    But one more question when in case if there is a 24/7 system, then its no use of taking incremental backup right?Why would you think that? If your system is 24/7, that's even <i><b>more</b></i> reason to be taking incrementals. If you do have to perform a recovery, having incrementals will shorten your recovery time, vs. haveing to apply all archived redo back to the last full backup.
    Also, you should be taking regular full backups as well. Most people take a full backup weekly, and an incremental on the other 6 days of the week.
    As an additional thought .... while it is a curiosity that that your incremental took longer than the full and much could be learned by chasing it down, you always have to ask "is this a problem that needs to be solved?" If you schedule all backups (full and incremental) during low-use times, and the users do not notice any impact, do you really care if the incremental took longer than the full? On the other hand, it may <i>not</i> be a problem that "needs" to be solved, but running it down may reveal other problems that are impacting or have real potential to impact the business, and <i>should</i> be solved.

  • Incremental Backup using "imsbackup"

    Dear every body,
    I have a trouble and need the help from you, please help me in this case if you can, thanks.
    I want to backup incrementally my mailboxes with "imsbackup" command. I have tested following below example but not succeeded:
    1. I send/receive email between 2 users in my domain at 08:00AM.
    2. I performed FULL backup the whole message store using imsbackup
    3. At 09:00AM I send/receive another email between 2 users in my domain
    4. I performed INCREMENTAL backup the whole message store using "imsbackup -d 20091217:083000....." but my backup file including the messages that I sent before 08:30AM
    I have done this several times and get the same result.
    Please kindly help me in this case, how can I use imsbackup to incrementally backup my mailboxes.
    Any help and advices from you is appreciated.
    Thanks all of you so much.
    huynq

    Hi Shane,
    Thanks so much for your response.
    The version of Messaging Server I am using is:
    {color:#ff0000}bash-3.00# ./imsimta version
    Sun Java(tm) System Messaging Server 7.0-3.01 64bit (built Dec 9 2008){color}
    For your question:
    Does this problem occur if you incrementally back up a single mailbox e.g.
    ./imsbackup -d 20091217:083000 ... user/<uid>/
    My Answer is:
    I have not performed above step yet because I want to backup mailboxes of all users.
    For your question:
    Is the time/timezone set correctly on the server?
    My answer is:
    Yes, of courses. I already set time/timezone correctly. I also checked the time stamp of newly created email in message store in server, their date are correct.
    For your question:
    Are you in daylight savings time i.e. you shift the imsbackup incremental time back-forward an hour and get the correct result?
    My answer is:
    I already tried many times but got the same result. For example, At{color:#ff0000} 9AM Dec 16th 2009{color} I sent an email. At{color:#ff0000} 9AM one day later (Dec 17th 2009){color} I sent another email. I performed incremental backup using{color:#ff0000} "./imsbackup -d 20091216:120000 -f- / > /email_backup/incremental.120000".{color}
    The backup file I got contained the email I sent at 9AM Dec 16th.
    Any advice on this ?
    Anyway, thanks so much for your help. I am awaiting your response.
    huynq.

  • Secure Backup Questions

    Hi Experts,
    We need a solution to backup 200+ Oracle server to a network drive (or multiple network drives as the case may be)
    I have been tasked with finding a solution, so far Secure Backup seems to be the ideal product, but I have a few questions.
    1. We require the backup to happen to a network disk, not a tape drive, I understand that we can use Virtual Tape Libraries to emulate a tape drive, are there any limitation to this and what VTL would you suggest?
    2. Can we do incremental backups? If so is there a differential process that must run before the backup can occur? Some of the databases we need to backup are larger than 1 TB.
    4. I'm struggling to get a quote out of Oracle, how much in USD can we expect to pay per server? a rough Ideas would help me make a decision about whether the project is viable or not.
    Thanks very much for you help.
    Regards,
    Gregory Alexander

    Oracle Secure Backup is licensing per physical tape drive. This is a single component licensing model which is very different that most other products which price per server, advanced feature etc.
    As noted earlier in the thread, you can utilize a VTL to obtain disk like performance for file system and the Oracle database. You could also utilize the Flash Recovery Area as a unified disk backup location for the Oracle database using RMAN and then OSB can backup the Flash Recovery Area to tape.

  • Optimized incremental backup in 10g

    Hi,
    I study the http://www.oracle.com/technology/products/database/oracle10g/pdf/twp_general_10gdb_product_family.pdf and i have one question about it...
    In "Incremental backup" feature/option there is a note :"SE/XE no optimized incremental backup".
    What are the features of "optimized incremental backup"...????
    Thanks......
    Sim

    I believe that is referring to block change tracking. That allows Oracle to track which blocks have actually changed since the last backup, so RMAN can just read the tracking file and backup those blocks rather than examining each block to see whether it has changed.
    Justin

  • Time Machine Incremental Backups

    I have just purchased a new MacBook Pro and restored my old MacBook on the new one using my Time Machine backup. Now I want Time Machine to continue backing up using the old backup and not starting a new backup from scratch. In effect, I want Time Machine to do incremental backups. I have read about Time Machine tying the Mac address of the old MacBook to the old backup I already have and as such, my new MacBook will have to create its own backup from scratch. Is there a work around this problem? Any helpful hints are welcome.

    iMinds wrote:
    Thanks for your suggestion. Yes, I did a full system restore, by booting the new Mac from the Leopard Install disc and selecting Utilities then Restore from Backups from the Menubar. What else can I do?
    Eeeeek! You now have the old Mac's entire version of OSX on the new one. I'm surprised it booted up at all. You may not have the correct hardware drivers and other things for the new Mac.
    I'm sorry to say, you need to start over. You need to do an *Erase and Install* using the Leopard Install disc that came with the new Mac, to put the correct version of OSX back on it. Then you can Migrate (transfer) everything else from your TM backups.
    See the *Erase, Install, & Migrate* section of the Glenn Carter - Restoring Your Entire System / Time Machine *User Tip* at the top of this forum.
    Once that's done, TM's next backup will be a full one. Everything you put on the new Mac's internal HD is new *to that Mac* as well as new *to that disk,* and TM's whole role in life is to back up everything that's new or changed. You cannot prevent it.
    Also, your old backups will not appear if you use the normal +Enter Time Machine+ option on the new Mac; you'll need the Browse option as per item #17 of the Frequently Asked Questions *User Tip* at the top of this forum.
    Plus, they won't be deleted by TM as the disk fills up, and it needs room for new backups. So your best bet will probably be, once you're sure everything transferred over properly, to simply erase the TM disk via Disk Utility and let TM start fresh.

Maybe you are looking for

  • Help with macbook to flatscreen tv

    I have my comp going to my flatscreen from dvi to hdmi and into tv. my tv shows the "starry night with northern lights" on the screen the apple has, but nothing i do on the computer shows up on the screen??? I've tried switching from "hdmi source" to

  • Schedule Lines in APO using CTM

    Dear Experts, How to create schedule lines directly in APO using CTM? Thanks adn regards, Sushant

  • HP Deskjet 2050 J510 series my scanner doesn't work

    got this HP as a birthday present, windows 7 says cannot scan This question was solved. View Solution.

  • How to use fault ploicies for DB adpter

    Hi Can fault policies applicalble to DB adapter. I added the porttype of DB adpater wsdl in fault-bindings.xml. while executing the DB adpter bpel i am getting a remote fault (bcoz i stopped database)and its not retrying just errored out. Can anyone

  • This code doesn't run

    This code doesn't pass run time. Can you please help me. * Copyright (c) 2004 David Flanagan.  All rights reserved. * This code is from the book Java Examples in a Nutshell, 3nd Edition. * It is provided AS-IS, WITHOUT ANY WARRANTY either expressed o