If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > NEWLOGPATH and user exit

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 01-12-04, 12:44
dollar489 dollar489 is offline
Registered User
 
Join Date: Sep 2002
Posts: 456
Arrow NEWLOGPATH and user exit

Hi,

In order to change the logpath of a database to new location using NEWLOGPATH do I have to make any change to userexit program so that it knows where the current logs will be? Or userexit gathers this information dynamically from the db cfg file?

DB : DB2 UDB V8 FP3 on Windows

dollar
Reply With Quote
  #2 (permalink)  
Old 01-12-04, 12:49
dbamota dbamota is offline
Registered User
 
Join Date: Sep 2003
Posts: 237
userexit gathers this information dynamically from the db cfg file
__________________
mota
Reply With Quote
  #3 (permalink)  
Old 01-12-04, 13:08
GertK GertK is offline
Registered User
 
Join Date: Nov 2003
Location: Netherlands
Posts: 96
Re: NEWLOGPATH and user exit

Quote:
Originally posted by dollar489
Hi,

In order to change the logpath of a database to new location using NEWLOGPATH do I have to make any change to userexit program so that it knows where the current logs will be? Or userexit gathers this information dynamically from the db cfg file?

DB : DB2 UDB V8 FP3 on Windows

dollar
Hi,

It's described in the db2uext source:

Code:
4. DB2 calls "db2uext2" in the following format -            
                                                             
     db2uext2 -OS<os> -RL<release> -RQ<request> -DB<dbname>  
              -NN<nodenumber> -LP<logpath> -LN<logname>      
              [-AP<adsmpasswd>]                              
                                                             
     where:  os         = operating system                   
             release    = DB2 release                        
             request    = 'ARCHIVE' or 'RETRIEVE'            
             dbname     = database name                      
             nodenumber = node number                        
             logpath    = log file path                      
             logname    = log file name                      
             logsize    = log file size (optional)           
             startingpage = starting offset in 4K page unit  
                            (optional)                       
             adsmpasswd = ADSM password (optional)
Hope this helps.

Kind regards, Gert
Reply With Quote
  #4 (permalink)  
Old 01-12-04, 13:29
dollar489 dollar489 is offline
Registered User
 
Join Date: Sep 2002
Posts: 456
Re: NEWLOGPATH and user exit

Thanks guys...

one more thing, how about the old log files, should I manually copy them to new location?

dollar


Quote:
Originally posted by GertK
Hi,

It's described in the db2uext source:

Code:
4. DB2 calls "db2uext2" in the following format -            
                                                             
     db2uext2 -OS<os> -RL<release> -RQ<request> -DB<dbname>  
              -NN<nodenumber> -LP<logpath> -LN<logname>      
              [-AP<adsmpasswd>]                              
                                                             
     where:  os         = operating system                   
             release    = DB2 release                        
             request    = 'ARCHIVE' or 'RETRIEVE'            
             dbname     = database name                      
             nodenumber = node number                        
             logpath    = log file path                      
             logname    = log file name                      
             logsize    = log file size (optional)           
             startingpage = starting offset in 4K page unit  
                            (optional)                       
             adsmpasswd = ADSM password (optional)
Hope this helps.

Kind regards, Gert
Reply With Quote
  #5 (permalink)  
Old 01-12-04, 15:43
cchattoraj cchattoraj is offline
Registered User
 
Join Date: Mar 2003
Posts: 343
I'd think you may want to backup the database after the newlogpath parms comes into effect to avoid having to look at those logs. Under a restore situation you may use the overflow logpath however, depending on how parms are set (softmax) some of these logs may be required for crash recovery.
Reply With Quote
  #6 (permalink)  
Old 01-12-04, 15:50
dollar489 dollar489 is offline
Registered User
 
Join Date: Sep 2002
Posts: 456
Thanks, thats what I was thinking too. Having logs at two different places will add to the complexity in case a restore is necessary.

dollar

Quote:
Originally posted by cchattoraj
I'd think you may want to backup the database after the newlogpath parms comes into effect to avoid having to look at those logs. Under a restore situation you may use the overflow logpath however, depending on how parms are set (softmax) some of these logs may be required for crash recovery.
Reply With Quote
  #7 (permalink)  
Old 01-12-04, 18:04
sathyaram_s sathyaram_s is offline
Super Moderator
 
Join Date: Aug 2001
Location: UK
Posts: 4,534
For crash recovery, my guess is that DB2 will be 'intelligent' enough to pick up logs from the old log path ...

Does anyone have experience otherwise ?

Cheers
Sathyaram

Quote:
Originally posted by cchattoraj
I'd think you may want to backup the database after the newlogpath parms comes into effect to avoid having to look at those logs. Under a restore situation you may use the overflow logpath however, depending on how parms are set (softmax) some of these logs may be required for crash recovery.
__________________
Visit the new-look IDUG Website , register to gain access to the excellent content.
Reply With Quote
  #8 (permalink)  
Old 01-12-04, 18:13
anil4321 anil4321 is offline
Registered User
 
Join Date: Feb 2003
Posts: 20
You don't have to move the log files manually.

When the first new connection is made to the database, the database manager will move the logs to the new location specified by newlogpath.
Reply With Quote
  #9 (permalink)  
Old 01-13-04, 13:13
preetim preetim is offline
Registered User
 
Join Date: Jun 2003
Posts: 77
Re: NEWLOGPATH and user exit

Hi ,

Please let me know if your user exit is functioning correctly after configuring NEWLOGPATH.
I'm having problems in doing the same thing.

My user exit was fine when the NEWLOGPATH parameter was not set and the active logs were going to the db2 default folder.
After I specified the NEWlogpath, the user exit stopped functioning. In the ARCHIVE file created by the user exit, it is recognizing the new logpath location, and stating no error. But actually the logs are not moving to the user exit path. I'm using DB2 v7.2 on windows NT.

Thanks.

Quote:
Originally posted by dollar489

In order to change the logpath of a database to new location using NEWLOGPATH do I have to make any change to userexit program so that it knows where the current logs will be? Or userexit gathers this information dynamically from the db cfg file?

DB : DB2 UDB V8 FP3 on Windows

dollar
Reply With Quote
  #10 (permalink)  
Old 01-13-04, 13:40
dollar489 dollar489 is offline
Registered User
 
Join Date: Sep 2002
Posts: 456
Re: NEWLOGPATH and user exit

Hi,

So far I have changed the archive path of db2uext2 file and it worked fine. Tomorrow I will change the NEWLOGPATH variable and let you know how did it go.

dollar


Quote:
Originally posted by preetim
Hi ,

Please let me know if your user exit is functioning correctly after configuring NEWLOGPATH.
I'm having problems in doing the same thing.

My user exit was fine when the NEWLOGPATH parameter was not set and the active logs were going to the db2 default folder.
After I specified the NEWlogpath, the user exit stopped functioning. In the ARCHIVE file created by the user exit, it is recognizing the new logpath location, and stating no error. But actually the logs are not moving to the user exit path. I'm using DB2 v7.2 on windows NT.

Thanks.
Reply With Quote
  #11 (permalink)  
Old 01-13-04, 14:43
preetim preetim is offline
Registered User
 
Join Date: Jun 2003
Posts: 77
Re: NEWLOGPATH and user exit

Thanks a lot for your response.
I'll wait for your next phase's result.


Quote:
Originally posted by dollar489
Hi,

So far I have changed the archive path of db2uext2 file and it worked fine. Tomorrow I will change the NEWLOGPATH variable and let you know how did it go.

dollar
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On