In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)05/31 Report--
This article mainly explains the "Oracle snooping log clean-up analysis", the content of the article is simple and clear, easy to learn and understand, the following please follow the editor's ideas slowly in depth, together to study and learn "Oracle snooping log clean-up analysis"!
The Oracle listener log file (usually called listener.log) is a plain text file whose size is growing all the time. On a production Oracle server, DBA will check the file every day, such as checking whether the listener has stopped abnormally, whether there is a malicious attack connection, etc. When the file is particularly large, it may be slow to open and browse the contents of the file. At this point, you may think of backing up the current log file and then recreating a new log file, but Oracle listeners are not allowed to delete and rename their log files at run time, so you have to stop the listener. After renaming, start the listener, and automatically create a new listener log file at startup, but the client connection will be disconnected. This article describes a method to rename the listener log file without stopping the listener.
Listener command (WINDOWS operates under the command line, LINUX and AIX are the same command)
Lsnrctl set log_status off
Lsnrctl set log_status on
Note: listener_scan1.log cleanup is different in the cluster.
Lsnrctl command line mode
Set current_listener listener_scan1
Set log_status off
Cat / dev/null > listener_scan1.log
Set log_status on
Cat listener_scan1.log
Stand-alone instance: AIX, ORACLE10G
1. Before processing (listener_p550a.log is very large)
P550a:/home/oracle/database/network/log#ls-lt
Total 2356504
-rw-r--r-- 1 oracle dba 1195793131 11: 09: 59 listener_p550a.log
-rw-r--r-- 1 oracle dba 10698028 March 10: 25 sqlnet.log
2 、 lsnrctl set log_status off
P550a:/#su-oracle
$lsnrctl set log_status off
LSNRCTL for IBM/AIX RISC System/6000: Version 10.2.0.3.0-Production on 11-MAR-2011 10:02:38
Copyright (c) 1991, 2006, Oracle. All rights reserved.
Connecting to (ADDRESS= (PROTOCOL=tcp) (HOST=) (PORT=1521))
LISTENER parameter "log_status" set to OFF
The command completed successfully
3. Move files to the backup path to free up space
P550a:/home/oracle/database/network/log#mv listener_p550a.log / bak
4 、 lsnrctl set log_status on
$lsnrctl set log_status on
LSNRCTL for IBM/AIX RISC System/6000: Version 10.2.0.3.0-Production on 11-MAR-2011 10:06:12
Copyright (c) 1991, 2006, Oracle. All rights reserved.
Connecting to (ADDRESS= (PROTOCOL=tcp) (HOST=) (PORT=1521))
LISTENER parameter "log_status" set to ON
The command completed successfully
5. Let's take a look. Listener_p550a.log has been created automatically.
P550a:/home/oracle/database/network/log#ls-lt
Total 20928
-rw-r--r-- 1 oracle dba 102 March 11 10 06 listener_p550a.log
-rw-r--r-- 1 oracle dba 10698028 March 10: 25 sqlnet.log
P550a:/home/oracle/database/network/log#
Thank you for your reading. The above is the content of "Oracle snooping Log cleanup Analysis". After the study of this article, I believe you have a deeper understanding of the problem of Oracle snooping log cleanup and analysis, and the specific usage needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.