Results 1 to 14 of 14

Thread: Log path change

  1. #1
    Join Date
    Sep 2011
    Posts
    85

    Question Unanswered: Log path change

    Hi all..

    Scenario
    I have a 3 databasees DB 9.7 express C for our Rational Software [RTC,RRC,RQM]
    we have installed the DB's data file in E: drive and it was became low disk and the Health center indicated Alarm state. So i have installed a New hard disk and directed the data file to new disk which was recommended by Health center.

    Problem
    But after that there was a db2 Log Filesystem Utilization in alarm state. So i changed the FAILARCHPATH , LOGARCHMETH1 , MIRRORLOGPATH to different locations. But LOGPATH still in the E: drive which is became full. I cant change that using Control Center..
    Is there is a way, I mean a command..
    What what is the way [I should take a back-up, Close all applications]

    Refer the attachments as well

    Any help would be appreciated
    Attached Thumbnails Attached Thumbnails untitled.JPG   untitled1.JPG  

  2. #2
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650
    The solution is in untitled1.jpg. Read carefully.

    Let me give a hint. - "new"

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

  3. #3
    Join Date
    Sep 2011
    Posts
    85

    Correct

    Yes i know i have to change it to new location..

    But this can't be done from Control Center.. Its un editable. Unlike other paths..

    Another question with me was this log saves directly in DB datafile

    eg : E:\RQM\DB2\NODE000\SQL00001\.....

    will this be a problem to the DB if this change to new location..

    Plz note that database maintenance in Fully Automated level..

    Plz give your advice..

  4. #4
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650
    Quote Originally Posted by ai_zaviour View Post
    Yes i know i have to change it to new location..

    But this can't be done from Control Center.. Its un editable. Unlike other paths..
    You didn't read the contents of untitled1.jpg . I have also given a hint.


    Another question with me was this log saves directly in DB datafile

    eg : E:\RQM\DB2\NODE000\SQL00001\.....

    will this be a problem to the DB if this change to new location..

    Plz note that database maintenance in Fully Automated level..

    Plz give your advice..
    If you want to change the db to a new location then you have to make sure the log path is 'moved' as well. As this is the default path, if doing redirected restore, no special action needed. If using relocate db, then include the change to the log path in the config file.

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

  5. #5
    Join Date
    Sep 2011
    Posts
    85

    Thats not what i want

    Thanx fro the replay..

    But im not restoring the DB to new location...
    Because of the disk full problem.. Health center suggest to add a new disk location..
    So i add a new hard disk and gave the location there..
    But still a db located in E: the excess data will go to G: drive as i have added that using Health Center suggestion.

    But what should i done with the logpath..

    Plz refer the 1st post for problem..

    Thanx..

  6. #6
    Join Date
    Apr 2006
    Location
    Belgium
    Posts
    2,514
    Provided Answers: 11
    according the doc
    The new setting does not become the value of logpath until both of the following occur:
    The database is in a consistent state, as indicated by the database_consistent parameter.
    All applications are disconnected from the database
    has this condition occured..
    Best Regards, Guy Przytula
    Database Software Consultant
    Good DBAs are not formed in a week or a month. They are created little by little, day by day. Protracted and patient effort is needed to develop good DBAs.
    Spoon feeding : To treat (another) in a way that discourages independent thought or action, as by overindulgence.
    DB2 UDB LUW Certified V7-V8-V9-V9.7-V10.1-V10.5 DB Admin - Advanced DBA -Dprop..
    Information Server Datastage Certified
    http://www.infocura.be

  7. #7
    Join Date
    Sep 2011
    Posts
    85
    I have change the DB's following parameter's - FAILARCHPATH , LOGARCHMETH1 , MIRRORLOGPATH to new location..

    Then restart the DB..
    Its work fine with all applications. But still i can't change the LOGPATH which is like starts with E:\DB2\NODE0000\SQL00001\...

    Its un editable in Control Center - Configure Parameter option.

    My question is how to change this as Health Center giving me a Alarm for log file.
    If i can change this what is the way..
    As a example

    Step 1 - Close all applications
    Step 2 - Back-up DB
    Step 3 - enter db2 update db cfg .........

    something like this...

  8. #8
    Join Date
    Apr 2006
    Location
    Belgium
    Posts
    2,514
    Provided Answers: 11
    why don't you use the command line interface ? no backup is needed....
    db2 update db cfg ... newlogpath ..
    disconnect all applications
    deactivate/activate database
    db2 get db cfg show detail .. should indicate if active or pending..
    for all details on commands see :
    UPDATE DATABASE CONFIGURATION
    Best Regards, Guy Przytula
    Database Software Consultant
    Good DBAs are not formed in a week or a month. They are created little by little, day by day. Protracted and patient effort is needed to develop good DBAs.
    Spoon feeding : To treat (another) in a way that discourages independent thought or action, as by overindulgence.
    DB2 UDB LUW Certified V7-V8-V9-V9.7-V10.1-V10.5 DB Admin - Advanced DBA -Dprop..
    Information Server Datastage Certified
    http://www.infocura.be

  9. #9
    Join Date
    Sep 2011
    Posts
    85
    This was what i have done

    db2 connect to RQM

    db2 update db cfg newlogpath G:\DB2LOGPATH\RQM - This gave a error

    db2 update db cfg logpath G:\DB2LOGPATH\RQM - This also give a error

    Can u'll provide me the correct command

  10. #10
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650
    Lookup the syntax of update db cfg command. you are missing the keyword using.

    For future reference, When you get an error always post the error message.
    Visit the new-look IDUG Website , register to gain access to the excellent content.

  11. #11
    Join Date
    Sep 2011
    Posts
    85
    sorry for the mistake

    i have done was

    db2 connect to RQM

    db2 update db cfg newlogpath G:\DB2LOGPATH\RQM - This gave a error

    Error was - SQL0104N An unexpected token "newlogpath" was found following "CFG".Expected tokens may include: "DBPARTITIONNUM". SQLSTATE=42601

    db2 update db cfg logpath G:\DB2LOGPATH\RQM - This also give a error

    Error was - SQL0104N An unexpected token "logpath" was found following "CFG". Expected tokens may include: "DBPARTITIONNUM". SQLSTATE=42601

  12. #12
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650
    Did you
    Lookup the syntax of update db cfg command. you are missing the keyword using.
    ?

    You can lookup syntax for a db2 command (not sql) using

    Code:
    db2 "? update"
    Last edited by sathyaram_s; 09-12-11 at 05:41.
    Visit the new-look IDUG Website , register to gain access to the excellent content.

  13. #13
    Join Date
    Sep 2008
    Location
    Toronto,Canada
    Posts
    655
    db2 update db cfg using newlogpath G:\DB2LOGPATH\RQM

  14. #14
    Join Date
    Sep 2011
    Posts
    85
    Thanx for the help...

Posting Permissions

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