SunQuest
 
       Oracle
  Home arrow Oracle arrow Page 2 - Configuring the Oracle HTTP Server
Dev Shed Forums 
Administration  
AJAX  
Apache  
BrainDump  
DHTML  
Flash  
Java  
JavaScript  
Multimedia  
MySQL  
Oracle  
Perl  
PHP  
Practices  
Python  
Reviews  
Security  
Style-Sheets  
Web Services  
XML  
Zend  
Zope  
Forums Sitemap 
IBM® developerWorks 
Sun Developer Network 
Dedicated Servers 
E-Commerce Hosting 
Linux Web Hosting 
Managed Hosting 
Small Business Hosting 
Actuate Whitepapers 
VeriSign Whitepapers 
VPS Hosting 
Weekly Newsletter

 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
ORACLE

Configuring the Oracle HTTP Server
By: McGraw-Hill/Osborne
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 5 stars5 stars5 stars5 stars5 stars / 3
    2007-01-18

    Table of Contents:
  • Configuring the Oracle HTTP Server
  • Access Control Directives
  • Administration Directives
  • Managing Processes and Connections

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT

    Stay one step ahead of the competition. Evaluate and give feedback on some of the hottest web development tools on the market today. Make your opinion heard! Click Here

    Configuring the Oracle HTTP Server - Access Control Directives


    (Page 2 of 4 )

    There are several important directives that relate to access control. These directives set the server and server administrator options, and they can be set for the main OHS server or a virtual host. Access control directives are useful when you want to limit the IP addresses or ports the OHS server will listen to, for example. Let's discuss the important access control-related OHS configuration directives, which are the Listen, UseCanonicalName, ServerName, and Port directives.

    Listen   The Listen directive tells the OHS server which port and IP address combinations it should listen to for client connection requests. The syntax for the Listen directive is as follows:

      Listen [IP-address:]portnumber

    As you can see, you can specify both the IP address and the port number as arguments to the Listen directive. However, the IP address is only an optional argument. If you specify only a certain port number, the OHS server will listen to all requests from all IP addresses on that port. If you specify the optional port number as well as the mandatory port number arguments, the OHS server will listen to requests only from the port number and IP address combination. Here's an example:

      Listen 192.166.14.12:80

    exam watch:  By default, the OHS Server listens to every IP address, if you just specify the port number for the Listen directive specification.

    The OHS server will listen to requests only from the IP address 192.166.14.12, on port 80. If you specify multiple Listen directives with various IP and port number combinations, OHS will accept connection requests from all the specified combinations of IP addresses and ports. Note that if you leave out the IP address, OHS will honor requests from all IP addresses, as long as they come through the
    specified port.

    UseCanonicalName   On occasion, the OHS server needs to construct self-referential URLs--that is, URLs that refer back to the same server. When redirecting a URL to the same server (i.e., when the OHS Server has to construct a self-referential URL), it has two choices regarding the host name and port. The first option is to use the host name and port specified by users in the HTTP 1.1 header. The other way is to use the host name and port numbers specified by the ServerName and Port directives. You can choose the latter option by setting the UseCanonicalName setting to ON, which is the default setting for this directive. If you set the UseCanonicalName directive to ON, the Oracle HTTP Server will use the Server Name and Port directives to construct the canonical name for the server.

      Example: ServerName = www.example.com
               Port = 9090
              Canonical Name = www.example.com:9090

    Self referential URLs may be useful when you have an intranet server, where you use short names such as www. If a user types a short name such as http://www/test (without the trailing slash), OHS will redirect it by default ( UseCanonicalName is ON by default) to http://www.mydomain.com/test /, and the user may thus be forced to authenticate twice (if you have enabled authentication)--first to //www, and then to //www/test. If you set UseCanonicalName to OFF instead, OHS will redirect this self-referential URL to simply http://www/test/ .

    ServerName   The ServerName directive specifies the host name and port that the server uses to identify itself when redirecting user URLs. IF you don't specify the ServerName directive, the OHS server will try to perform a reverse lookup on the IP address to gather the host name information. If you omit the optional port argument for the ServerName directive, then OHS will use the port number specified in the incoming requests. It's a good idea to always explicitly specify the hostname and port by using the ServerName directive. Here's the syntax of the ServerName directive:

      ServerName fully-qualified-domain-name[:port]

    As you can see, the fully qualified domain name is mandatory, and the port specification is optional, for the ServerName directive. Let's say the name of the server hosting the OHS server is test.company.com. Let's say the server also has a DNS alias named www.company.com. If your goal is for the server to be always identified as www.company.com, you can do that by setting the following value for the ServerName directive:

     ServerName www.company.com:80

    Under a virtual hosting system, the ServerName directive inside the <VirtualHost> container specifies the host names that should be specified in the HTTP 1.1 headers to match the virtual host name.

    The ServerName directive defines the host name for the SERVER_NAME variable used in the canonical server name for URL redirection requests.

    Port    The Port directive sets the SERVER_PORT environment variable used in redirection requests. If you don't set the Listen directive, the OHS Server accepts connections and redirects to the port number specified by the Port directive. That is, in the absence of the Listen directive, the Port directive specifies the default port for the Web server. If you do set the Listen directive, however, OHS uses the Port directive only for redirection; this is usually the IP and port on the Web cache that sits in front of the OHS. When you use the Listen directive, that directive will override any port value that's been set by you, which will become the default port for redirected URLs or any other URLs generated by the Oracle HTTP Server. The port numbers OHS can use range from 0 to 65535, but all port numbers below 1024 are reserved for system use.

    on the job:  You can start OHS only from the root account if you choose port number 80.

    More Oracle Articles
    More By McGraw-Hill/Osborne


       · This article is an excerpt from the book "Oracle 10g Application Server Exam Guide,"...
     

    Buy this book now. This article is excerpted from chapter five of the book Oracle 10g Application Server Exam Guide, written by Sam Alapati (McGraw-Hill, 2006; ISBN: 0072262710). Check it out today at your favorite bookstore. Buy this book now.

       

    ORACLE ARTICLES

    - Tuning PL/SQL Code
    - Debugging PL/SQL Code
    - Testing PL/SQL Code
    - Working With PL/SQL Code
    - Conditional Compilation for Oracle Database ...
    - Compile-Time Warnings for Oracle DB 10g
    - Compiling PL/SQL Code for an Oracle Database
    - Troubleshooting PL/SQL Code
    - Managing PL/SQL Code
    - Data Manipulation and More for HTML DB Appli...
    - Oracle Database Fundamentals
    - Adding Processes to HTML DB Applications
    - Adding Computations, Processes, and Validati...
    - Sub-templates and More with Oracle HTML DB
    - Focusing on Templates in Oracle HTML DB





    © 2003-2008 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway