Solved

Not to show the Spy GET in the access_log file

Posted on 2004-03-23
8
937 Views
Last Modified: 2013-12-01
I am using 9iAS release 2 on windows 2000 platform.

Currently in the access_log file, it logs an endless list of GET requests for dms0/Spy,dmsoc4j/Spy,opromgr-service and opromgr-status. From the access_log file, it seems that the requests are fired every 10 seconds.

Can someone throw some lights on how to configure the system in such a way that those requests are not logged onto the access_log file.

















0
Comment
Question by:tionghoe
  • 4
  • 2
  • 2
8 Comments
 
LVL 9

Expert Comment

by:vzilka
ID: 10670428
Are you using an open enterprise manager window? The EM access the dmsspy all the time.
0
 

Author Comment

by:tionghoe
ID: 10671371
The EMWebsite is running as a service. Is this the open enterprise manager window that you are referring to  or somehow related ?
0
 
LVL 9

Expert Comment

by:vzilka
ID: 10674525
Yes. This is  the one that sends the DMS requests.
THe EMWebsite process is actually an OC4J isntance that run the administration console (enterprise manager).
It automatically runs DMS requests against the server to check it status.

I don't think you can disable this behavior.
0
 

Author Comment

by:tionghoe
ID: 10678192
You are right that the DMS behavior cannot be disabled. However, have you or anyone else came across on how not to log these DMS requests on the access_log ? It is taking up too much space when the EMWebSite is running.


0
Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

 
LVL 3

Expert Comment

by:gacki
ID: 10690189
Hi,

I came across the same problem a few months ago. I then found metalink doc 226873.1, but it didn't work for me. Today I found that this document has been updated on Feb 15th 2004. I will try it again and let you know if it works now.

Gerald Krieger

0
 

Author Comment

by:tionghoe
ID: 10690738
Thanx Gerald. Hope to hear positive news from you.
0
 
LVL 3

Accepted Solution

by:
gacki earned 500 total points
ID: 10703194
Now it worked for me!

The following are the most important parts of metalink doc 226873.1 "How to Control the Size of the Oracle HTTP Server access_log File in 9iAS R2". The document addresses both Unix and Windows, I will only quote the Windows stuff. No warranty for copy and paste errors:). Part 1 describes preliminary steps needed for 9ias RL 2 prior to 9.0.4. Part 2 describes the configuration changes to make in httpd.conf.

Part 1:

Due to [BUG:2402206] and [BUG:2444298] (internal BUGs) fixed in 9iAS 9.0.4, the  following workaround is required for 9iAS 9.0.2 and 9.0.3 for Option 2 explained  above to be workable. Because this workaround requires a manual change in some  of the 9iAS internal configuration files, Oracle highly recommends to make a full  back of 9iAS prior to the change and to take an extreme caution while updating  these files.  

1-Make a backup of the apache.xsd and modDirectiveMS.xsd file using the following commands:  
DOS>cd <ORACLE_HOME>\dcm\config\plugins\apache    
DOS>copy apache.xsd apache.xsd.org    
DOS>copy modDirectiveMS.xsd modDirectiveMS.xsd.org  

2-If you are running 9iAS 9.0.2.1 or above, then stop the dcm-daemon process  using the following command:  
DOS>cd <ORACLE_HOME>\opmn\bin     DOS>opmnctl stopproc gid="dcm-daemon"  

3-Edit the apache.xsd file:  
Use wordpad.exe to edit <ORACLE_HOME>\dcm\config\plugins\apache\apache.xsd file  

4-Search for a section that looks like:      
<complexType name="AccessLogType">
       <attribute name="LogFile"   type="string"        use="required"/>
       <attribute name="Format"    type="string"        use="required"/>
       <attribute name="Key"       type="apache:keyset" use="fixed" value="LogFile Format"/>
</complexType>  

Insert a new line in the above section so that it looks like:      
<complexType name="AccessLogType">
       <attribute name="LogFile"   type="string"        use="required"/>
       <attribute name="Env"       type="string"        use="optional"/>
       <attribute name="Format"    type="string"        use="required"/>
       <attribute name="Key"       type="apache:keyset" use="fixed" value="LogFile Format"/>    
</complexType>  

5-Save the file  

6-Edit the modDirectiveMS.xsd file:  
Use wordpad.exe to edit <ORACLE_HOME>\dcm\config\plugins\apache\modDirectiveMS.xsd file  

