Discussion:
offline restore without roll forward
(too old to reply)
j***@gmail.com
2014-02-11 05:44:52 UTC
Permalink
I am using partitioned DB2 10.1 (AESE), with 15 partitions on 5 machines (each machine hosts 3 partitions).

I have taken an offline backup from my database (after deactivating it) by running following command on catalog node (instance owning node):

db2 backup database myDb on ALL DBPARTITIONNUMS to /home/data/db2/backup

Now I am trying to restore it, by running restore command without roll forward. Starting from catalog node, I run following command on ALL machines, and all of them return success code:

db2 RESTORE DATABASE myDb FROM /home/data/db2/backup TAKEN AT 20140210171717 INTO myDb REPLACE EXISTING WITHOUT ROLLING FORWARD

But when I start my database, and run queries, I keep getting following error:

SQL1471N Cannot connect to database "MYDB" on node "2" because the
database on this node is not synchronized with catalog node. SQLSTATE=08004

Reading IBM pages, I realized it is happening because of roll forwarding issues. I even tried running restore command, and right after that running following command from catalog node:

db2 rollforward db myDb to end of logs ON ALL DBPARTITIONNUMS and complete

But it keeps giving me the same error.

I am just wondering what I am missing, as I just want to restore myDb to its initial state that I had right after loading it, when I took backup.

Any suggestion/idea ?
(Thanks in advance)

James
Mark A
2014-02-11 10:06:15 UTC
Permalink
Post by j***@gmail.com
I am using partitioned DB2 10.1 (AESE), with 15 partitions on 5 machines
(each machine hosts 3 partitions).
I have taken an offline backup from my database (after deactivating it)
db2 backup database myDb on ALL DBPARTITIONNUMS to /home/data/db2/backup
Now I am trying to restore it, by running restore command without roll
forward. Starting from catalog node, I run following command on ALL
db2 RESTORE DATABASE myDb FROM /home/data/db2/backup TAKEN AT
20140210171717 INTO myDb REPLACE EXISTING WITHOUT ROLLING FORWARD
SQL1471N Cannot connect to database "MYDB" on node "2" because the
database on this node is not synchronized with catalog node.
SQLSTATE=08004
Reading IBM pages, I realized it is happening because of roll forwarding
issues. I even tried running restore command, and right after that
db2 rollforward db myDb to end of logs ON ALL DBPARTITIONNUMS and complete
But it keeps giving me the same error.
I am just wondering what I am missing, as I just want to restore myDb to
its initial state that I had right after loading it, when I took backup.
Any suggestion/idea ?
(Thanks in advance)
James
I am not sure about 10.1 but on 9.7 I think you need to restore the catalog node only first, then restore
all the other nodes. The first command you issued restores the catalog node only. Then run the same
command again prefixed by db2_all (instead of just db2) to restore to all nodes. At that point you
should be OK to connect to database.
j***@gmail.com
2014-02-11 22:21:32 UTC
Permalink
When running restore command, I first run it on the node that has catalog partition. So catalog partition gets restored first. Then I run the command on other boxes. db2_all also runs the command separately on each machine (similar to the way I am doing manually on machines). I do not face with any problem in that part, as all the machines return success.
I am just wondering why I keep getting SQL1471N error although I am restoring without Roll Forward.

James
Post by Mark A
Post by j***@gmail.com
I am using partitioned DB2 10.1 (AESE), with 15 partitions on 5 machines
(each machine hosts 3 partitions).
I have taken an offline backup from my database (after deactivating it)
db2 backup database myDb on ALL DBPARTITIONNUMS to /home/data/db2/backup
Now I am trying to restore it, by running restore command without roll
forward. Starting from catalog node, I run following command on ALL
db2 RESTORE DATABASE myDb FROM /home/data/db2/backup TAKEN AT
20140210171717 INTO myDb REPLACE EXISTING WITHOUT ROLLING FORWARD
But when I start my database, and run queries, I keep getting following
SQL1471N Cannot connect to database "MYDB" on node "2" because the
database on this node is not synchronized with catalog node.
SQLSTATE=08004
Reading IBM pages, I realized it is happening because of roll forwarding
issues. I even tried running restore command, and right after that
db2 rollforward db myDb to end of logs ON ALL DBPARTITIONNUMS and
complete
But it keeps giving me the same error.
I am just wondering what I am missing, as I just want to restore myDb to
its initial state that I had right after loading it, when I took backup.
Any suggestion/idea ?
(Thanks in advance)
James
I am not sure about 10.1 but on 9.7 I think you need to restore the catalog node only first, then restore
all the other nodes. The first command you issued restores the catalog node only. Then run the same
command again prefixed by db2_all (instead of just db2) to restore to all nodes. At that point you
should be OK to connect to database.
m***@gmail.com
2017-01-13 07:43:31 UTC
Permalink
whats the fix for this ?
Jerry Stuckle
2017-01-13 12:57:57 UTC
Permalink
Post by m***@gmail.com
whats the fix for this ?
Ensure the database is restored from consistent offline backups on all
nodes without rolling forward.
--
==================
Remove the "x" from my email address
Jerry Stuckle
***@attglobal.net
==================
t***@gmail.com
2019-02-11 00:10:17 UTC
Permalink
Hi all?
This problem is solved? If Yes, can you share the solution please?
I'm facing To the same issue.

Thanks in advance.

Loading...