Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

DB2 9 rollforward OVERFLOW LOG PATH syntax

800 views
Skip to first unread message

normajeansebastian via DBMonster.com

unread,
Oct 9, 2007, 7:33:14 PM10/9/07
to
Hi,
i am new to DB2, please be patient with me. i have a lot of informix
experience and some oracle.


i am trying to do a "db2 rollforward database QA4 to end of logs OVERFLOW LOG
PATH (/db2/QA4/log_dir)"

and i am getting a "badly placed ()'s" error.
however when i do "db2 rollforward ?" it shows how to use the command which
is exactly how i have it.
ROLLFORWARD DATABASE database-alias ....
[TO END OF LOGS] [AND {COMPLETE | STOP}] |
....[OVERFLOW LOG PATH (log-directory [{,log-directory ON DBPARTITIONNUM db-
partition-number} ... ])]


... what is wrong with my syntax? i thought the overflow log path was
supposed to override and roll whatever DB logs are sitting in the "overflow
log path" directory.... or at least that is what the online documentation
implies.

i am doing this because i did a backup including logs.
i was able to do the restore including logs ....which put the logs in the
above log_dir i listed.
but now i need to roll forward these logs.....


so to make my story even more fun... because the overflow log path concept
didn't work, i took the phrase off "db2 rollforward database QA4 to end of
logs" .... oh, DB2 likes that... and it is happily applying logs as it
requests them from netbackup.... so it will roll forward right into the mess
of transactions that caused my boss to request the DB restore in the first
place.
so i issued a cancel command....
and apparently i am in restore pending mode....

i believe i went far enough in rolling logs to get past the ones needed to
"wrap up the online backup" that i was restoring, so i could tie this off and
bring the DB up....
but how do i do that now...???

sorry this sounds so messy.... i am new....and this DB2 stuff is.... well....
fun. :)

and no, i have only been to the first IBM DB2 training class... which really
doesn't get me too far.

thank you for any help.
Norma Jean

--
Message posted via DBMonster.com
http://www.dbmonster.com/Uwe/Forums.aspx/ibm-db2/200710/1

shen...@gmail.com

unread,
Oct 9, 2007, 10:47:56 PM10/9/07
to
Put the " after db2 like this

fra...@gmail.com

unread,
Oct 10, 2007, 9:49:28 AM10/10/07
to
On Oct 9, 7:33 pm, "normajeansebastian via DBMonster.com" <u5287@uwe>
wrote:

try quotes before and after ()

KC

unread,
Oct 17, 2007, 9:53:04 AM10/17/07
to
On Oct 10, 9:49 am, "fraf...@gmail.com" <fraf...@gmail.com> wrote:
> On Oct 9, 7:33 pm, "normajeansebastian via DBMonster.com" <u5287@uwe>
> wrote:
>
>
>
>
>
> > Hi,
> > i am new toDB2, please be patient with me. i have a lot of informix
> > experience and some oracle.
>
> > i am trying to do a "db2rollforwarddatabase QA4 to end of logs OVERFLOW LOG

> > PATH (/db2/QA4/log_dir)"
>
> > and i am getting a "badly placed ()'s" error.
> > however when i do "db2rollforward?" it shows how to use the command which

> > is exactly how i have it.
> >ROLLFORWARDDATABASE database-alias ....

> > [TO END OF LOGS] [AND {COMPLETE | STOP}] |
> > ....[OVERFLOW LOG PATH (log-directory [{,log-directory ON DBPARTITIONNUM db-
> > partition-number} ... ])]
>
> > ... what is wrong with my syntax? i thought the overflow log path was
> > supposed to override and roll whatever DB logs are sitting in the "overflow
> > log path" directory.... or at least that is what the online documentation
> > implies.
>
> > i am doing this because i did a backup including logs.
> > i was able to do the restore including logs ....which put the logs in the
> > above log_dir i listed.
> > but now i need to roll forward these logs.....
>
> > so to make my story even more fun... because the overflow log path concept
> > didn't work, i took the phrase off "db2rollforwarddatabase QA4 to end of
> > logs" .... oh,DB2likes that... and it is happily applying logs as it

