Page 1 of 2 12 LastLast
Results 1 to 15 of 20
  1. #1
    Join Date
    Jan 2010
    Posts
    206

    Unanswered: Rollforward doesnt work! I need help please!

    Hello Guys,

    It would be great if somebody can help my on my problem. I need a quick solution. Today I restored a database and it worked fine until I wanted to make the rollforward. The error is like this:

    db2 rollforward db database complete
    SQL1276N Database "database" cannot be brought out of rollforward pending state
    until roll-forward has passed a point in time greater than or equal to
    "2011-06-19-05.14.35.000000 UTC", because node "0" contains information later
    than the specified time.


  2. #2
    Join Date
    Jan 2003
    Posts
    4,292
    Provided Answers: 5
    Code:
    db2 rollforward database to 2011-06-19-05.14.35.000000 and complete
    Andy

  3. #3
    Join Date
    Jan 2003
    Posts
    4,292
    Provided Answers: 5
    I should note that you will need the log files from the backup image in the correct directory for the rollforward to complete successfully.

    Andy

  4. #4
    Join Date
    Jan 2010
    Posts
    206
    SQL4970N Roll-forward recovery on database "Database" cannot reach the specified
    stop point (end-of-log or point-in-time) on database partition(s) "0".
    Roll-forward recovery processing has halted on log file "S0033785.LOG"
    Last edited by DB_N00b; 06-23-11 at 03:25.

  5. #5
    Join Date
    Jan 2003
    Posts
    4,292
    Provided Answers: 5
    Did you extract the log files from the backup image? Did you place all of them in the database log directory?

    Andy

  6. #6
    Join Date
    Jan 2010
    Posts
    206
    No! I did a redirectored restore from a TSM Full Backup, anyway, there is that missing log file in that folder.

    I dont get that?!

  7. #7
    Join Date
    Jan 2010
    Posts
    206
    total 795992
    -rw------- 1 db2inst3 db2adm3 4857856 22 Jun 18:24 S0033788.LOG
    -rw------- 1 db2inst3 db2adm3 134225920 22 Jun 18:24 S0033787.LOG
    -rw------- 1 db2inst3 db2adm3 134225920 22 Jun 18:24 S0033786.LOG
    -rw------- 1 db2inst3 db2adm3 134225920 22 Jun 18:24 S0033785.LOG

  8. #8
    Join Date
    Jan 2003
    Posts
    4,292
    Provided Answers: 5
    Does the redirect restore also retrieve the logs (LOGTARGET clause)? Is there anything in the db2diag.log file?

    Andy

  9. #9
    Join Date
    Jan 2010
    Posts
    206
    mmm it says this:

    2011-06-22-21.30.14.885564+120 E37864602A477 LEVEL: Warning
    PID : 348248 TID : 2071 PROC : db2sysc 0
    INSTANCE: db2inst3 NODE : 000 DB : Database
    APPHDL : 0-413 APPID: *LOCAL.db2inst3.110622193013
    AUTHID : DB2INST3
    EDUID : 2071 EDUNAME: db2agent (Database) 0
    FUNCTION: DB2 UDB, data protection services, sqlufrol, probe:8180
    MESSAGE : ADM1611W The rollforward recovery phase has been completed.

    2011-06-22-21.30.14.885967+120 I37865080A502 LEVEL: Warning
    PID : 348248 TID : 2071 PROC : db2sysc 0
    INSTANCE: db2inst3 NODE : 000 DB : Database
    APPHDL : 0-413 APPID: *LOCAL.db2inst3.110622193013
    AUTHID : DB2INST3
    EDUID : 2071 EDUNAME: db2agent (Database) 0
    FUNCTION: DB2 UDB, data protection services, sqlufrol, probe:8181
    MESSAGE : The rollforward recovery phase completed with a return code of
    -2146434885
    Last edited by DB_N00b; 06-23-11 at 03:26.

  10. #10
    Join Date
    Jun 2003
    Location
    Toronto, Canada
    Posts
    5,516
    Provided Answers: 1
    Quote Originally Posted by DB_N00b View Post
    there is that missing log file in that folder.
    Which is "that folder"? If you ask for help, I think it would do you a lot of good to respect other people's time and provide detailed information about what you're doing. Copy and paste your entire session, including your input and program output, beginning with the restore.

  11. #11
    Join Date
    Jan 2010
    Posts
    206
    Okay, Sorry for stealing your Time.

    This was my redirected restore command which worked fine!

    After that i tried the rollforward ( as u already know ) and it failed


    -- ************************************************** ***************************
    -- ** automatically created redirect restore script
    -- ************************************************** ***************************
    UPDATE COMMAND OPTIONS USING S ON Z ON Database_NODE0000.out V ON;
    SET CLIENT ATTACH_DBPARTITIONNUM 0;
    SET CLIENT CONNECT_DBPARTITIONNUM 0;
    -- ************************************************** ***************************
    -- ** automatically created redirect restore script
    -- ************************************************** ***************************
    RESTORE DATABASE Database
    -- USER <username>
    -- USING '<password>'
    REBUILD WITH TABLESPACE (
    SYSCATSPACE
    , TSTMP16K
    , SYSTOOLSTMPSPACE
    , Table1
    , Table2
    )
    USE TSM
    OPEN 1 SESSIONS
    OPTIONS '-fromowner=db2inst1'
    TAKEN AT Timestamp
    ON '/db2/Database/storage'
    DBPATH ON '/db2/Database/dbdir'
    INTO Database
    LOGTARGET '/db2/Database/templogs/'
    NEWLOGPATH '/db2/Database/logs/'
    -- WITH <num-buff> BUFFERS
    -- BUFFER <buffer-size>
    -- REPLACE HISTORY FILE
    -- REPLACE EXISTING
    REDIRECT
    -- PARALLELISM <n>
    -- WITHOUT ROLLING FORWARD
    -- WITHOUT PROMPTING
    ;
    -- ************************************************** ***************************
    -- ** table space definition
    -- ************************************************** ***************************
    -- ************************************************** ***************************
    -- ** Tablespace name = SYSCATSPACE
    -- ** Tablespace ID = 0
    -- ** Tablespace Type = System managed space
    -- ** Tablespace Content Type = All permanent data. Regular table space.
    -- ** Tablespace Page size (bytes) = 16384
    -- ** Tablespace Extent size (pages) = 32
    -- ** Using automatic storage = No
    -- ** Total number of pages = 22021
    -- ************************************************** ***************************
    SET TABLESPACE CONTAINERS FOR 0
    -- IGNORE ROLLFORWARD CONTAINER OPERATIONS
    USING (
    PATH '/db2/Database/ts_syscat'

    );
    -- ************************************************** ***************************
    -- ** Tablespace name = TSTMP16K
    -- ** Tablespace ID = 3
    -- ** Tablespace Type = System managed space
    -- ** Tablespace Content Type = System Temporary data
    -- ** Tablespace Page size (bytes) = 16384
    -- ** Tablespace Extent size (pages) = 32
    -- ** Using automatic storage = No
    -- ** Total number of pages = 4
    -- ************************************************** ***************************
    SET TABLESPACE CONTAINERS FOR 3
    -- IGNORE ROLLFORWARD CONTAINER OPERATIONS
    USING (
    PATH '/db2/Database/ts_tmp16k_sys_2'

    );
    -- ************************************************** ***************************
    -- ** Tablespace name = SYSTOOLSTMPSPACE
    -- ** Tablespace ID = 1455
    -- ** Tablespace Type = System managed space
    -- ** Tablespace Content Type = User Temporary data
    -- ** Tablespace Page size (bytes) = 16384
    -- ** Tablespace Extent size (pages) = 4
    -- ** Using automatic storage = Yes
    -- ** Total number of pages = 4
    -- ************************************************** ***************************
    -- ************************************************** ***************************
    -- ** Tablespace name = Table1
    -- ** Tablespace ID = 1823
    -- ** Tablespace Type = Database managed space
    -- ** Tablespace Content Type = All permanent data. Large table space.
    -- ** Tablespace Page size (bytes) = 16384
    -- ** Tablespace Extent size (pages) = 32
    -- ** Using automatic storage = No
    -- ** Auto-resize enabled = Yes
    -- ** Total number of pages = 1000
    -- ** Number of usable pages = 896
    -- ** High water mark (pages) = 96
    -- ************************************************** ***************************
    SET TABLESPACE CONTAINERS FOR 1823
    -- IGNORE ROLLFORWARD CONTAINER OPERATIONS
    USING (
    FILE '/db2/Database/Table1.ts' 500

    );
    -- ************************************************** ***************************
    -- ** Tablespace name = Table1
    -- ** Tablespace ID = 1824
    -- ** Tablespace Type = Database managed space
    -- ** Tablespace Content Type = All permanent data. Large table space.
    -- ** Tablespace Page size (bytes) = 16384
    -- ** Tablespace Extent size (pages) = 32
    -- ** Using automatic storage = Yes
    -- ** Auto-resize enabled = Yes
    -- ** Total number of pages = 5632
    -- ** Number of usable pages = 5504
    -- ** High water mark (pages) = 5408
    -- ************************************************** ***************************
    -- ************************************************** ***************************
    -- ** start redirected restore
    -- ************************************************** ***************************
    RESTORE DATABASE Database CONTINUE;
    -- ************************************************** ***************************
    -- ** end of file
    -- ************************************************** ***************************
    Last edited by DB_N00b; 06-23-11 at 03:28.

  12. #12
    Join Date
    Jan 2003
    Posts
    4,292
    Provided Answers: 5
    Based on your restore command, the logs are not being put into the proper directory for the rollforward to continue. You are putting them is a temp directory and setting the log directory to something else. How do they get to the log directory?

    Also post the the entire db2diag.log from the start of the rollforward to the end of the file.


    Andy

  13. #13
    Join Date
    Jan 2010
    Posts
    206
    Okay, when I enter:

    db2 rollforward database edwh2 to 2011-06-19-05.14.35.000000 and complete

    the db2diag says:

    2011-06-22-21.45.03.258581+120 I42220518A486 LEVEL: Warning
    PID : 348248 TID : 2071 PROC : db2sysc 0
    INSTANCE: db2inst NODE : 000 DB : Database
    APPHDL : 0-423 APPID: *LOCAL.db2inst3.110622194502
    AUTHID : DB2INST
    EDUID : 2071 EDUNAME: db2agent (Database) 0
    FUNCTION: DB2 UDB, data protection services, sqlufrol, probe:987
    DATA #1 : <preformatted>
    Stop Timestamp specified 2011-06-19-05.14.35.000000 UTC

    2011-06-22-21.45.03.258716+120 E42221005A506 LEVEL: Info
    PID : 348248 TID : 2071 PROC : db2sysc 0
    INSTANCE: db2inst NODE : 000 DB : Database
    APPHDL : 0-423 APPID: *LOCAL.db2inst3.110622194502
    AUTHID : DB2INST
    EDUID : 2071 EDUNAME: db2agent (Database) 0
    FUNCTION: DB2 UDB, data protection services, sqlufrol, probe:1210
    MESSAGE : ADM1603I DB2 is invoking the forward phase of the database
    rollforward recovery.

    2011-06-22-21.45.03.258858+120 I42221512A588 LEVEL: Warning
    PID : 348248 TID : 2071 PROC : db2sysc 0
    INSTANCE: db2inst NODE : 000 DB : Database
    APPHDL : 0-423 APPID: *LOCAL.db2inst3.110622194502
    AUTHID : DB2INST
    EDUID : 2071 EDUNAME: db2agent (Database) 0
    FUNCTION: DB2 UDB, recovery manager, sqlpForwardRecovery, probe:710
    DATA #1 : <preformatted>
    Invoking database rollforward forward recovery,
    lowtranlsn 0000041FD162DE7A in log file number 33785
    minbufflsn 0000041FD162DE7A in log file number 33785

    2011-06-22-21.45.03.267468+120 I42222101A495 LEVEL: Warning
    PID : 348248 TID : 2071 PROC : db2sysc 0
    INSTANCE: db2inst NODE : 000 DB : Database
    APPHDL : 0-423 APPID: *LOCAL.db2inst3.110622194502
    AUTHID : DB2INST
    EDUID : 2071 EDUNAME: db2agent (Database) 0
    FUNCTION: DB2 UDB, recovery manager, sqlprecm, probe:2000
    DATA #1 : <preformatted>
    Using parallel recovery with 6 agents 64 QSets 320 queues and 64 chunks

    2011-06-22-21.45.03.268623+120 E42222597A490 LEVEL: Warning
    PID : 348248 TID : 7599 PROC : db2sysc 0
    INSTANCE: db2inst NODE : 000 DB : Database
    APPHDL : 0-423 APPID: *LOCAL.db2inst.110622194502
    AUTHID : DB2INST
    EDUID : 7599 EDUNAME: db2redom (Database) 0
    FUNCTION: DB2 UDB, recovery manager, sqlpParallelRecovery, probe:880
    DATA #1 : <preformatted>
    Resetting max shredder memory to 12316373 from 32768000

    2011-06-22-21.45.03.362090+120 I42223088A365 LEVEL: Warning
    PID : 348248 TID : 2038 PROC : db2sysc 0
    INSTANCE: db2inst NODE : 000
    EDUID : 2038 EDUNAME: db2logmgr (Database) 0
    FUNCTION: DB2 UDB, data protection services, sqlpgRetryFailedArchive, probe:4071
    MESSAGE : search on vendor did not find any chain

    2011-06-22-21.45.03.362231+120 E42223454A433 LEVEL: Error
    PID : 348248 TID : 2038 PROC : db2sysc 0
    INSTANCE: db2inst NODE : 000
    EDUID : 2038 EDUNAME: db2logmgr (Database) 0
    FUNCTION: DB2 UDB, data protection services, sqlpSearchForLogArchiveOnDisk, probe:4000
    MESSAGE : ZRC=0x860F000A=-2045837302=SQLO_FNEX "File not found."
    DIA8411C A file "" could not be found.

    2011-06-22-21.45.03.366564+120 I42223888A421 LEVEL: Error
    PID : 348248 TID : 2807 PROC : db2sysc 0
    INSTANCE: db2inst NODE : 000 DB : Database
    EDUID : 2807 EDUNAME: db2loggr (Database) 0
    FUNCTION: DB2 UDB, recovery manager, sqlpgSwitchFromRedoToUndo, probe:1860
    MESSAGE : rc -2045837302 when trying to open log extent 33785, index 0
    FileCount 1

    2011-06-22-21.45.03.366691+120 I42224310A419 LEVEL: Error
    PID : 348248 TID : 2807 PROC : db2sysc 0
    INSTANCE: db2inst NODE : 000 DB : EDWH2
    EDUID : 2807 EDUNAME: db2loggr (Database) 0
    FUNCTION: DB2 UDB, data protection services, sqlpgasn, probe:650
    RETCODE : ZRC=0x801000BB=-2146434885=SQLPR_MISSING_LOGFILES
    "rollforward missing log files"

    2011-06-22-21.45.03.366831+120 I42224730A477 LEVEL: Error
    PID : 348248 TID : 7599 PROC : db2sysc 0
    INSTANCE: db2inst NODE : 000 DB : Database
    APPHDL : 0-423 APPID: *LOCAL.db2inst3.110622194502
    AUTHID : DB2INST
    EDUID : 7599 EDUNAME: db2redom (Database) 0
    FUNCTION: DB2 UDB, data protection services, sqlpgPostLoggrWithoutLatching, probe:930
    MESSAGE : db2logger: rc=-2146434885 sem rc=0 type=28

    2011-06-22-21.45.03.366946+120 I42225208A174 LEVEL: Error
    PID:348248 TID:7599 NODE:000 Title: SQLP_DBCB
    Dump File:/home/db2inst3/sqllib/db2dump/348248.7599.000.dump.bin

    2011-06-22-21.45.03.370099+120 I42225383A505 LEVEL: Error
    PID : 348248 TID : 7599 PROC : db2sysc 0
    INSTANCE: db2inst NODE : 000 DB : Database
    APPHDL : 0-423 APPID: *LOCAL.db2inst3.110622194502
    AUTHID : DB2INST
    EDUID : 7599 EDUNAME: db2redom (Database) 0
    FUNCTION: DB2 UDB, recovery manager, sqlpPRecReadLog, probe:3980
    RETCODE : ZRC=0x801000BB=-2146434885=SQLPR_MISSING_LOGFILES
    "rollforward missing log files"

    2011-06-22-21.45.03.573104+120 I42225889A508 LEVEL: Error
    PID : 348248 TID : 2071 PROC : db2sysc 0
    INSTANCE: db2inst NODE : 000 DB : Database
    APPHDL : 0-423 APPID: *LOCAL.db2inst3.110622194502
    AUTHID : DB2INST
    EDUID : 2071 EDUNAME: db2agent (Database) 0
    FUNCTION: DB2 UDB, recovery manager, sqlprDoForwardPhase, probe:330
    RETCODE : ZRC=0x801000BB=-2146434885=SQLPR_MISSING_LOGFILES
    "rollforward missing log files"

    2011-06-22-21.45.03.573258+120 I42226398A509 LEVEL: Error
    PID : 348248 TID : 2071 PROC : db2sysc 0
    INSTANCE: db2inst NODE : 000 DB : Database
    APPHDL : 0-423 APPID: *LOCAL.db2inst3.110622194502
    AUTHID : DB2INST
    EDUID : 2071 EDUNAME: db2agent (Database) 0
    FUNCTION: DB2 UDB, recovery manager, sqlpForwardRecovery, probe:1230
    RETCODE : ZRC=0x801000BB=-2146434885=SQLPR_MISSING_LOGFILES
    "rollforward missing log files"

    2011-06-22-21.45.03.576549+120 E42226908A477 LEVEL: Warning
    PID : 348248 TID : 2071 PROC : db2sysc 0
    INSTANCE: db2inst NODE : 000 DB : Database
    APPHDL : 0-423 APPID: *LOCAL.db2inst3.110622194502
    AUTHID : DB2INST
    EDUID : 2071 EDUNAME: db2agent (Database) 0
    FUNCTION: DB2 UDB, data protection services, sqlufrol, probe:8180
    MESSAGE : ADM1611W The rollforward recovery phase has been completed.

    2011-06-22-21.45.03.576860+120 I42227386A502 LEVEL: Warning
    PID : 348248 TID : 2071 PROC : db2sysc 0
    INSTANCE: db2inst NODE : 000 DB : Database
    APPHDL : 0-423 APPID: *LOCAL.db2inst.110622194502
    AUTHID : DB2INST
    EDUID : 2071 EDUNAME: db2agent (Database) 0
    FUNCTION: DB2 UDB, data protection services, sqlufrol, probe:8181
    MESSAGE : The rollforward recovery phase completed with a return code of
    -2146434885

    2011-06-22-21.45.03.654562+120 E42227889A467 LEVEL: Event
    PID : 348248 TID : 2071 PROC : db2sysc 0
    INSTANCE: db2inst NODE : 000 DB : Database
    APPHDL : 0-423 APPID: *LOCAL.db2inst.110622194502
    AUTHID : DB2INST
    EDUID : 2071 EDUNAME: db2agent (idle) 0
    FUNCTION: DB2 UDB, base sys utilities, sqeLocalDatabase::TermDbConnect, probe:2000
    STOP : DATABASE: Databaseb : DEACTIVATED: NO
    Last edited by DB_N00b; 06-23-11 at 05:05.

  14. #14
    Join Date
    Jan 2010
    Posts
    206
    What can i Do now? Should i fix the redirect restore command and run it again?

  15. #15
    Join Date
    Jan 2003
    Posts
    4,292
    Provided Answers: 5
    The db2diag.log file clearly shows that it cannot find the log files. You need to copy/move them from the temporary directory to the log directory before the rollforward.

    Andy

Posting Permissions

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