Results 1 to 7 of 7
  1. #1
    Join Date
    May 2004
    Posts
    9

    Question Unanswered: restoring database from a different schema

    hi,

    i have been given backup image of a database which was created using username/password user1/pass1. now my database username is different (user2/pass2) and i cant seem to be able to restore the database image sent to me because i keep on getting the error that the supplied username and password is incorrect.

    my assumption is that the supplied password in the statement

    restore database testdata user user2 using pass2 from c:\temp\testdata with 3 buffers buffer 1024 without prompting

    is being used to 1) open the image, and 2 ) used for logging to the current instance (my system username and schema name are different).

    can somebody point me to the right direction?

    thanks.

  2. #2
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650
    What platform and version are you on ?

    If you are on Windows, is the user domain or local ?

    Cheers
    Sathyaram
    Visit the new-look IDUG Website , register to gain access to the excellent content.

  3. #3
    Join Date
    Jun 2004
    Posts
    2

    Urgent!!! Restore data from DAT files!?

    Hello,

    we have a big problem!
    From a DB does'n exist any backup. We have only the DAT.*, NAM.*, INX.*, *.LB and *.LBA files without their right paths for the data structure (only SMS tablespaces , OS=Win2000 Server).

    How can I restore the tables from the DAT tables? Do you know a tool which can read DAT files?

    thanks
    hufa

  4. #4
    Join Date
    May 2004
    Posts
    9
    Quote Originally Posted by sathyaram_s
    What platform and version are you on ?

    If you are on Windows, is the user domain or local ?

    Cheers
    Sathyaram
    Sorry, i forgot to supply that basic information...

    our platform is windows. the backup image is from DB2 7.2 EE which is the same version installed in the destination workstation.

    my user is a domain user but the DB2 application was intalled using a local account. please let me know if i have left out some other information useful for debugging this problem. thank you.

    regards...

  5. #5
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650
    Attach to the instance using your local account and password and then issue this restore command ...

    db2 attach to inst1 user localac using localpass
    db2 restore database dbname1 .....

    HTH

    sAthyaram
    Visit the new-look IDUG Website , register to gain access to the excellent content.

  6. #6
    Join Date
    May 2004
    Posts
    9
    ok, i logged in as the local user (db2admin) and attached to the db2 instance. however using any of the following command throws the exception that the supplied credentials are not valid.

    restore database testdata from c:\......
    restore database testdata user user2 using pass2 from c:\...
    restore database testdata user db2admin using localpass from c:\...

  7. #7
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650
    Certainly, the second and third statements have invalid credentials.

    For the first command, unless you supply the full command, there is no way for anyone to know what the invalud credentials are.

    BTW, IBM has compiled information about DB2 and published them. They are popularly known as manuals ... These pages may tell you what the valid credentials are ... Refer 'Useful DB2 Stuff' thread for the link to the manuals

    Cheers
    Sathyaram
    Visit the new-look IDUG Website , register to gain access to the excellent content.

Posting Permissions

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