7-Search for a section that looks like:      
<group name="MSIfModule_SETENVIF_Content">      
 <sequence>        
      <element name="BrowserMatch"             type="string"   minOccurs="0" maxOccurs="unbounded"/>
      <element name="BrowserMatchNoCase"      type="string"   minOccurs="0"/>        
      <element name="SetEnvIf"               type="string"   minOccurs="0"/>        
      <element name="SetEnvIfNoCase"           type="string"   minOccurs="0"/>      
 </sequence>    
</group>  

Change it so it looks like:      
<group name="MSIfModule_SETENVIF_Content">      
  <sequence>        
      <element name="BrowserMatch"             type="string"   minOccurs="0" maxOccurs="unbounded"/>               <element name="BrowserMatchNoCase"      type="string"   minOccurs="0" maxOccurs="unbounded"/>               <element name="SetEnvIf"               type="string"   minOccurs="0" maxOccurs="unbounded"/>               <element name="SetEnvIfNoCase"           type="string"   minOccurs="0" maxOccurs="unbounded"/>
  </sequence>    
</group>  

8-Save the file  

9-If you are running 9iAS 9.0.2.1 or above, then start the dcm-daemon process   using the following command:  DOS>cd <ORACLE_HOME>\opmn\bin    
DOS>opmnctl startproc gid="dcm-daemon"

Part 2:

In the steps below, replace any occurrence of <ORACLE_HOME> with the complete path of Oracle Home.  

1-Make a backup of $ORACLE_HOME/Apache/Apache/conf/httpd.conf file using the following commands:  
DOS>cd <ORACLE_HOME>\Apache\Apache\conf    
DOS>copy httpd.conf httpd.conf.org  

2-Edit the httpd.conf file:  
Use wordpad.exe to edit <ORACLE_HOME>\Apache\Apache\conf\httpd.conf file  

3-Comment out the following line, by adding # at the start of the line:
CustomLog logs/access_log common  

4-Add the following lines just after the line commented out in step 3 above:
SetEnvIf Request_URI "^\/dmsoc4j\/Spy" noLog    
SetEnvIf Request_URI "^\/dms0\/Spy" noLog    
SetEnvIf Request_Method HEAD noLog    
CustomLog <ORACLE_HOME>\Apache\Apache\logs\access_log common env=!noLog  

Note: ----- o If you have multiple CustomLog (or TransferLog) directives, you will need to add   env=!noLog option to each of them as shown in step 4 above. It is only enough   to change the CustomLog line in the Server Level Configuration context to bypass    spy requests. Changing the CustomLog or TransferLog in SSL VirtualHost should   not cause any problems, but will not really add any value since OPMN pings OHS    using HTTP and not HTTPS.            

5-Update DCM and stop the OHS using the following commands:  
DOS>cd <ORACLE_HOME>\dcm\bin    
DOS>dcmctl updateConfig -ct ohs -v -d    
DOS>dcmctl stop -ct ohs -v -d  

6-Archive the existing access_log using the following commands:  
DOS>cd <ORACLE_HOME>\Apache\Apache\logs    
DOS>ren access_log access_log.old  

7-Start the OHS using the following command:  
DOS>cd <ORACLE_HOME>\dcm\bin    
DOS>dcmctl start -ct ohs -v -d  

Hope this helps

Gerald
0
 

Author Comment

by:tionghoe
ID: 10705297
Gerald,

Thanx for the posting.
I tried the 2nd part alone but it was't working then. I am going to try it with the 1st part but it may take me awhile to get hand-on on it again. Anyway, I am going to give you the points now.

Thanx.
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

Suggested Solutions

-Xmx and -Xms are the two JVM options often used to tune JVM heap size.   Here are some common mistakes made when using them:   Assume BigApp is a java class file for the below examples. 1.         Missing m, M, g or G at the end …
Most of the developers using Tomcat find it easy to configure the datasource in Server.xml and use the JNDI name in the code to get the connection.  So the default connection pool using DBCP (or any other framework) is made available and the life go…
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…
This video shows how to remove a single email address from the Outlook 2010 Auto Suggestion memory. NOTE: For Outlook 2016 and 2013 perform the exact same steps. Open a new email: Click the New email button in Outlook. Start typing the address: …

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now