> > requests them from netbackup.... so it will roll forward right into the mess
> > of transactions that caused my boss to request the DB restore in the first
> > place.
> > so i issued a cancel command....
> > and apparently i am in restore pending mode....
>
> > i believe i went far enough in rolling logs to get past the ones needed to
> > "wrap up the online backup" that i was restoring, so i could tie this off and
> > bring the DB up....
> > but how do i do that now...???
>
> > sorry this sounds so messy.... i am new....and thisDB2stuff is.... well....
> > fun. :)
>
> > and no, i have only been to the first IBMDB2training class... which really

> > doesn't get me too far.
>
> > thank you for any help.
> > Norma Jean
>
> > --
> > Message posted via DBMonster.comhttp://www.dbmonster.com/Uwe/Forums.aspx/ibm-db2/200710/1
>
> tryquotesbefore and after ()- Hide quoted text -
>
> - Show quoted text -

Hello,

Just wondering if you got this issue resolved. I'm having the same
problem, or very similar issue..
I need to call a db2 rollforward from within a script that root is
running, so it needs to be prefixed with an "su". I have tried the
following with no success:

su - db2tst -c db2 "rollforward db tst to end of logs and stop
overflow log path ('/tmp')"
su - db2tst -c "db2 rollforward db tst to end of logs and stop
overflow log path ('/tmp')"
su - db2tst -c db2 rollforward db tst to end of logs and stop overflow
log path "('/tmp')"
su - db2tst -c db2 "rollforward db tst to end of logs and stop
overflow log path (/tmp)"
su - db2tst -c db2 rollforward db tst to end of logs and stop overflow
log path "(/tmp)"

Always get the same error message "ksh: 0403-057 Syntax error at line
1 : `(' is not expected."

Any help would really be appreciated! We're running AIX 5.3

Thanks,

Kevin

Lennart

unread,
Oct 17, 2007, 1:34:38 PM10/17/07
to

Try:

su - db2tst -c "db2 \"rollforward db tst to end of logs and stop
overflow

log path (/tmp)\" "

/Lennart

Lennart

unread,
Oct 17, 2007, 1:44:07 PM10/17/07
to
On Oct 17, 3:53 pm, KC <kebuc...@yahoo.com> wrote:

Not sure what happened to my other post. Apologies if it turns up in a
moment or so. Anyhow, try:

su - db2tst -c "db2 \"rollforward db tst to end of logs and stop
overflow

log path (/tmp)\" "

/Lennart

> Thanks,
>
> Kevin


KC

unread,
Oct 18, 2007, 7:04:29 AM10/18/07
to
> > I need to call adb2rollforwardfrom within a script that root is

> > running, so it needs to be prefixed with an "su". I have tried the
> > following with no success:
>
> > su - db2tst -cdb2"rollforwarddb tst to end of logs and stop

> > overflow log path ('/tmp')"
> > su - db2tst -c "db2rollforwarddb tst to end of logs and stop

> > overflow log path ('/tmp')"
> > su - db2tst -cdb2rollforwarddb tst to end of logs and stop overflow

> > log path "('/tmp')"
> > su - db2tst -cdb2"rollforwarddb tst to end of logs and stop
> > overflow log path (/tmp)"
> > su - db2tst -cdb2rollforwarddb tst to end of logs and stop overflow

> > log path "(/tmp)"
>
> > Always get the same error message "ksh: 0403-057 Syntax error at line
> > 1 : `(' is not expected."
>
> > Any help would really be appreciated! We're running AIX 5.3
>
> Not sure what happened to my other post. Apologies if it turns up in a
> moment or so. Anyhow, try:
>
> su - db2tst -c "db2\"rollforwarddb tst to end of logs and stop

> overflow
> log path (/tmp)\" "
>
> /Lennart
>
>
>
> > Thanks,
>
> > Kevin- Hide quoted text -
>
> - Show quoted text -- Hide quoted text -

>
> - Show quoted text -

Lennart,

That worked !! Thanks!! I should have thought that is just an
issue with the shell and formatting the string with "\"... anyways,
thanks again!

Kevin

0 new messages