Linux平台下Apache 2.x Weblogic 8.1.x整合

來源:互聯網
上載者:User

1、把 /home/services/bea/weblogic81/server/lib/linux/i686 目錄下的mod_wl_20.so檔案拷貝到 /etc/httpd/modules 目錄下

2、修改Apache的設定檔/etc/httpd/conf/httpd.conf ,
       a). 添加和WebLogic相關的應用模組
        LoadModule weblogic_module modules/mod_wl_20.so

       b). 添加虛擬機器主機
# Virtual host admin.wps.com, 確保admin.wps.com被解析, 可以在/etc/hosts 中加入此網域名稱
<VirtualHost admin.wps.com>
        ServerName admin.wps.com
        DocumentRoot "/usr/webfiles/wps"
        <IfModule mod_weblogic.c>
        WebLogicHost 10.13.11.147
        WebLogicPort 7001
        MatchExpression *.jsp
        MatchExpression *.do   #這裡可以再加上自己調用的一些servlet
        </IfModule>
        <Directory "/usr/webfiles/wps">
        Options All
        AllowOverride None
        Allow from all
        Order allow,deny
        </Directory>
        <Directory "/usr/webfiles/wps/WEB-INF">
        deny from all
        Order deny,allow
        </Directory>
</VirtualHost>

通過上述配置, apache可以通過admin.wps.com網域名稱正常的訪問。

3、配置Weblogic應用
       a). 建立一個web module,並在該應用的WEB-INF目錄下面的weblogic.xml檔案中,是將該應用設定為myserver的預設Web應用。

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE weblogic-web-app PUBLIC "-//BEA Systems, Inc.//DTD Web
Application 8.1//EN"
"http://www.bea.com/servers/wls810/dtd/weblogic810-web-jar.dtd">
<weblogic-web-app>
  <container-descriptor>
    <index-directory-enabled>true</index-directory-enabled>
  </container-descriptor>
  <context-root>/</context-root>
</weblogic-web-app>

       b). 配置Weblogic的虛擬機器主機
       VirtualHosts,然後在右面點擊Configure a new Virtual Host...,在Configuration的General選項卡下面,填寫:
        Name: admin.wps.com
        Virtual Host Names: admin.wps.com
        然後點擊"apply",然後到Target and Deploy 選項卡,選中myserver,點擊"apply",這樣名稱為admin.wps.com的虛擬機器主機就搭建成功了。

       c). 進入Console的Targets選項,確認web應用與虛擬機器主機綁定

相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.