zoukankan      html  css  js  c++  java
  • mod_wl.so,apxs,mod_so.c,withmpm=worker,selinux;apapche&weblogic链接配置

    #cd /data/src

    #tar -xvzf httpd-2.0.52.tar.gz

    #cd httpd-2.0.52

    #./configure --prefix=/usr/local/apache2 --enable-module=so --enable-rule=SHARED_CORE\

    --enable-rewrite && make && make install

    备注:不要添加参数:--with-mpm=worker了

    [root@lc httpd-2.0.52]# cd /usr/local/apache2/

    [root@lc apache2]# ./bin/httpd -l

    Compiled in modules:

      core.c

      mod_access.c

      mod_auth.c

      mod_include.c

      mod_log_config.c

      mod_env.c

      mod_setenvif.c

      worker.c

      http_core.c

      mod_mime.c

      mod_status.c

      mod_autoindex.c

      mod_asis.c

      mod_cgid.c

      mod_negotiation.c

      mod_dir.c

      mod_imap.c

      mod_actions.c

      mod_userdir.c

      mod_alias.c

      mod_so.c-------------------------à说明已经支持so模块

    [root@lc apache2]# cd /opt/bea/

    [root@lc bea]# pwd

    /opt/bea

    # perl /usr/local/apache2/bin/apxs -i -a -n weblogic mod_wl.so

    # ll /usr/lib/httpd/modules/mod_wl.so

    ls: /usr/lib/httpd/modules/mod_wl.so: No such file or directory

    [root@lc bea]# perl /usr/local/apache2/bin/apxs -i -a -n weblogic mod_wl.so

    /usr/local/apache2/build/instdso.sh SH_LIBTOOL='/usr/local/apache2/build/libtool' mod_wl.so /usr/local/apache2/modules

    /usr/local/apache2/build/libtool --mode=install cp mod_wl.so /usr/local/apache2/modules/

    cp mod_wl.so /usr/local/apache2/modules/mod_wl.so

    Warning!  dlname not found in /usr/local/apache2/modules/mod_wl.so.

    Assuming installing a .so rather than a libtool archive.

    chmod 755 /usr/local/apache2/modules/mod_wl.so

    [activating module `weblogic' in /usr/local/apache2/conf/httpd.conf]

    Httpd.conf文件配置

    # cd /usr/local/apache2/conf/

    # pwd

    /usr/local/apache2/conf

    [root@lc conf]# ../bin/apachectl start

    [root@lc conf]# ../bin/apachectl start

    WARNING: ThreadsPerChild of 100 exceeds ThreadLimit value of 64

    threads, lowering ThreadsPerChild to 64. To increase, please see the

     ThreadLimit directive.

    WARNING: MaxClients (10000) is not an integer multiple

     of ThreadsPerChild (64), lowering MaxClients to 9984

     for a maximum of 156 child processes,

    WARNING: MaxClients of 9984 would require 156 servers,

     and would exceed the ServerLimit value of 100.

     Automatically lowering MaxClients to 6400.  To increase,

     please see the ServerLimit directive.

    Syntax error on line 311 of /usr/local/apache2/conf/httpd.conf:

    DocumentRoot must be a directory

    当有如上报错后,去掉参数:--with-mpm=worker后,重新编译

    [root@lc conf]# ../bin/apachectl start

    Syntax error on line 311 of /usr/local/apache2/conf/httpd.conf:

    DocumentRoot must be a directory

    [root@lc conf]# ps aux|grep httpd

    root      8625  0.0  0.0   5136  1736 ?        Ss   10:09   0:00 /usr/local/apache2/bin/httpd -k start

    nobody    8626  0.0  0.0   4928  1140 ?        S    10:09   0:00 /usr/local/apache2/bin/httpd -k start

    nobody    8627  0.0  0.0 281908  2068 ?        Sl   10:09   0:00 /usr/local/apache2/bin/httpd -k start

    nobody    8629  0.0  0.0 281772  1700 ?        Sl   10:09   0:00 /usr/local/apache2/bin/httpd -k start

    root     14739  0.0  0.0   4016  680 pts/1    S+   10:23   0:00 grep httpd

    看到报错:DocumentRoot must be a directory,请查看SELinux的状态

    # getenforce

    Enforcing

    请关闭SELinux

    # setenforce 0

    # getenforce

    Permissive

    # vim /etc/sysconfig/selinux

    # This file controls the state of SELinux on the system.

    # SELINUX= can take one of these three values:

    #       enforcing - SELinux security policy is enforced.

    #       permissive - SELinux prints warnings instead of enforcing.

    #       disabled - SELinux is fully disabled.

    #SELINUX=enforcing

    SELINUX=disabled

    #reboot

  • 相关阅读:
    java多线程:并发包中ConcurrentHashMap和jdk的HashMap的对比
    java编程之:Unsafe类
    mave之:java的web项目必须要的三个jar的pom形式
    java多线程:并发包中ReentrantReadWriteLock读写锁的锁降级模板
    java多线程:并发包中ReentrantReadWriteLock读写锁的原理
    java编程之:按位与运算,等运算规则
    java多线程:jdk并发包的总结(转载)
    liunx之:wps for liunx的安装经验
    mysql中enum类型理解
    MySQL类型float double decimal的区别
  • 原文地址:https://www.cnblogs.com/taosim/p/2587590.html
Copyright © 2011-2022 走看看