DBAsupport.com Forums - Powered by vBulletin
Results 1 to 6 of 6

Thread: create bAtch file to delete old listener log on windows

  1. #1
    Join Date
    Jan 2008
    Posts
    17

    create bAtch file to delete old listener log on windows

    hi all,
    plz comment
    i am planing to make a batch file to delete old listener log file and old log file will be automatically zipped in same location.

  2. #2
    Join Date
    Aug 2007
    Location
    Cyberjaya,kuala lumpur
    Posts
    340
    What you are expecting

  3. #3
    Join Date
    Dec 2007
    Posts
    82
    listener logs does not occupy more disk space and other logs(??? Alert??). write a batch file and zip those and move another location and delete. however keep on eye on log files all the time as it is the place where you look for DB issues if any.

  4. #4
    Join Date
    Jan 2008
    Posts
    17
    Hi Expert People ,

    I Just Wanna Batch File Which Will Replace Old Listener Log With New , So I Can Schdule It And Hence Personal Interference Is Not Required.

  5. #5
    Join Date
    Apr 2006
    Posts
    377
    You can use forfiles to delete/move older files on Windows. However, you'll have to either shutdown the listener or find a utility that will allow you to delete/move an open file.

    Forgot to mention, you do have an option to avoid shutting down the listener. You could run the following command to rename the listener.log file while the listener is running:

    Code:
    C:\> lsnrctl
    LSNRCTL> SET LOG_FILE c:\oracle\network\log\new_listener.log
    Last edited by ebrian; 07-12-2008 at 06:49 AM.

  6. #6
    Join Date
    Jan 2008
    Posts
    17
    hi ebrain ,

    i am aware of below step. but i want to create a batch file to automate the below task..
    any idea. how

Posting Permissions

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


Click Here to Expand Forum to Full Width