Results 1 to 7 of 7
  1. #1
    Join Date
    Nov 2005
    Location
    Jersey
    Posts
    47

    Unanswered: Restore Informix database in batch process

    Hi all.

    I'm very new to the Informix world so please forgive me if this is a simple question.

    I would like to know if there is a command that will restore an informix database from one server to a backup server using a batch file. Also, not sure if this makes a difference, but the database will already exist on the backup server. Does this need to be deleted first? If so, what is the command line for that.

    Thank you for your help.

    ODaniels

  2. #2
    Join Date
    Nov 2004
    Posts
    143
    Hi,

    Informix doesnot take database level backups (ver 10 do take, I guess). So you need to write a script which will do the export of database using dbpexort utility, move all the unl and the sql file to the backup server, drop the existing database and then import from the FTPed files.

    Bye

    Nitin

  3. #3
    Join Date
    Nov 2005
    Location
    Jersey
    Posts
    47
    Hi.

    The backups are already happening nightly. I need to take the backup files and restore them onto a development server. That's the step I need help with. If anyone has the commands on how to drop the database and restore the files to the development server, that would be most helpfull.

    Thanks,
    ODaniels

  4. #4
    Join Date
    Nov 2004
    Posts
    143
    Hi,

    You can drop the database by running "drop database db_nm"

    once the database is dropped, use

    dbimport db_nm -d dbspace_nm

    where db_nm is the name of the database which you want to build and dbspace_nm is the name of the dbspace where you want the database to reside. Remember, there should be db_nm.exp directory and it should contain db_nm.sql along with unl files.

    Bye

    Nitin

  5. #5
    Join Date
    Nov 2002
    Posts
    25
    if your backup is an exported database, dbimport will work fine. If you have an ontape backup, then you should have the exact production replica of the test env.

  6. #6
    Join Date
    May 2004
    Location
    New York
    Posts
    248
    If your systems prod and dev are the same as far as onconfig file and dbspace layout then ontape -r is the best and fastest way

    I restore my dev system from prod on a weekly basis using ontape, my db is not that big around 10GB and it takes less then an hour

  7. #7
    Join Date
    Aug 2006
    Location
    Riga, Latvia
    Posts
    17
    Consider using HADR technlogy!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •